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

Consistent #EXTINF Segment Errors and HTTP 400 Responses in twspace_dl During Twitter Spaces Downloads #110

Open
rasrobo opened this issue Apr 30, 2024 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@rasrobo
Copy link

rasrobo commented Apr 30, 2024

Certainly! Here's the revised bug report with all specific references sanitized for privacy and general use:


Describe the bug

When attempting to download Twitter Spaces recordings using twspace_dl, multiple errors occur related to HLS segment processing. Specifically, the tool consistently fails to get the correct #EXTINF value for segments, defaulting to 1ms. Additionally, HTTP 400 errors are encountered when trying to access segments, resulting in failed downloads. This issue has been observed across multiple Space recordings on different days, suggesting a systemic issue with the tool or its interaction with Twitter's HLS streams.

To Reproduce

twspace_dl -i 'https://twitter.com/i/spaces/1LyxBnrkXOjxN' -o '/path/to/output/2024-04-16.m4a' --input-cookie-file /path/to/cookie/x_cookie.txt

Expected behavior

The Twitter Space is expected to be downloaded successfully without errors, and the segments are processed correctly without any #EXTINF or HTTP errors.

Output

If applicable, add the output of the command to help explain your problem.

[hls @ 0x5651ed96f500] Cannot get correct #EXTINF value of segment https://prod-ec-us-east-1.video.pscp.tv/Transcoding/v1/hls/V-oYC3Lvi69nc7JhfanD_NxSkHLsGRNkw7-Lzyw3afDG28yvwgf9W5ZaemyIbnoTg5tm4DA9JErvkp0phrrTHQ/non_transcode/us-east-1/periscope-replay-direct-prod-us-east-1-public/master_dynamic_16733460512549281898.m3u8?type=replaychunk_1713269164294234457_133_a.ts, set to default value to 1ms.

Desktop (please complete the following information):

  • OS: Ubuntu
  • Version: 22.04.4 LTS
  • Installation method: pip

Additional context

The cookie file used has been verified to be valid and works for other downloads, ruling out authentication issues. The issue persists across multiple recordings and on different days, indicating it is not isolated to a single instance. Network configuration has been checked and does not appear to affect the outcome.


This version removes specific references and uses placeholders where appropriate, making the bug report suitable for broader sharing while protecting sensitive details.

@rasrobo rasrobo added the bug Something isn't working label Apr 30, 2024
@rasrobo
Copy link
Author

rasrobo commented Apr 30, 2024

Yes, the error messages you've provided from your latest attempt to download a Twitter Space are indeed similar to those reported in the bug report. They involve issues with getting the correct #EXTINF values for HLS segments and encountering HTTP 400 errors. These symptoms are consistent with the issues you've been experiencing with the twspace_dl tool, suggesting that these problems are recurring and affect multiple downloads.

Here’s how you can add another sighting of the issue to your bug report on GitHub, keeping the information sanitized:


Additional Sighting:

  • Date of Occurrence: 2024-04-22
  • Command Used:
    twspace_dl -i 'https://twitter.com/i/spaces/1ypKdkYaEdQxW' -o '/path/to/output/2024-04-22.m4a' --input-cookie-file /path/to/cookie/x_cookie.txt
  • Errors Encountered:
    [hls @ 0x5640a8959500] Cannot get correct #EXTINF value of segment https://prod-ec-us-east-1.video.pscp.tv/Transcoding/v1/hls/i6d5o23l57tQBU3HLV9Idb8fiGYS5MjWBxTxIcqFCZAth8b15ROGNElKq0n_dktackfcdJ6wgpjNUT8UElqcPw/non_transcode/us-east-1/periscope-replay-direct-prod-us-east-1-public/master_dynamic_16732947700106950497.m3u8?type=replaychunk_1713787724796406133_194_a.ts, set to default value to 1ms.
    [hls @ 0x5640a8959500] Cannot get correct #EXTINF value of segment https://prod-ec-us-east-1.video.pscp.tv/Transcoding/v1/hls/i6d5o23l57tQBU3HLV9Idb8fiGYS5MjWBxTxIcqFCZAth8b15ROGNElKq0n_dktackfcdJ6wgpjNUT8UElqcPw/non_transcode/us-east-1/periscope-replay-direct-prod-us-east-1-public/master_dynamic_16732947700106950497.m3u8?type=replaychunk_1713788270890773621_466_a.ts, set to default value to 1ms.
    [https @ 0x5640a8ba5900] HTTP error 400 Bad Request
    [hls @ 0x5640a8959500] Failed to open segment 0 of playlist 0
    [https @ 0x5640a8e86140] HTTP error 400 Bad Request
    [hls @ 0x5640a8959500] Failed to open segment 1 of playlist 0
    [https @ 0x5640a8bded40] HTTP error 400 Bad Request
    [hls @ 0x5640a8959500] Failed to open segment 2 of playlist 0
    [https @ 0x5640a8bd7600] HTTP error 400 Bad Request
    

This addition provides another instance of the issue, strengthening the case for systemic problems with the tool, which can help the developers in troubleshooting and resolving the issues more effectively.

@alimirjahani7
Copy link

I thinks I can help a little as I tried to fix my code
In the sample I saw the spaces that have videos in them have different structure of files and m3u8 file which this code don't support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants