question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

jsonb_pretty method buffer ending prematurely

See original GitHub issue

Description

When the postgres method jsonb_pretty is used on a jsonb object that is larger than ~15-20 lines, then the result is cut off. Not sure if it is cut off from a certain number of characters or certain number of lines. i.e.

test@localhost:main>  select jsonb_pretty(object) from table;
+-------------------------------------------------------------------+
| jsonb_pretty                                                      |
|-------------------------------------------------------------------|
| [                                                                 |
|     {                                                             |
|         "sample": "1",                                            |
|         "this": {                                                 |
|             "does": true,                                         |
|             "not": null,                                          |
|             "output": null,                                       |
|             "properly": null,                                     |
|             "and": null,                                          |
|             "is": null,                                           |
|             "cut": null                                           |
|         },                                                        |
|         "off": "false",                                           |
|         "prematurely": false,                                     |
|         "unfortunately": true                                     |
+-------------------------------------------------------------------+

Your environment

Connected to a local postgres database

  • Please provide your OS and version information. Running Mac OS 10.14.5

  • Please provide your CLI version. pgcli version 2.1.1 (latest)

  • What is the output of pip freeze command. No output.

To be clear, this issue does not happen when using the native psql cli tool for postgres.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:1
  • Comments:8 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
Jl14Salvadorcommented, Jul 15, 2019

I actually had it installed through brew and it looks like the formula had not been updated yet. And when i uninstalled and reinstalled it the issue persisted. I then uninstalled it using brew and reinstalled it through pip instead and that installed the latest version with that fix you mentioned (from cli-helper 1.2.1). Thanks for your help! @amjith 🎉

0reactions
Globegittercommented, Sep 18, 2019

If I use the normal psql client btw it can print the column just fine.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Documentation: 9.5: Release 9.5 - PostgreSQL
Create mechanisms for tracking the progress of replication, including methods for identifying the origin of individual changes during ...
Read more >
Today I Learned - TIL @ Hashrocket
Hey, want to change your database so that you can never delete a record? Here's a way to implement this (probably terrible) idea,...
Read more >
VMware Tanzu Greenplum 7 Beta Documentation
Configuring and Using Resource Groups. 988. Prerequisite. 988. Procedure. 990. VMware Tanzu Greenplum 7 Beta Documentation. VMware, Inc.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found