clifordsymack / Electron-Cash

Electrum; Bitcoin thin client
MIT License
6 stars 3 forks source link

Issue? Shuffle pool view keeps wallet unlocked when wallet window is closed. #85

Closed emergent-reasons closed 5 years ago

emergent-reasons commented 5 years ago

It's not really a bug, but was surprising behavior. Maybe the pool view is the first non-modal besides the wallets themselves in EC?

I think it would be better if the pool view is not allowed to keep the wallet unlocked.

Steps:

  1. start ec with an encrypted wallet
  2. password to unlock wallet
  3. password to enable cashshuffle
  4. open pool view
  5. close wallet window
  6. restart from 1. and the unlock password step is skipped
cculianu commented 5 years ago

This has nothing to do with pool view window. Nor does it have anything to do with CashShuffle.

t's a "feature" of electron cash and electrum (I'd argue it's a bug, but whatever) -- that your wallets are never closed until you exit the app. If you repeatedly open and close the same wallet window (keep another window open to keep the app alive, though) -- you will see this always happens.

You can do this with regular electron cash too (no CashShuffle) to convince yourself.

emergent-reasons commented 5 years ago

Yes the behavior of EC in terms of wallets is odd but not unexpected. I am saying that the pool window probably should not be considered an entity by itself that is able to keep electron alive. In other words, it would seem logical that closing a wallet would close a pool view that was spawned from it.

I don't think this is a big deal. I just wanted to document it.

On Sat, Mar 2, 2019 at 2:26 AM Calin Culianu notifications@github.com wrote:

This has nothing to do with pool view window. Nor does it have anything to do with CashShuffle.

t's a "feature" of electron cash and electrum (I'd argue it's a bug, but whatever) -- that your wallets are never closed until you exit the app. If you repeatedly open and close the same wallet window (keep another window open to keep the app alive, though) -- you will see this always happens.

You can do this with regular electron cash too (no CashShuffle) to convince yourself.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/clifordsymack/Electron-Cash/issues/85#issuecomment-468743835, or mute the thread https://github.com/notifications/unsubscribe-auth/AgcuZg4XEGkCDaKXMmxsnfVhPVafQ-rMks5vSWLfgaJpZM4bZQot .

cculianu commented 5 years ago

I hear you but -- I can't fix this now due to time constraints.

Prove it to yourself: You can keep Electron Cash (regular, not even CashShuffle) alive by itself with a transaction dialog (open a tx dialog screen and then close your main wallet). Or with the Network Dialog!

I'm not fixing this here -- it's a general Electron Cash "feature" (and Electrum too). I want to focus on CashShuffle stuff.

This would require me spending a few hours testing and figuring out the best way to do it and making sure nothing else broke

But I hear ya -- it's unexpected ..

If you want open a general EC issue about how windows can keep the app alive.... 👍

cculianu commented 5 years ago

General Electron Cash issue tracker: https://github.com/Electron-Cash/Electron-Cash/issues

cculianu commented 5 years ago

Hey @emergent-reasons -- I think I know how to fix this really easily. Fixing now and will push a commit.

cculianu commented 5 years ago

(Fix will only be for pool view windows tho.. general EC bug remains.)

emergent-reasons commented 5 years ago

Nice! Thanks for letting me know. Maybe you have set the precedent that will lead to rational window behavior in EC :D