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

[Feature Request] Add torrent dialog for magnet links. #329

Open
testbughub opened this issue Mar 1, 2023 · 12 comments
Open

[Feature Request] Add torrent dialog for magnet links. #329

testbughub opened this issue Mar 1, 2023 · 12 comments

Comments

@testbughub
Copy link

It would be nice to be able to set a category/label before adding a magnet link.

@journeym
Copy link

Yes, please implement auto open advanced dialog on torrent adding / magnet link opening

@journeym
Copy link

journeym commented Aug 2, 2023

I have compiled a version that does it
https://drive.google.com/file/d/1iS_wZHn5EqqpPWDLEiH6vBFIfuKP-J-S/view?usp=sharing

@testbughub
Copy link
Author

I have compiled a version that does it https://drive.google.com/file/d/1iS_wZHn5EqqpPWDLEiH6vBFIfuKP-J-S/view?usp=sharing

Nice! Would you mind forking this repo and commit the changes you did?
Maybe the dev could merge it, and I would also see the changes
so that I can compile a Linux version.

@journeym
Copy link

journeym commented Aug 3, 2023

Just remove if from line

$scope.$on('torrents:add', function(event, item: PendingTorrentUploadItem, askUploadOptions: boolean) {

it should look like this
$scope.$on('torrents:add', function(event, item: PendingTorrentUploadItem, askUploadOptions: boolean) { $scope.pendingTorrentFiles.push(item) $scope.$apply() })

@testbughub
Copy link
Author

Just remove if from line

$scope.$on('torrents:add', function(event, item: PendingTorrentUploadItem, askUploadOptions: boolean) {

it should look like this
$scope.$on('torrents:add', function(event, item: PendingTorrentUploadItem, askUploadOptions: boolean) { $scope.pendingTorrentFiles.push(item) $scope.$apply() })

Couldn't get this to work unfortunately. It just adds it still.
Not sure why though.

@journeym
Copy link

journeym commented Aug 3, 2023

You can try this version https://github.com/journeym/Electorrent

@journeym
Copy link

journeym commented Aug 3, 2023

It wasn't working correctly due to different handling of magnet and torrent links, i have pushed a commit that fixes that, at least fro me on windows, it's now working (wasnt working before) https://github.com/journeym/Electorrent

@testbughub
Copy link
Author

testbughub commented Aug 4, 2023

It wasn't working correctly due to different handling of magnet and torrent links, i have pushed a commit that fixes that, at least fro me on windows, it's now working (wasnt working before) https://github.com/journeym/Electorrent

I just tried it, and it works great,
except for the name of the download which just says "Download location",
but that's such a minor thing that I can't complain about it.
And I had to copy the 'package-lock.json' file from the original Electorrent to get it to compile.
Thank you so much for putting down some time to fix this!
Hopefully we'll get an 'official' patch soon, but this works great for now 😄
Cheers!

@journeym
Copy link

journeym commented Aug 4, 2023

except for the name of the download which just says "Download location",

In the list of torrents after torrent startup name is correct, in the advanced options dialog, i belive, it's not possible to retrieve name for magnet link before the actual download started. At least for me, the dialog looks the same as if i use file > Paste torrent url.
Please add a screenshot.

@testbughub
Copy link
Author

except for the name of the download which just says "Download location",

In the list of torrents after torrent startup name is correct, in the advanced options dialog, i belive, it's not possible to retrieve name for magnet link before the actual download started. At least for me, the dialog looks the same as if i use file > Paste torrent url. Please add a screenshot.

Yeah, it still works even though it doesn't show the torrent name. Imgur

I'm not sure how common it is, but in the magnet links I've seen,
the torrent name is in the URL.

Example;
magnet:?xt=urn:btih:dd8255ecdc7ca55fb0bbf81323d87062db1f6d1c&dn=Big+Buck+Bunny&tr=udp.......

And I also got an error when trying that magnet link (from https://webtorrent.io/free-torrents), but it still works. Imgur

@journeym
Copy link

journeym commented Aug 4, 2023

Yeah, it still works even though it doesn't show the torrent name. Imgur

This looks perfectly normal IMO, i have the same behavior in native client (qbittorrent web gui), when adding magnet links, practically no clients i encountered decode magnet links on the fly just to get torrent name.
Regarding the error this seems to be a variable type problem, i hadn't hit this when testing, seems my magnet links were shorter. Ill check it sometime, i think....

@testbughub
Copy link
Author

Yeah, it still works even though it doesn't show the torrent name. Imgur

This looks perfectly normal IMO, i have the same behavior in native client (qbittorrent web gui), when adding magnet links, practically no clients i encountered decode magnet links on the fly just to get torrent name. Regarding the error this seems to be a variable type problem, i hadn't hit this when testing, seems my magnet links were shorter. Ill check it sometime, i think....

Don't worry about it. Like I said, it works, so no need to dive any deeper :)
Thanks again!

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

2 participants