Open scossu opened 1 year ago
I retried this with a vanilla Archlinux docker image, installing just Python 3.9, Node 16, etc. It builds now. This means that something in my user startup scripts might be causing the problem. I'll try now with a new user on my native OS to confirm this is indeed the case.
Maybe I can focus further on the problematic bits so we can decide whether I have a non-standard setup or if it's a standard setup that's causing invenio-cli to misbehave.
Confirmed that a new user without customized .bashrc and .profile* works.
I found the problem, but I don't have a solution.
The lines here run a non-interactive IPython shell, which on exit leaves some junk characters. These characters are caused by a setting in my home folder:
$ ipython --show-config
Python 3.9.17 (main, Aug 18 2023, 15:45:01)
Type 'copyright', 'credits' or 'license' for more information
IPython 8.14.0 -- An enhanced Interactive Python. Type '?' for help.
Loaded config files:
/home/stefano/.ipython/profile_default/ipython_config.py
TerminalInteractiveShell
.editing_mode = 'vi'
this difference shows when I run
ipython -c "print('hello')" | less
in the same virtualenv. (without piping to less the junk won't show as it's not printable)
By removing the editing_mode = 'vi'
option, the install script runs just fine. However, I don't want to change my config just to install a software package.
I tried passing the option --quick
to IPython, which doesn't load my configuration, and that seems to work. But if I add the same option to the install script, for some reason it will still produce the wrong output.
Is it necessary to use IPython as the default shell to run non-interactive commands? Or is there another way to get the Flask app context within the install script?
Package version (if known): Python 3.9.17 Node 14.21.3 npm 6.14.18 invenio-cli 1.1.0 Invenio 11.0
Describe the bug
Running
invenio-cli install
after running cookie cutter for Invenio 11.0 results in the following error:The problem is that
scheme.config
is in a folder that got created with a strange path:That folder got created along with a "normal" seeming folder:
It looks like the script is having some issues escaping path names.
Steps to Reproduce
In Archlinux + bash:
Expected behavior
Invenio install should complete with out errors.