-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Truncation of displayed array entries in the REPL with TERM=dumb #36492
Comments
Something is likely wrong with your setup. How did you install and launch Julia? What's the output of |
Aha. Thanks for the clue.
This issue only affects my REPL when it is running inside an emacs shell.
I can confirm that this occurs with a freshly downloaded version of
Julia 1.4.2 (and a less fresh version 1.4.1).
The behavior changed from Julia 1.3.1 where the REPL functioned as expected.
In both cases I tested this with emacs-nox 25.2.2.
Inside the emacs shell, the displaysize() function returns the correct
result, but when I start the REPL in the emacs shell, the REPL warns me:
┌ Warning: Terminal not fully functional
└ @ Base client.jl:374
In Julia 1.4.2:
julia> versioninfo(verbose=true)
Julia Version 1.4.2
Commit 44fa15b* (2020-05-23 18:35 UTC)
Platform Info:
OS: Linux (x86_64-pc-linux-gnu)
Ubuntu 18.04.4 LTS
uname: Linux 4.15.0-108-generic #109-Ubuntu SMP Fri Jun 19 11:33:10
UTC 2020 x86_64 x86_64
CPU: Intel(R) Core(TM) i7 CPU 930 @ 2.80GHz:
speed user nice sys idle irq
#1 1608 MHz 8504745 s 1 s 491936 s 18723355
s 0 s
#2 1621 MHz 9834630 s 195 s 586046 s 17333636
s 0 s
#3 2148 MHz 9009530 s 104 s 528640 s 18198089
s 0 s
#4 1713 MHz 9196854 s 347 s 548066 s 17992007
s 0 s
#5 1613 MHz 9196227 s 0 s 536888 s 18021111
s 0 s
#6 1635 MHz 9205637 s 156 s 541138 s 17999255
s 0 s
#7 1707 MHz 9807582 s 2816 s 579872 s 17343328
s 0 s
#8 1668 MHz 9519599 s 2155 s 555600 s 17675299
s 0 s
Memory: 23.527812957763672 GB (7618.578125 MB free)
Uptime: 277627.0 sec
Load Avg: 0.11328125 0.02880859375 0.00634765625
WORD_SIZE: 64
LIBM: libopenlibm
LLVM: libLLVM-8.0.1 (ORCJIT, nehalem)
Environment:
LD_LIBRARY_PATH = /home/ezaron/opt/lib
HOME = /home/ezaron
TERM = dumb
PATH =
/home/ezaron/opt/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr\
/local/games:/snap/bin
In version 1.3.1:
julia> versioninfo(verbose=true)
Julia Version 1.3.1
Commit 2d57411 (2019-12-30 21:36 UTC)
Platform Info:
OS: Linux (x86_64-pc-linux-gnu)
Ubuntu 18.04.4 LTS
uname: Linux 5.3.0-61-generic #55~18.04.1-Ubuntu SMP Mon Jun 22
16:40:20 UTC 2020 x86_64 x86_64
CPU: Intel(R) Core(TM) i7-9700K CPU @ 3.60GHz:
speed user nice sys
idle irq
#1 4630 MHz 49652 s 93 s 15769 s 10728212
s 0 s
#2 4674 MHz 47468 s 511 s 15987 s 10712165
s 0 s
#3 4654 MHz 52500 s 99 s 15653 s 10714194
s 0 s
#4 4774 MHz 45689 s 354 s 18438 s 10725210
s 0 s
#5 4751 MHz 48638 s 499 s 16342 s 10728321
s 0 s
#6 4720 MHz 51196 s 46 s 16820 s 10725778
s 0 s
#7 4675 MHz 49516 s 181 s 16707 s 10728269
s 0 s
#8 4616 MHz 46232 s 186 s 22292 s 10720032
s 0 s
Memory: 15.487720489501953 GB (254.50390625 MB free)
Uptime: 108062.0 sec
Load Avg: 0.27685546875 0.19873046875 0.18603515625
WORD_SIZE: 64
LIBM: libopenlibm
LLVM: libLLVM-6.0.1 (ORCJIT, skylake)
Environment:
GLADE_CATALOG_PATH = :
GLADE_MODULE_PATH = :
HOME = /home/ezaron
GLADE_PIXMAP_PATH = :
TERM = dumb
XDG_SEAT_PATH = /org/freedesktop/DisplayManager/Seat0
XDG_SESSION_PATH = /org/freedesktop/DisplayManager/Session0
PATH =
/home/ezaron/opt/bin:/home/ezaron/opt/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
I will experiment with TERM settings to see if I can get the old
behavior and report back here if I find a solution.
Thanks for your help.
…-Ed
On 6/30/20 1:46 PM, Matt Bauman wrote:
Something is likely wrong with your setup. How did you install and
launch Julia? What's the output of |versioninfo(verbose=true)|? Do you
see any warnings upon startup?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#36492 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABD4FGFJBBTFAWDSRLUA2FTRZJFLJANCNFSM4OMUACPA>.
--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Edward D. Zaron
Research Associate Professor
Department of Civil and Environmental Engineering
Portland State University
Portland, OR 97207-0751
Phone: (503)-725-2435
FAX: (503)-725-5950
[email protected]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
I can confirm that the REPL works as expected inside an emacs-term, but it is broken in this regard in an emacs-shell. Manually changing TERM inside the emacs-shell fixes the display truncation behavior, but changes the command-line prompt to gibberish. |
Well that would do it. You're explicitly disabling all the fancy terminal features because your emacs shell doesn't support some of them. You could potentially try |
Solved (mostly): In any case, I will close this issue. Hopefully these notes will be useful to others who like to use emacs as their IDE for developing in julia. |
This indicates that the problem is that |
Thanks for your attention to this. |
fix #36492, ensure output is limited even with basic REPLs
(cherry picked from commit ac57297)
Is the REPL broken in the latest stable version of Julia? In version 1.3.1 I obtained the (expected) truncation of arrays displayed in the REPL. For example, the command
randn(100,100)
displays a truncated set of values.
In Julia versions 1.4.1 and 1.4.2 the same command will attempt to display all 10000 values of this array. Of course, the situation is much worse for huge arrays.
I understand that I can suppress the output with a trailing semicolon, but I preferred the old behavior that displayed a small selection of array values.
displaysize(stdout) returns the value (24, 112), which looks correct to me.
The text was updated successfully, but these errors were encountered: