Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[7.9.0] OptimisticCheckError: Object ChannelMetadata was updated outside of current transaction #6115

Closed
kozlovsky opened this issue May 17, 2021 · 2 comments
Assignees
Milestone

Comments

@kozlovsky
Copy link
Contributor

Traceback (most recent call last):, 
  File "lib\asyncio\events.py", line 81, in _run, 
  File "ipv8\taskmanager.py", line 131, in done_cb, 
  File "src\tribler-core\tribler_core\modules\metadata_store\gigachannel_manager.py", line 99, in check_and_regen_personal_channel_torrent, 
  File "ipv8\taskmanager.py", line 131, in done_cb, 
  File "src\tribler-core\tribler_core\modules\metadata_store\gigachannel_manager.py", line 85, in regenerate_channel_torrent, 
  File "<string>", line 2, in consolidate_channel_torrent, 
  File "lib\site-packages\pony\orm\core.py", line 515, in new_func, 
  File "src\tribler-core\tribler_core\modules\metadata_store\orm_bindings\channel_metadata.py", line 209, in consolidate_channel_torrent, 
  File "src\tribler-core\tribler_core\modules\metadata_store\orm_bindings\channel_metadata.py", line 207, in update_timestamps_recursive, 
  File "src\tribler-core\tribler_core\modules\metadata_store\orm_bindings\channel_node.py", line 220, in sign, 
  File "src\tribler-core\tribler_core\modules\metadata_store\orm_bindings\channel_node.py", line 182, in _serialized, 
  File "lib\site-packages\pony\orm\core.py", line 5472, in to_dict, 
  File "lib\site-packages\pony\orm\core.py", line 1896, in flush, 
  File "lib\site-packages\pony\orm\core.py", line 5421, in _save_, 
  File "lib\site-packages\pony\orm\core.py", line 5332, in _save_updated_, 
  File "lib\site-packages\pony\utils\utils.py", line 106, in throw, 
pony.orm.core.OptimisticCheckError: Object ChannelMetadata[75] was updated outside of current transaction. Changes: infohash (b'V\x1d\x7f\xef\xb3z{\x91::g>\xbe2\xc4\xfcO\xdb\xf2\x16' -> b'(\xbah\xf5\x1b3\xd1`x\xcd\xb2l\x0e\xc0\x90\xba\x8c3, 
\xdd'), torrent_date (datetime.datetime(2021, 5, 3, 4, 43, 48) -> datetime.datetime(2021, 5, 9, 16, 50, 46))

The reason is incorrect db_session handling in regenerate_channel_torrent, I'll fix this.

@kozlovsky kozlovsky added this to the 7.10.0 May milestone May 17, 2021
@kozlovsky kozlovsky self-assigned this May 17, 2021
@sentry-for-tribler
Copy link

Sentry issue: TRIBLER-53

@sentry-for-tribler
Copy link

Sentry issue: TRIBLER-LEGACY-AF

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

1 participant