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

Sync Script doesn't seem to work with description #1756

Open
NatoBoram opened this issue Sep 9, 2020 · 5 comments
Open

Sync Script doesn't seem to work with description #1756

NatoBoram opened this issue Sep 9, 2020 · 5 comments
Labels
enhancement Something we do have implemented already but needs improvement upon to the best of knowledge.
Milestone

Comments

@NatoBoram
Copy link

NatoBoram commented Sep 9, 2020

Hi!

I've imported a script from GitHub and enabled the Webhook. However, when I publish changes and click on "Edit script info", the old info is still here.

The webhook have a response 200, but nothing changed on the website.

Date: Wed, 09 Sep 2020 14:41:51 GMT
Strict-Transport-Security: max-age=31536000000; includeSubDomains
Vary: X-HTTP-Method-Override
X-Powered-By: Express

GitHub | OpenUserJS

Martii added a commit to Martii/UserScripts that referenced this issue Sep 9, 2020
@Martii
Copy link
Member

Martii commented Sep 9, 2020

The webhook have a response 200, but nothing changed on the website.

We don't usually send a 200 ever for a push delivery. Please recheck your webhook log here on GH and post the correct status code preferably with a clipped screenshot. Same goes for your webhook settings. So far this is an "Invalid" label but I'm usually open to additional debug checking.

This is as you i.e. no tracked Syncs which indicates your webhook isn't setup correctly:
NatoBoram_20200909_185241

This is me with my test that I did referenced right above this comment:
Marti_20200909_185807

@Martii
Copy link
Member

Martii commented Sep 9, 2020

However, when I publish changes and click on "Edit script info", the old info is still here.

Btw we don't sync https:/NatoBoram/youtube-comment-blacklist/blob/master/README.md with your Script user content area and it's highly unlikely that it will be added.


See also:

@NatoBoram
Copy link
Author

NatoBoram commented Sep 10, 2020

Right, the 202 was too small to read!

Here's my settings :

image

image

Thanks for the help!

It's a shame for README.md sync though.

@Martii
Copy link
Member

Martii commented Sep 10, 2020

Well from the screenshot it appears to be correct for the webhook.

A couple of things usually for this part to work:

  1. Import the source to OUJS first.
  2. Establish the webhook (if you haven't already).
  3. Push a change to GH but remember they have rate limiting in effect. So if you push one and we receive that sync request we process it. If GH receives another push from you too soon they cache the old source and that's all we can retrieve from the raw path. i.e. wait at least two minutes between pushing changes to GH. We detect if there is no change to the source and ignore the update if we get the same code back.

We've also had a node bug lately that's freezing up the sites process that I'm tackling every day... so there is a small possibility that a Sync may not show up if the server is in a frozen/stuck CPU state. In that case "Redeliver" it from GH if it's not showing up on OUJS Sync list. The GH icon on a mouse hover on OUJS shows the unique id that GH sends (in this hooks case it's the 14822180-f2d9-11ea-8c87-91127d3334d5 with the little box to the left). This particular feature is a new implementation to help Authors pin down an issue.

Syncing documents aren't completely out of the question but a lot of that issue I mentioned is dated. We will never allow a non-owned repo to sync a .md file; There's still the issue of case-insensitive; There's still the issue of which one depending on how the repo is crafted; etc. So it's not a high priority atm. Since Jerone closed his issue I'll keep this one open for long term but realize stability of the site is more paramount. We are currently in a "Soft Blocking" state which means most new features will be on the back-burner. I'm having to go over the code and our deps almost constantly to figure out the freeze. I just got logs for the one we had today and as usual it's not very helpful yet. *crosses fingers*.

On a completely unrelated note:

While I have your attention if you are running dev locally please update it to the latest HEAD. We got an email that said your account was accessing a deprecated GH route that was already fixed.

@Martii Martii added the enhancement Something we do have implemented already but needs improvement upon to the best of knowledge. label Sep 10, 2020
@Martii Martii added this to the Beyond milestone Sep 10, 2020
@NatoBoram
Copy link
Author

While I have your attention if you are running dev locally please update it to the latest HEAD. We got an email that said your account was accessing a deprecated GH route that was already fixed.

I didn't run this project locally, I just logged in using the website's "Add new default preferred" feature. Is that a recent change?

There's still the issue of which one depending on how the repo is crafted

One solution would be to add a setting on the script's page to indicate which file to use

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Something we do have implemented already but needs improvement upon to the best of knowledge.
Development

No branches or pull requests

2 participants