Julia displays error messages and doesn't display underscores when launched from Juno

When I start Julia from Juno in Atom, I get the following error message:

sh: module: line 1: syntax error: unexpected end of file
sh: error importing function definition for `module'
sh: switchml: line 1: syntax error: unexpected end of file
sh: error importing function definition for `switchml'
Starting Julia...
INFO: Loading HttpServer methods...
               _
   _       _ _(_)_     |  A fresh approach to technical computing
  (_)     | (_) (_)    |  Documentation: https://docs.julialang.org
   _ _   _| |_  __ _   |  Type "?help" for help.
  | | | | | | |/ _` |  |
  | | |_| | | | (_| |  |  Version 0.6.3 (2018-05-28 20:20 UTC)
 _/ |\__'_|_|_|\__'_|  |
|__/                   |  x86_64-redhat-linux

WARNING: Atom.jl: unrecognised message connected.

Interestingly, the underscores are still there (as evidenced by the pasted message above) and they still matter (var_1 is distinct from var 1 even though both display as “var 1”), but just aren’t displayed. Julia seems functional, but I would prefer to correct whatever’s causing the error messages at the beginning.

The only file named “switchml” I can find on my system is in /usr/share/Modules/init/ksh-functions/switchml. I don’t get these errors when I launch Julia from Konsole.

This is on Fedora 28, KDE spin. Any help is appreciated.

Update: I downloaded and installed Julia, Atom, and Juno on another computer running Fedora 28 KDE. With a fresh install, both problems (the error messages and the missing underscores) still persist.

I also downloaded and compiled the source for Julia 1.0.0. Using Julia 1, an error message appeared after downloading and compiling all packages on the first run: WARNING: could not import Base.endof into StringDistances

After stopping and restarting Julia, I don’t get any error messages. Underscores still aren’t displayed.

Additionally, I downloaded the source for Atom and ran the bootstrap script, then started it in dev mode. The bootstrapped version of Atom still gives the “Atom.jl: unrecognised message connected.” warning each time I start Julia 0.6.3, but there are no shell error messages like there are with the version installed via rpm.

The

sh: module: line 1: syntax error: unexpected end of file
sh: error importing function definition for `module'
sh: switchml: line 1: syntax error: unexpected end of file
sh: error importing function definition for `switchml'

error seems similar to this:

which can be resolved be removing scl-utils. You might want to try that.


WARNING: could not import Base.endof into StringDistances and WARNING: Atom.jl: unrecognised message connected. are harmless and can be ignored (and will be fixed with the next release of those packages).


I’m pretty sure this error is unrelated to the ones above. Can you go to Settings -> Editor -> Font Family and a) tell me what it is set to and b) set it to some other font you have installed?

I don’t have scl-utils installed, so I can’t try removing it, unfortunately.

The editor font family is set to Default: Menlo, Consolas, DejaVu Sans Mono, monospace

I tried editing it to use Liberation Sans. Although I have the font installed, the editor will only display Liberation for some reason. Still, underscores are correctly displayed.

Underscores are also correctly displayed for Menlo, Consolas, DejaVu, DejaVu Sans, and monospace. Only when DejaVu Sans Mono is enabled do the underscores disappear.

I tested DejaVu Sans Mono in LibreOffice Writer and Konsole. Both display underscores normally. I even started Julia in Konsole and the ASCII logo is displayed with all underscores intact, no matter what style or font size I select. The issue seems to be with either Atom or Juno.

Alright, I’m afraid you’ll have to use another font for now. This is an upstream issue I can’t really do much about (same thing happens in VSCode too):
https://github.com/xtermjs/xterm.js/issues/1138

I still suspect the sh: error importing function ... error happens because there’s something weird about your system, but am not sure what it could be.