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

Can't find resyncing instructions #5260

Closed
astrojuanlu opened this issue Feb 9, 2019 · 13 comments
Closed

Can't find resyncing instructions #5260

astrojuanlu opened this issue Feb 9, 2019 · 13 comments
Labels
Support Support question

Comments

@astrojuanlu
Copy link
Contributor

I think that "manually re-syncing" relying on the user is not a solution.

(#5062 (comment))

Talking about "manually re-syncing", the webhooks docs mention

To resync a webhook from Read the Docs, visit the integration detail page and follow the directions for re-syncing your repository webhook.

But I don't see such a thing in, for example, https://readthedocs.org/dashboard/poliastro/integrations/57915/.

@astrojuanlu
Copy link
Contributor Author

In reality, this is a follow-up from my comment at #4450 (comment), since I again pushed a branch to my GitHub repository and the build was not triggered, although the event was received:

https://readthedocs.org/dashboard/poliastro/integrations/57915/exchange/bac1718a-b4f4-4f64-b7a1-1e20dd51e9d5/

@stsewd stsewd added the Support Support question label Feb 9, 2019
@humitos
Copy link
Member

humitos commented Feb 9, 2019

But I don't see such a thing in, for example, readthedocs.org/dashboard/poliastro/integrations/57915.

When I go to my Admin > Integrations > GitHub incoming webhook I see a button there that says "Resync webhook". Does not appear to you? Clicking it should resync the webhook and subscript to the new GH events.

Also, please check that your webhooks in GH are properly configured after that at https://github.com/poliastro/poliastro/settings/hooks

Example,

captura de pantalla_2019-02-09_23-09-19

The first one is the proper one, which is subscribed to create, delete, pull_request and push the second one is the old one. Yours, should look like the first one. Let me know!

@astrojuanlu
Copy link
Contributor Author

When I go to my Admin > Integrations > GitHub incoming webhook I see a button there that says "Resync webhook". Does not appear to you?

Not really:

screenshot_2019-02-09 integration read the docs

My webhook on GH looks like the first one, but it was not subscribed to pull requests, so I amended that already.

@humitos
Copy link
Member

humitos commented Feb 10, 2019

OK! My webhook page looks different

captura de pantalla_2019-02-10_11-41-31

Taking a look at the code, that's because your integration's attribute can_sync is False.

https://github.com/rtfd/readthedocs.org/blob/cb1f941825a320daa321b87d1fd5460badfccd3b/readthedocs/templates/projects/integration_webhook_detail.html#L32-L49

I'm not sure what that means yet

https://github.com/rtfd/readthedocs.org/blob/cb1f941825a320daa321b87d1fd5460badfccd3b/readthedocs/integrations/models.py#L282-L286

I checked the provider_data for your integration and it's ''. So, that's the reason.

Now, I need to find out how '' ended up there. I'll keep you updated.

My webhook on GH looks like the first one, but it was not subscribed to pull requests, so I amended that already.

If only pull requests was missing, I suppose that you still have experimenting the problem of creating a new branch and don't see it reflected on RTD as a Version, right?

@astrojuanlu
Copy link
Contributor Author

I suppose that you still have experimenting the problem of creating a new branch and don't see it reflected on RTD as a Version, right?

Correct! But I guess the culprit is that my webhook is not synced. Thanks for looking into this!

@agjohnson
Copy link
Contributor

The resync option is only available if the webhook was set up using a connected GitHub account. If you disconnected your GitHub account, or reconnected, I'm not sure of the behavior. But, without this connected account, we can't attempt the API operations to resync the webhook, so it's a manual configuration piece that you need to handle on GitHub.

Is you GitHub account connected to your RTD account, and does that GH user have access to the admin of the repository?

@agjohnson agjohnson added the Needed: more information A reply from issue author is required label Feb 13, 2019
@astrojuanlu
Copy link
Contributor Author

@agjohnson I just logged out and logged in with my GH account just to try and it worked, and this user has access to the admin of the repository.

@no-response no-response bot removed the Needed: more information A reply from issue author is required label Feb 13, 2019
@stsewd
Copy link
Member

stsewd commented Feb 20, 2019

We only show this button if the repo was imported using the import from repo option, if the project was manually imported, or the webhook was deleted and add it again, it doesn't show the Resync option.

Probably we can close this in favor of #3932. Or clarify the docs in the meantime.

@humitos
Copy link
Member

humitos commented Feb 21, 2019

Do we have a proposed workaround in the meantime? I'd like to give a solution to @Juanlu001 and other people hitting this problem.

@stsewd
Copy link
Member

stsewd commented Feb 21, 2019

I think there is a confusion with the feature that @Juanlu001 is mentioning

since I again pushed a branch to my GitHub repository and the build was not triggered, although the event was received

We currently listen to create/delete events to update the versions list of a project. Users still need to activate and trigger a build to new branches. If you want that feature, keep an eye in #4001

@stsewd stsewd added the Needed: more information A reply from issue author is required label Feb 28, 2019
@humitos
Copy link
Member

humitos commented Mar 5, 2019

@stsewd oh, I think you are right.

@Juanlu001 the new feature regarding how we handle webhooks on Read the Docs was about "detecting that a new branch/tag was added into the repo and create a Version for it" (not activated --which won't build by default, though). Can you confirm that the new branch created in the repo was automatically detected and added as a version on RTD?

@astrojuanlu
Copy link
Contributor Author

If I recall correctly, the new branch didn't create a new version, although it eventually did when I pushed more commits to it.

If I understand correctly there's some progress in #4001 by @stsewd, so let's revisit this when I branch my project again. If you don't want to keep an issue open until July, let's close it and I will comment here if I have further problems.

@no-response no-response bot removed the Needed: more information A reply from issue author is required label Mar 5, 2019
@stsewd
Copy link
Member

stsewd commented Mar 27, 2019

Maybe it was in a github downtime or in our servers downtime. You can revisit the webhooks page (on github and rtd) to see if the webhook was correctly handled. Let's close this for now, let us know if something doesn't work.

@stsewd stsewd closed this as completed Mar 27, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Support Support question
Projects
None yet
Development

No branches or pull requests

4 participants