1
0
Commit Graph

13781 Commits

Author SHA1 Message Date
ghost43
1e34b96725 Merge pull request #7258 from bitromortac/2104-openchannel-7219
kivy: improve openchannel dialog for trampoline
2021-04-30 11:41:27 +00:00
bitromortac
97b31880d7 kivy: improve openchannel dialog for trampoline 2021-04-30 13:32:07 +02:00
ThomasV
7789497140 release script: add username to signature file, upload files into airlock. 2021-04-30 10:27:33 +00:00
ThomasV
2b05615995 Do not perform webserver update from release script.
(see publish.sh and deploy.sh in the electrum-web repo)
2021-04-28 12:37:15 +00:00
SomberNight
1dfa81e7b6 contrib: fix find_restricted_dependencies for deps with version range
New release of pyinstaller (4.3) broke the script (which is used by freeze_packages.sh).

-----

Compare:

$ wget https://pypi.org/pypi/pyinstaller/4.3/json
$ cat json | jq ".info.requires_dist"
[
  "setuptools",
  "altgraph",
  "pyinstaller-hooks-contrib (>=2020.6)",
  "importlib-metadata ; python_version < \"3.8\"",
  "macholib (>=1.8) ; sys_platform == \"darwin\"",
  "pefile (>=2017.8.1) ; sys_platform == \"win32\"",
  "pywin32-ctypes (>=0.2.0) ; sys_platform == \"win32\"",
  "tinyaes (>=1.0.0) ; extra == 'encryption'",
  "pytest (>=2.7.3) ; extra == 'hook_testing'",
  "execnet (>=1.5.0) ; extra == 'hook_testing'",
  "psutil ; extra == 'hook_testing'"
]

$ wget https://pypi.org/pypi/pyinstaller/4.2/json | jq .
$ cat json | jq ".info.requires_dist"
null

$ wget https://pypi.org/pypi/qrcode/6.1/json
$ cat json | jq ".info.requires_dist"
[
  "six",
  "colorama ; platform_system == \"Windows\"",
  "tox ; extra == 'dev'",
  "pytest ; extra == 'dev'",
  "mock ; (python_version < \"3\") and extra == 'dev'",
  "zest.releaser[recommended] ; extra == 'maintainer'",
  "pillow ; extra == 'pil'",
  "pytest ; extra == 'test'",
  "pytest-cov ; extra == 'test'",
  "mock ; (python_version < \"3\") and extra == 'test'"
]
2021-04-26 20:45:40 +02:00
ghost43
de716ab07c Merge pull request #7247 from bitromortac/2104-fix-liquidity-hints
lnworker: fix path_finder access
2021-04-26 15:17:40 +00:00
SomberNight
8bba3b9ef5 network: also clear network.path_finder in stop_gossip
stop_gossip should undo start_gossip

related: #7242
2021-04-26 17:06:52 +02:00
ThomasV
04b1e8718a tx dialog (Qt): if possible, save psbt and fully signed transaction under the same basename. 2021-04-26 12:31:04 +02:00
bitromortac
4cb0b99996 lnworker: fix path_finder access 2021-04-26 08:43:50 +02:00
ThomasV
4411652b1c Merge pull request #7238 from SomberNight/202104_qt_send_max_tooltip
qt send tab: when clicking "Max", show tooltip explaining max amt
2021-04-23 20:22:53 +02:00
SomberNight
86ba37dc1c qt send tab: when clicking "Max", show tooltip explaining max amt
Beginner users often ask why they cannot send their full balance.
Hence, this intends to reduce support load.
In terms of UI, maybe there is a better way to do this but this was
easy to do and still a good first step IMHO.
2021-04-23 17:52:19 +02:00
SomberNight
37bde9baf9 qt: cpfp: fix handling "no dynamic fee estimates"
fixes #7237
2021-04-23 17:27:00 +02:00
ghost43
ecb083b283 Merge pull request #7231 from bitromortac/2104-fix-swap-check
swaps: fix swap sanity check
2021-04-23 12:57:44 +00:00
bitromortac
b97e51dbd8 swaps: fix off-by-one sanity check
Tolerates discrepancies in the swap amount crosschecks. To ensure we
calculate the send/receive amounts correctly we apply a check, using
amount inversion. The inversion is not exact up to +-1 due to used
floor and ceil functions in the methods. They are not invertible,
which is why we relax the check to off-by-ones.
2021-04-23 07:43:36 +02:00
SomberNight
1436760d3d qt coins tab: Ctrl+F now searches the whole prevout string
(not just the truncated string that is displayed in the list)
2021-04-22 20:56:00 +02:00
SomberNight
3b77340671 Qt MyTreeView: rm usages of Qt.UserRole, use explicit roles instead
This is a bit more verbose but it explicitly shows what data is being
used where.

Also rm implicitly setting editable_columns based on stretch_column.
2021-04-22 20:37:14 +02:00
SomberNight
720d60c391 (trivial) rm dead code
follow-up #7152
2021-04-22 17:57:50 +02:00
SomberNight
af44c846cc tests: add test for payto command 2021-04-22 17:13:56 +02:00
ghost43
0f83270053 Merge pull request #7152 from bitromortac/2103-liquidity-hints
Liquidity hints for pathfinding
2021-04-22 14:45:41 +00:00
SomberNight
bb381a263a android build: update p4a/buildozer to latest upstream
Rebased our branches on latest p4a develop HEAD and buildozer master HEAD.

Re `android.allow_backup = False` in buildozer.spec, now that this setting
has been exposed to buildozer.spec (see https://github.com/kivy/buildozer/pull/1206),
we could finally drop a commit from our branch that did the same:
7a7d415d90

Re commenting out `android.arch` in buildozer.spec, we are setting this
via the ENV VAR in make_apk.
2021-04-21 20:04:37 +02:00
ThomasV
8ce94248d4 kivy: update wizard message: pin->password 2021-04-21 10:33:11 +02:00
SomberNight
11bb39ee82 kivy: implement freezing channels 2021-04-19 18:57:47 +02:00
SomberNight
4e0a20ae46 gui messages: mv one more message to messages.py 2021-04-19 18:57:43 +02:00
SomberNight
0ab9687734 kivy: make ActionDropdown disappear when an action is selected 2021-04-19 18:57:39 +02:00
SomberNight
e15a11a437 kivy: use ActionDropdown in ChannelDetailsPopup 2021-04-19 18:04:15 +02:00
SomberNight
b8ec85d615 kivy tx dialog: abstract away ActionDropdown, mv into its own file 2021-04-19 18:01:22 +02:00
SomberNight
b27925c6c5 kivy tx dialog: dscancel btn text was too long
see first part of #6868
2021-04-19 16:40:57 +02:00
SomberNight
4f6c0c2c61 kivy bump fee dialog: handle no dynamic fee estimates
fix #7220
2021-04-19 16:06:43 +02:00
ThomasV
8f95dc2640 Merge pull request #7211 from SomberNight/202104_keep_early_logs
logging: don't lose log messages during early startup
2021-04-18 20:56:24 +02:00
ThomasV
d8c6753e88 Merge pull request #7218 from verretor/2021-04-qrcodes
Avoid hiding QR codes with help_text
2021-04-18 10:52:23 +02:00
Benoit Verret
2cc16f8ed4 Avoid hiding QR codes with help_text
In some situations, if a QR code's data and help_text were too long,
the QR code was unscannable.
2021-04-17 22:54:37 -04:00
ThomasV
7c3f1d9e65 appimage: update libudev-dev package 2021-04-17 12:16:54 +02:00
ThomasV
75d77c55d6 commands, input sanitization: allow 'max' amounts only in specific contexts (payto, paytomany) 2021-04-16 16:03:25 +02:00
SomberNight
7ffb2c3cb0 config: (trivial) add some type hints and rm unused variable 2021-04-15 19:00:46 +02:00
SomberNight
f53f177203 kivy swaps: handle no dynamic fee estimates
fixes #7215
2021-04-15 18:50:54 +02:00
SomberNight
9a38c4d2a1 logging: don't lose log messages during early startup
Previously, during early-startup (until configure_logging(config) is
called in run_electrum),
- the stderr log handler lost all log messages below warning level, and
- the file log handler lost all log messages regardless of log level

We now instead start buffering log messages in memory as soon as
electrum.logging is imported. The buffer is dumped into the
stderr and file log handlers when they are fully set up, and then
the buffer is discarded (and the temporary log handler is removed).

Note that messages are not logged until configure_logging() is called.
Previously WARNING/ERROR messages would get logged immediately to stderr,
but not anymore. This was changed so that the order of the log messages
can be kept intact. (if we log WARNINGs immediately, but need to delay
INFOs until the config is available, messages would either be out of order
or alternatively there would be duplicates)

Relatedly, we now follow the recommendation of the python docs re
logging for libraries [0]: we try to only configure logging if running via
run_electrum (the main script) and not when e.g. a 3rd party script
imports electrum.

[0]: https://docs.python.org/3/howto/logging.html#configuring-logging-for-a-library
2021-04-14 19:14:26 +02:00
SomberNight
6650e6bbae logging: (move-only) move module level code to near the end 2021-04-14 19:13:27 +02:00
SomberNight
67c6f0e1bd wallet: make sure we don't create zero input txs
fixes #7207
2021-04-14 19:08:04 +02:00
SomberNight
7335a584e7 logging: handle "cannot delete old logfile" error
E.g. on Windows, files open in one process cannot be deleted by another process.
With file logging enabled, if an old logfile was open in a text editor,
Electrum could crash during startup.

```
E | __main__ |
Traceback (most recent call last):
  File "...\electrum\run_electrum", line 391, in main
    handle_cmd(
  File "...\electrum\run_electrum", line 403, in handle_cmd
    configure_logging(config)
  File "...\electrum\electrum\logging.py", line 278, in configure_logging
    _configure_file_logging(log_directory)
  File "...\electrum\electrum\logging.py", line 107, in _configure_file_logging
    _delete_old_logs(log_directory)
  File "...\electrum\electrum\logging.py", line 98, in _delete_old_logs
    os.remove(str(f))
PermissionError: [WinError 32] The process cannot access the file because it is being used by another process: '...\\AppData\\Roaming\\Electrum\\testnet\\logs\\electrum_log_20210414T023751Z_25008.log'
```
2021-04-14 05:10:54 +02:00
SomberNight
12fac3a167 fix running with --offline 2021-04-13 19:05:07 +02:00
SomberNight
4e91555d56 appimage build: bundle dependencies of Qt xcb plugin
fixes #7198

We recently bumped the bundled version of PyQt (5.14.2->5.15.4).
It seems the new version has a lot more dynamic dependencies.

From https://doc.qt.io/qt-5/linux-requirements.html :
> From Qt 5.15 onwards, Qt does require libxcb 1.11. Also, the -qt-xcb
> configure option got removed that was bundling some of the libs below.

We are using the prebuilt wheels for PyQt5 from PyPI. Presumably those
had previously been built using the -qt-xcb option.
2021-04-12 18:21:57 +02:00
bitromortac
5e03d751eb lnrouter: add hint timestamp 2021-04-09 11:11:22 +02:00
bitromortac
bc20f57a78 lnrouter: remove blacklist boolean 2021-04-09 11:11:21 +02:00
SomberNight
1d8b1ef698 dnssec: trivial clean-up
- rm unused imports
- mark private API as private
- don't catch BaseException
2021-04-08 19:49:43 +02:00
Alex Recuenco
bc72e0fc15 Prevent spaces from causing issues in make_osx (#7191)
In some places in the script if some directory name had spaces it could cause issues. 

I also added quotes around a few other directory names that currently are hardcoded with names without spaces as a way to prevent any future mishap
2021-04-08 15:12:14 +00:00
ghost43
29d13eb32f Merge pull request #6001 from SomberNight/20200228_make_seed_not_bip39
mnemonic: make sure newly generated seeds are not valid as bip39
2021-04-08 14:27:20 +00:00
SomberNight
9f08293c0e mnemonic: make sure newly generated seeds are not valid as bip39 2021-04-08 16:24:10 +02:00
SomberNight
b7a8b1aae6 prepare release 4.1.2 4.1.2 2021-04-08 15:22:40 +02:00
ThomasV
2c39f0c9c4 fix #7190 2021-04-08 15:12:32 +02:00
ThomasV
842ecd2da6 android Makefile: do not try to deploy and run 2021-04-08 14:55:31 +02:00