Skip to content

Fix bug: duplicate slash in torrent announce URL#630

Merged
josecelano merged 5 commits intotorrust:developfrom
josecelano:628-remove-duplicate-slash-in-tracker-url-inside-to-downloaded-torrent-file
Jun 11, 2024
Merged

Fix bug: duplicate slash in torrent announce URL#630
josecelano merged 5 commits intotorrust:developfrom
josecelano:628-remove-duplicate-slash-in-tracker-url-inside-to-downloaded-torrent-file

Conversation

@josecelano
Copy link
Copy Markdown
Member

@josecelano josecelano commented Jun 11, 2024

When the tracker runs in private mode the announce URL in the torrent file includes a double slash /. For example:

http://tracker:7070//KEY

Subtasks

  • Scaffolding to run E2E tests with tracker in private mode. We have been running E2E tests only for public mode so far.
  • Add a failing test.
  • Fix the failing test.
  • Simplify config files removing defaults options.

@josecelano josecelano self-assigned this Jun 11, 2024
@josecelano josecelano added the Bug Incorrect Behavior label Jun 11, 2024
…unce URL

When the tracker is running in private mode the announce URL in the
torrent file includes a double slash '/'. For example:

http://tracker:7070//KEY

This commit adds a failing test.

It needed scaffolding to run E2E tests with a tracker running in
"private" mode. We have been only running E2E tests for public trackers so
far. The new tests is only execute with Sqlite3. It would be easy to run
it also for MySQL. It was not cinluded in order to avoid making tests to
slow. It requires to start the docker E2E shared environment twice (for
public and private tracker configurations).
@josecelano josecelano force-pushed the 628-remove-duplicate-slash-in-tracker-url-inside-to-downloaded-torrent-file branch from 9ea88b9 to 96269cd Compare June 11, 2024 15:43
Runnint the tracker in private mode the announce URL in the torrent file
should be:

http://tracker:7070/TRACKER_USER_KEY

instead of:

http://tracker:7070//TRACKER_USER_KEY
@josecelano josecelano force-pushed the 628-remove-duplicate-slash-in-tracker-url-inside-to-downloaded-torrent-file branch from a933119 to f0a5006 Compare June 11, 2024 16:28
@josecelano josecelano marked this pull request as ready for review June 11, 2024 17:00
@josecelano josecelano requested a review from da2ce7 June 11, 2024 17:00
@josecelano
Copy link
Copy Markdown
Member Author

ACK 784ac54

@josecelano josecelano merged commit 32542e9 into torrust:develop Jun 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Bug Incorrect Behavior

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Remove duplicate slash / in tracker URL inside to downloaded torrent file

1 participant