Disable the testing with seo.com as the site certificate has expired.
Ideally should not be testing against live sites and instead use request
replay tool such as VCR.py.
The bad host id error usually occurs on webui when the 'default_daemon'
key in web.conf does not exist in hostlist.conf.
Added a errback method to output a more useful log message.
Removed previous workaround to ensure sync of file priorities with
libtorrent. This did not work when loading torrents as the status is
called before setting the file priorites and resets them to default.
Removed the call to set_file_priorities when writing the torrent file
to disk as it resets the options to default so although the torrent
file priorities do not change, the priorities for UIs is incorrect.
Replace the 'D' header with an unsigned byte that indicates the protocol version. This will allow easier changes to protocol in the future.
Replace the signed integer used for message length with an unsigned 32-bit integer. There is no need for a signed value here as a message length must always be positive. This also doubles the max message length.
- On Python 3 find_msvcrt returns None and _wputenv should be used with
unicode strings.
- Removed the alternative msvcrt set env since `cdll.msvcrt` should suffice.
- Removed the broad exception catching.
The main issue here is a user trying to start deluge and the XDG
`user-dirs.dirs` file contains dir names with non-ascii chars causing
a UnicodeDecodeError when comparing with unicode chars since Py2
default encoding is ascii.
The solution is to use io.open as used elsewhere in code with
encoding set to utf8. Applied to all usage of open in common.
When showing the main_window, Add dialog or file manager windows they
would not appear at the top of the display stack, always one below.
This is due to needing the windowing timestamp to be passed when making
these calls. The recommended Gtk solution to use present_with_time and
use an event.time timestamp. However, this does not always work so
instead used the lower level Gdk set_user_time and fetch timestamp from
X11 server.
Notes:
- Using int(time.time()) for timestamp is not correct as the
windowing timestamp is different.
- Gtk.get_current_event_time only works when there is an event being
processed.
- It might be useful for non-X11 windowing systems to store event
timestamps so that we have a value to use instead of 0.
- Fixed the sidebar position not being restored by applying the config
value in main_window first_show and updating config in position
callback.
- Renamed the main_window vpaned and hpaned widgets to aid identifying
purpose.
- Fixed filtertreeview KeyError when not conneted and hiding tabsbar.
- Fixed the tabsbar notebook not being hidden on restart by adding a
new config value.
When not connected the tray preferences should still be available.
There is no need to have the `is_connected` applied to widget
sensitivity here as that is set elsewhere in the code.
- Fixed the core not correctly settings the current file_priority
settings and added a test.
- Fixed the console not setting file priorities.
- Change the label for not downloading of a file to 'Skip'.
If the torrent.state was corrupted then loading would create a new
state with no backup to examine.
The solution is to use the archive function to save a copy of the
torrent.state.
Added a message argument to archive_files so that the error message
with a reason for archiving can be included in the tarball.
Users encounter issues when trying to install plugins with differing
python versions. If the plugin was built with Py2.6 but they are using
Py2.7 the plugin would not load. With the move to Python 3 this could
become more of an issue. The workaround is to let the plugin manager
to try to load the deluge plugin regardless of the python version it
was built with.
This will put the onus on plugin author to keep the plugin code
compatible with more Python versions.
There were issues with dependencies and tox environments under Python 3
so refactored the tox configuration to be more consistent and clearer.
- Moved travis to default to Python 3 for linting and tests.
- Fixed missing mock for cairo in sphinx config.
- Collated the base deps sections to improve readability.
- Added PYTEST_ADDOPTS env to override pytest verbosity in just tox
tests as this was a common option being used.
- Renamed env 'testcoverage' to the more concise 'coverage' and moved
html creation under single env as handy to have this output as well
as report.
- Cleaned up the isort config for gtk3.
- Added `bad-continuation` to pylint config as conflcts with black
formatting.
- Fix isort issue with bbfreeze script. This will likely be removed
in future so just skip sorting it.
To ensure properties are updated this is a simple open and save with the
glade designer. Always a bit messy with the diff but should not
change functionality.