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

Adds TorBox Support #946

Open
wants to merge 12 commits into
base: main
Choose a base branch
from
Open

Adds TorBox Support #946

wants to merge 12 commits into from

Conversation

Wamy-Dev
Copy link

@Wamy-Dev Wamy-Dev commented Sep 12, 2024

Allows downloading using TorBox.

  • Accepts and saves TorBox API key as authorization.
  • Adds magnets to TorBox account.
  • Lists TorBox files.
  • Downloads files directly from TorBox (as a zip). This is something that might need a little work. The zips that comes from TorBox are streamed, meaning there is no known completed size. This results in an always 0% progress.

Lemme know if any work needs done. If you want to test, you can sign up with a free account on TorBox.app, or contact me @WAMY on Discord for Pro keys (developers on this pull only).

closes #935
closes #1255

Copy link
Author

@Wamy-Dev Wamy-Dev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a general change. Virtual environments should be ignored.

Copy link
Author

@Wamy-Dev Wamy-Dev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please review these comments

@@ -8,6 +8,11 @@ module.exports = {
"@electron-toolkit/eslint-config-ts/recommended",
"plugin:prettier/recommended",
],
settings: {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was getting build errors if this wasn't done. If it works without it, don't hesitate to remove it.

package.json Show resolved Hide resolved
package.json Show resolved Hide resolved
import { HttpDownload } from "./http-download";
import { GenericHttpDownloader } from "./generic-http-downloader";
import { gameRepository } from "@main/repository";
// import { calculateETA } from "./helpers";
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need for calculating ETA. Left it here in case in the future TorBox gives a definite file size for zips.

numPeers: 0,
numSeeds: 0,
downloadSpeed: status.downloadSpeed,
timeRemaining: -1,
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Time remaining is -1 always. No way to know for sure.

const status = download.getStatus();

if (status) {
let progress =
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Progress is 0 since we can't know the completed file size.

@zamitto
Copy link
Collaborator

zamitto commented Sep 12, 2024

Can't promise we will be able to review and test your PR properly until the next release (this saturday) as we are rushing with it

@Wamy-Dev
Copy link
Author

any update @zamitto ?

@@ -98,6 +98,7 @@ export const Hydra2_0_3: HydraMigration = {
table.text("downloadsPath");
table.text("language").notNullable().defaultTo("en");
table.text("realDebridApiToken");
table.text("torboxApiToken");
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you actually need to create a new migration file, and import it in src/main/knex-client.ts

@kenhendricks00
Copy link

Please implement this, RealDebrid is actively removing torrents and hosters. This will result in it being unusable for Hydra Launcher. There's an influx of RealDebrid users migrating to TorBox.
As support TorBox grows and torrent caches grow, it will become the primary Debrid service people use.

Reference: https://x.com/RealDebrid/status/1859673163681960169

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

Successfully merging this pull request may close these issues.

[REQUEST] Swap RealDebrid Support for TorBox Support [REQUEST] Use TorBox Debrid Instead Of BitTorrent
4 participants