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

Greasy Fork userscripts display Error when checking for updates #2447

Closed
BooBerry opened this issue Mar 1, 2019 · 7 comments

Comments

Projects
None yet
4 participants
@BooBerry
Copy link

commented Mar 1, 2019

AG for Windows 7.0 nightly displays Error when checking for updates for userscripts added from Greasy Fork.

Steps to reproduce

  1. Find a userscript on Greasy Fork, e.g. https://greasyfork.org/en/scripts/375183-facebook-unsponsored-fixed
  2. Add it to the extensions
  3. Open AG for Windows, check for updates, watch the Error for the userscript.

Expected behavior

All filters/extensions/userscripts should update or display Up to date.

Actual behavior

All filters/extensions/userscripts except ones from Greasy Fork either update or display Up to date. Instead, the Greasy Fork-hosted userscript displays Error.

Screenshot:

agupdateerror

@adbuker

This comment has been minimized.

Copy link

commented Mar 21, 2019

resolved in adguard-windows/pull-requests/355

@ameshkov

This comment has been minimized.

Copy link
Member

commented May 12, 2019

@BooBerry reports in the chat that the issue still exists

There is no error now, but they aren't getting updated

@BooBerry

This comment has been minimized.

Copy link
Author

commented May 12, 2019

It still exists in perhaps two different ways.

  1. If you install a userscript and that userscript at some point gets updated by the author, the userscript isn't actually updated in AG for Windows. When I say not updated, I mean it displays the old version number (the version you initially installed) and doesn't update when there's an update.

I'm not sure if the userscript is updated and AG for Windows fails to update the version of the userscript in the UI (I need to check this if possible by installing a script, having it update, then editing the script in AG for Windows to check its version number) or if the userscript isn't updated at all. When you check for updates, the userscript shows "Up to date" when clearly this isn't the case.

  1. Take a userscript like https://greasyfork.org/en/scripts/377350-hide-ads-on-facebook and try installing an older version of the userscript, e.g. https://greasyfork.org/en/scripts/377350-hide-ads-on-facebook?version=692429 and then checking for updates in AG for Windows. AG for Windows' update dialog will indeed show Error for this one. Not sure why yet.

EDIT: This second issue is likely because of the source URL used (and being used by AG for Windows to try and update it) isn't a typical URL used for userscripts.

https://greasyfork.org/scripts/377350-hide-ads-on-facebook/code/Hide%20Ads%20on%20Facebook.user.js?version=692429&d=.user.js

Which in turn displays Error when checking for updates. This is likely a different issue altogether and not related to the first issue.

@ameshkov

This comment has been minimized.

Copy link
Member

commented May 12, 2019

Most likely the bug is caused by the absense of @updateURL and @downloadURL in greasyfork userscripts.

In this case, AG must be using the original source URL (or file path if the userscript is installed from a local file).

@BooBerry

This comment has been minimized.

Copy link
Author

commented May 12, 2019

Okay, I just posted my own test userscript on GreasyFork and pushed a couple updates... and AG for Windows 7 updates them correctly. Odd that the other ones I used didn't update, but I'll keep watching the other userscripts I use for updates and see if they actually update and hope this was just a fluke.

@adbuker

This comment has been minimized.

Copy link

commented May 13, 2019

Most likely the bug is caused by the absense of @updateURL and @downloadURL in greasyfork userscripts.

In this case, AG must be using the original source URL (or file path if the userscript is installed from a local file).

In fact, we do so. I'll retry with the specified script again (hide-ads-on-facebook).

@adbuker

This comment has been minimized.

Copy link

commented May 14, 2019

resolved in adguard-windows/pull-requests/452/

@zzebrum zzebrum closed this May 31, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.