greasyfork-org / greasyfork

An online repository of user scripts.
https://greasyfork.org
GNU General Public License v3.0
1.46k stars 435 forks source link

Cannot update my script (502 Gateway Error) #1292

Closed realcoloride closed 2 months ago

realcoloride commented 2 months ago

Hello!

My following script YouTubeDL cannot be updated because every time, I get the same error over and over again. It doesn't matter what I do and how I update the script, I get the same error.

VPN/No VPN doesn't do anything. Logging on/off doesn't do anything. I've tried reviewing my code and same thing. I've waited days to see if it was just a temporary issue, but I've waited long enough and I still have the same error when updating my script.

image

Cheers

JasonBarnabe commented 2 months ago
1.1.1.1 - - [16/Jul/2024:03:59:58 +0000] "POST /fr/scripts/471103-youtubedl/versions HTTP/2.0" 502 568 "https://greasyfork.org/fr/scripts/471103/versions/new" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36"
2024/07/16 03:59:58 [error] 954#954: *536734235 upstream prematurely closed connection while reading response header from upstream, client: 1.1.1.1, server: greasyfork.org, request: "POST /fr/scripts/471103-youtubedl/versions HTTP/2.0", upstream: "http://unix:///www/greasyfork/shared/tmp/sockets/puma.sock:/fr/scripts/471103-youtubedl/versions", host: "greasyfork.org", referrer: "https://greasyfork.org/fr/scripts/471103/versions/new"

I do see see a process crash in the logs, but it has no timestamp or IP address attached. It's possible the script is crashing the JS checking process. Can you provide the content of the script you're trying to post?

realcoloride commented 2 months ago

Hello there again, The content of the script is available here: https://github.com/realcoloride/YoutubeDL/blob/main/youtubeDL.user.js

Cheers

JasonBarnabe commented 2 months ago

I was able to post that without issue - https://greasyfork.org/en/scripts/500866-youtubedl - so not a JS checking problem. Perhaps something specific to your browser or account.

realcoloride commented 2 months ago

Perhaps its the description of the package or the patchnotes?

Try:

# <img src="https://raw.githubusercontent.com/realcoloride/YoutubeDL/main/YoutubeDL.png" alt="YoutubeDL" width="28" height="28"> YoutubeDL - Youtube Video Downloader
### Download YouTube videos in a single click.

### <img src="https://github.com/realcoloride/YoutubeDL/assets/108619637/dd2b0546-a521-4459-b796-5c59ad932c5e" alt="YoutubeDL" width="290" height="274">

🌟 Features:
* 🎥 Download video formats from 144p to 2K* (up to 60 fps)
* 🎵 Download audio format in MP3
* 🔅 Light and dark theme support set automatically
* 📎 Support for embeds, shorts and videos
* 🤙 Simple and non instrusive design and a user-friendly UI
* ❌ No need for extra websites
* 🌟 Support for YouTube shorts, embeds, and YouTube no cookie
* ➕ And a bit more...

\*_Certain providers might not support up to 4K on all videos due to geo-restrictions or other technical issues._

# Demonstration
#### See it in action

![YoutubeDL_demo](https://github.com/realcoloride/YoutubeDL/assets/108619637/b6cc5e64-f199-4675-8beb-fb8bdfec5974)

#### *The icon on the player*

![Icon on the player](https://github.com/realcoloride/YoutubeDL/assets/108619637/93061219-01e6-47b3-8597-03523756e9c1)

### Youtube Shorts

![YouTube Shorts](https://github.com/realcoloride/YoutubeDL/assets/108619637/9463dae9-17a2-41aa-b200-dc221bfeefe1)

# Installation
### 🤐 Before you install...
### \*\* When Tampermonkey prompts you this page, click on **"Always allow all domains"** (bottom button) \*\*
![Allow](https://raw.githubusercontent.com/realcoloride/YoutubeDL/main/allow.gif)
![Allow](https://raw.githubusercontent.com/realcoloride/YoutubeDL/main/allow.png)

## Links
|<img src="https://github.com/realcoloride/YoutubeDL/assets/108619637/17ae24e6-c899-4002-bf43-751196b5cfcd" alt="GreasyFork" width="64" height="64">|**[Install the script on GreasyFork](https://greasyfork.org/scripts/471103-youtubedl)**|
|-|-|
|<img src="https://raw.githubusercontent.com/realcoloride/YoutubeDL/main/tampermonkey.png" alt="Tampermonkey" width="64" height="64">|**[Download the Tampermonkey extension](https://www.tampermonkey.net/)**|
|<img src="https://github.com/realcoloride/YoutubeDL/assets/108619637/32616f4d-d690-44db-897c-12ddfc16e9a1" alt="Support" width="64" height="64">|**[Check out my other scripts](https://greasyfork.org//users/1070263-realcoloride)**|
|<img src="https://raw.githubusercontent.com/realcoloride/YoutubeDL/main/kofi.png" alt="KoFi" width="64" height="64">|**[Support me on Ko-Fi](https://ko-fi.com/coloride)**|
|<img src="https://raw.githubusercontent.com/realcoloride/YoutubeDL/main/github.png" alt="Support" width="64" height="64">|**[Check out my other projects on Github](https://github.com/realcoloride)**|

# Notice
*By installing and using this Tampermonkey script, please be aware that it utilizes website APIs of various YouTube downloading websites. The extension only transmits simple GET and POST requests to these websites without sending or selling any personal data or cookies. Please note that I do not assume any responsibility for the content downloaded or any actions taken by the user.*

***⚠️ This Tampermonkey script is NOT associated with YouTube or other websites.***

# Troubleshooting (READ THIS IF YOU'RE HAVING ISSUES)
|Problem|Solution|
|-|-|
|🙈 Button not appearing?|Try reloading the page.|
|😵‍💫 Tab appearing with a video instead of downloading?|Try doing right click on the video and clicking on **Save video as...**. This happens when the browser has tried everything to download the file but failed, as a backup.|
|⛔ Download keeps failing|This can either be an issue relating to rate limit or your antivirus. Either way, refreshing the page or making an exception (on your antivirus) can sometimes help.|
|🔑 Do you use your own backend for downloading?|No. _The reverse-engineers yearn for the mines._|
|💡 You have an idea, suggestion, or want to share feedback?|Contact me or open an [Issue](/issues/).|
|❓ Other unlisted problems?|Try opening an [Issue](/issues/).|

# Contribute/Support
🚩 Feel free to open an [Issue](https://github.com/realcoloride/TwitterDL/issues) to suggest something, give feedback or other and 
**feel free to put a review on the Greasyfork page and star this repository.** 👍

☕ If you wish to support me, you can send me a coffee on ko.fi: https://ko-fi.com/coloride

# License
🤝 Distributed with the MIT License. (real)coloride - 2023-2024

❤️ If you like this script, please check out [my other Tampermonkey scripts](https://greasyfork.org/users/1070263-realcoloride).

Try with this. If this works for you, I will try to use another browser to submit.

JasonBarnabe commented 2 months ago

No issues with that - https://greasyfork.org/en/scripts/500866-youtubedl

It's possible however that there is an encoding issue somewhere and posting it to GitHub, then me copy and pasting it, makes it not happen.

I would suggest trying to update just the code, then just the additional info, then doing no changes and just pressing update, to see which cases fail.

realcoloride commented 2 months ago

Well, that's odd. I managed to make it update by copy pasting through GitHub. Thank you, but I'm still weirded by why this is happening.

JasonBarnabe commented 2 months ago

My guess would be there's some encoding issue that gets fixed by the process of putting in on GitHub and copy/pasting.

When you were trying and it was failing, were you copy pasting into the text area or doing a file upload?

realcoloride commented 2 months ago

When it was failing I actually tried doing both multiple times, copy pasting & file upload.

JasonBarnabe commented 2 months ago

Another possibility is that you're hitting the rate limiter, possibly due to a user script that's doing something on Greasy Fork? I can see from your IP lots of requests to /scripts/471103-youtubedl/versions.json.

realcoloride commented 2 months ago

Yes. They check the version to see if the script is up to date and puts a yellow text to click to update at the bottom.

JasonBarnabe commented 2 months ago

Alright, well pretty sure that's the issue you're having. It's making requests at too high of a rate and causing your IP to be blocked for short periods. I would recommend reporting this to the author of that script.

realcoloride commented 2 months ago

Thank you again for helping me. I am the author of the script.