You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I find the behaviour of the --portable/-P flag confusing, and in some cases unintended.
Note that the "portable" Windows exe we distribute works by implicitly setting --portable. The user can also manually set the flag regardless of how they run Electrum.
For context, Electrum normally places its data directory (config file, wallet files, block headers, lightning gossip, etc) at ~/.electrum (or %APPDATA%/Electrum on Windows). The --portable flag is there to change this: if set, Electrum will instead create a folder named electrum_data at ... well it depends, but usually in $PWD (the current working directory).
The current behaviour is as follows:
"pyinstaller" case: portable .exe, other .exes with --portable, and .dmg with --portable
uses $PWD
note that when you double-click the portable .exe on Windows, $PWD is set to the parent folder, i.e. the datadir gets put next to the .exe
pip install *.tar.gz, and calling "electrum --portable" from terminal
uses python's user script directory
~/.local/bin/electrum_data
$VIRTUAL_ENV/bin/electrum_data
I would like to consolidate this... but I realise some users might be relying on current behaviour.
I think the clean solution would be to simply always use $PWD, however, to minimise breakage, I suggest the following:
"pyinstaller" case: portable .exe, other .exes with --portable, and .dmg with --portable
uses $PWD
appimage --portable
(CHANGED) uses $PWD
git clone
next to run_electrum
unpacking tar.gz and running locally from it
next to run_electrum
pip install *.tar.gz, and calling "electrum --portable" from terminal
(CHANGED) uses $PWD
That is, the only breaking change is re the last case, but I hope no one is relying on that ~madness.
The text was updated successfully, but these errors were encountered:
Note: technically this is a breaking change but I think it is ok for it to get included in 4.2.1.
I doubt anyone was relying on behaviour that changed.
I find the behaviour of the
--portable
/-P
flag confusing, and in some cases unintended.Note that the "portable" Windows exe we distribute works by implicitly setting
--portable
. The user can also manually set the flag regardless of how they run Electrum.For context, Electrum normally places its data directory (config file, wallet files, block headers, lightning gossip, etc) at
~/.electrum
(or%APPDATA%/Electrum
on Windows). The--portable
flag is there to change this: if set, Electrum will instead create a folder namedelectrum_data
at ... well it depends, but usually in$PWD
(the current working directory).The current behaviour is as follows:
.exe
, other.exe
s with--portable
, and.dmg
with--portable
$PWD
.exe
on Windows,$PWD
is set to the parent folder, i.e. the datadir gets put next to the.exe
--portable
run_electrum
tar.gz
and running locally from itrun_electrum
pip install *.tar.gz
, and calling "electrum --portable" from terminal~/.local/bin/electrum_data
$VIRTUAL_ENV/bin/electrum_data
I would like to consolidate this... but I realise some users might be relying on current behaviour.
I think the clean solution would be to simply always use
$PWD
, however, to minimise breakage, I suggest the following:.exe
, other.exe
s with--portable
, and.dmg
with--portable
$PWD
--portable
$PWD
run_electrum
tar.gz
and running locally from itrun_electrum
pip install *.tar.gz
, and calling "electrum --portable" from terminal$PWD
That is, the only breaking change is re the last case, but I hope no one is relying on that ~madness.
The text was updated successfully, but these errors were encountered: