Re: [Deluge] #3605: crash when adding multiple magnet links sequentially via webUI

2023-08-02 Thread Deluge
#3605: crash when adding multiple magnet links sequentially via webUI
---+
  Reporter:  working-name  |  Owner:
  Type:  bug   | Status:  new
  Priority:  major |  Milestone:  2.1.1
 Component:  Core  |Version:  2.1.0
Resolution:|   Keywords:  libtorrent, new, crash
---+
Changes (by working-name):

 * version:  2.0.5 => 2.1.0


--
Ticket URL: 
Deluge 
Deluge Project

-- 
You received this message because you are subscribed to the Google Groups 
"Deluge Dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to deluge-dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/deluge-dev/066.5ec55a601c4c362e141d280c9699ea48%40deluge-torrent.org.


[Deluge] #3605: crash when adding multiple magnet links sequentially via webUI

2023-08-02 Thread Deluge
#3605: crash when adding multiple magnet links sequentially via webUI
--+
 Reporter:  working-name  |   Type:  bug
   Status:  new   |   Priority:  major
Milestone:  2.1.1 |  Component:  Core
  Version:  2.0.5 |   Keywords:  libtorrent, new, crash
--+
 Deluge 2.1.1 running from a docker image
 (https://hub.docker.com/r/linuxserver/deluge/)

 libtorrent version: 2.0.8.0

 Operating System and version (no clue, see
 https://hub.docker.com/r/linuxserver/deluge/)

 Browser and version (if using WebUI): Brave Version 1.52.130 Chromium:
 114.0.5735.198 (Official Build) (64-bit)

 Plugins enabled: blacklist (not used actually) and labels.

 Installation method i.e. from source, package or installer: Docker image.



 [[BR]]
 [[BR]]


 Precise steps to reproduce the bug:


 Step 1: start container(s).

 Step 2: add multiple magnet links one after another.

 Step 3: see it crash, logs say something about tracker error.


 These steps assume you have a sizable list of torrents (I'm at about 300
 now).

 They are also not *precise* because the crash is intermittent, and
 sometimes happens when adding a single magnet at a random time during the
 day, too. But for the most part I can make it crash by adding multiple
 sequential magnet links.
 [[BR]]
 [[BR]]


 Deluge Logs (error level is usually fine in first instance):

 {{{
 21:33:49 [INFO][deluge.core.torrentmanager:1622] Torrent (let's
 just say... DMCA would be proud) from user "localclient" added
 Unhandled Error
 Traceback (most recent call last):
   File "/usr/lib/python3.11/site-packages/deluge/core/daemon_entry.py",
 line 119, in run_daemon
 daemon.start()
   File "/usr/lib/python3.11/site-packages/deluge/core/daemon.py", line
 161, in start
 reactor.run()
   File "/usr/lib/python3.11/site-packages/twisted/internet/base.py", line
 1318, in run
 self.mainLoop()
   File "/usr/lib/python3.11/site-packages/twisted/internet/base.py", line
 1328, in mainLoop
 reactorBaseSelf.runUntilCurrent()
 ---  ---
   File "/usr/lib/python3.11/site-packages/twisted/internet/base.py", line
 994, in runUntilCurrent
 call.func(*call.args, **call.kw)
   File "/usr/lib/python3.11/site-packages/deluge/core/torrentmanager.py",
 line 1389, in on_alert_tracker_error
 error_message = decode_bytes(alert.error_message())
 Boost.Python.ArgumentError: Python argument types in
 tracker_error_alert.error_message(tracker_error_alert)
 did not match C++ signature:
 error_message(libtorrent::tracker_error_alert {lvalue})

 Caught SIGTERM signal!
 Tell Deluged to shut down.
 s6-supervise svc-deluged: warning: finish script lifetime reached maximum
 value - sending it a SIGKILL
 }}}


 Information of any errors or traces: not sure how to gdb in that
 container.
 Config files:
 (core.conf):
 {{{
 {
 "file": 1,
 "format": 1
 }{
 "add_paused": false,
 "allow_remote": false,
 "auto_manage_prefer_seeds": false,
 "auto_managed": true,
 "cache_expiry": 60,
 "cache_size": 512,
 "copy_torrent_file": false,
 "daemon_port": 58846,
 "del_copy_torrent_file": false,
 "dht": true,
 "dont_count_slow_torrents": true,
 "download_location": "/downloads",
 "download_location_paths_list": [],
 "enabled_plugins": [
 "Label",
 "Blocklist"
 ],
 "enc_in_policy": 1,
 "enc_level": 2,
 "enc_out_policy": 1,
 "geoip_db_location": "/usr/share/GeoIP/GeoIP.dat",
 "ignore_limits_on_local_network": true,
 "info_sent": 0.0,
 "listen_interface": "",
 "listen_ports": [
 6881,
 6891
 ],
 "listen_random_port": 51765,
 "listen_reuse_port": true,
 "listen_use_sys_port": false,
 "lsd": true,
 "max_active_downloading": 5,
 "max_active_limit": 303,
 "max_active_seeding": 5,
 "max_connections_global": -1,
 "max_connections_per_second": 20,
 "max_connections_per_torrent": -1,
 "max_download_speed": -1.0,
 "max_download_speed_per_torrent": -1,
 "max_half_open_connections": 100,
 "max_upload_slots_global": 250,
 "max_upload_slots_per_torrent": -1,
 "max_upload_speed": 1300.0,
 "max_upload_speed_per_torrent": -1,
 "move_completed": false,
 "move_completed_path": "/downloads",
 "move_completed_paths_list": [],
 "natpmp": true,
 "new_release_check": true,
 "outgoing_interface": "",
 "outgoing_ports": [
 0,
 0
 ],
 "path_chooser_accelerator_string": "Tab",
 "path_chooser_auto_complete_enabled": true,
 "path_chooser_max_popup_rows": 20,
 "path_chooser_show_chooser_button_on_localhost": true,
 "path_chooser_show_hidden_files": false,
 "peer_tos": "0x00",
 "plugins_location": "/config/plugins",
 "pre_allocate_storage": false,
 "prioritize_first_last_pieces": false,
 "proxy": {