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

🚚 Add sleeps to daily Weblate Update script #5737

Merged
merged 1 commit into from
Sep 2, 2024
Merged

Conversation

rix0rrr
Copy link
Collaborator

@rix0rrr rix0rrr commented Sep 2, 2024

It seems that wlc commit followed by wlc push doesn't always create a PR (WeblateOrg/weblate#12400). This is the cause of the Weblate repository sometimes being locked without ever getting unlocked: unlocking happens on the PR-close workflow, but the PR never gets created.

In fact, since we also run a wlc reset to avoid future merge conflicts, the wlc reset destroys all pending translator changes, which has happened to some contributors and now their work is gone.

Add some sleeps to get a (presumably) async commit process to finish, and do an additional check for the push flag to reduce chances of data loss.

How to test

This is hard to test in isolation. We'll just have to monitor the GitHub Workflow runs over the next couple of days.

It seems that `wlc commit` followed by `wlc push` doesn't always create
a PR (WeblateOrg/weblate#12400). This is the cause of the Weblate
repository sometimes being locked without ever getting unlocked:
unlocking happens on the PR-close workflow, but the PR never gets
created.

In fact, since we also run a `wlc reset` to avoid future merge conflicts,
the `wlc reset` destroys all pending translator changes, which has
happened to some contributors and now their work is gone.

Add some sleeps to get a (presumably) async commit process to finish,
and do an additional check for the `push` flag to reduce chances
of data loss.
Copy link
Member

@jpelay jpelay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will try to translate something in Spanish and see if things work out!

Copy link
Contributor

mergify bot commented Sep 2, 2024

Thank you for contributing! Your pull request is now going on the merge train (choo choo! Do not click update from main anymore, and be sure to allow changes to be pushed to your fork).

@mergify mergify bot merged commit 46a3a17 into main Sep 2, 2024
12 checks passed
@mergify mergify bot deleted the weblate-no-reset branch September 2, 2024 16:37
@jpelay
Copy link
Member

jpelay commented Sep 3, 2024

I tested a bit and my comments are in the PR, so I think this worked?

@rix0rrr
Copy link
Collaborator Author

rix0rrr commented Sep 3, 2024

Yeah but the failure rate is about 1 in 10, so that's no guarantee unfortunately :(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants