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

Notify when all the piece hashes are available #7854

Open
glassez opened this issue Feb 9, 2025 · 0 comments
Open

Notify when all the piece hashes are available #7854

glassez opened this issue Feb 9, 2025 · 0 comments

Comments

@glassez
Copy link
Contributor

glassez commented Feb 9, 2025

Users often want to save a .torrent file for torrents added via magnet link.
There is no problem to do this for v1 torrents once the metadata (info-section) is received.
But for v2/hybrid torrents, we have to wait until all the piece hashes are also available, and we don't have a clear indication of this event.

P.S. To be honest, I have no idea of any straightforward way to save .torrent file for v2 torrents. Right now we are relying on the torrent finished event, after which we request torrent_file_with_hashes, which I don't like because it is a blocking call. In addition, we use create_torrent in a deprecated way, which will become unavailable later (BTW, torrent_file_with_hashes should also be deprecated). Otherwise, we should wait for the torrent to finish, then request resume data, and wait for the appropriate alert (along the way, filtering out such alerts that may have been requested earlier than the torrent was finished).

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

No branches or pull requests

1 participant