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

Translations update from Weblate #3792

Merged
merged 77 commits into from
Dec 15, 2020

Conversation

weblate
Copy link
Collaborator

@weblate weblate commented Dec 4, 2020

Translations update from Weblate for CircuitPython/main.

Current translation status:

Weblate translation status

hierophect and others added 30 commits November 3, 2020 16:31
Currently translated at 100.0% (875 of 875 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/pt_BR/
Currently translated at 3.7% (33 of 875 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/cs/
Currently translated at 99.7% (873 of 875 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/sv/
Currently translated at 100.0% (875 of 875 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/sv/
Enhance debug log for wifi scan, sta_start, sta_stop
…n-available

Make ResetReason and RunReason available
Also print backtrace before reset when DEBUG. This will help debug
safe mode issues which calls reset.
It seems that this warning no longer applies.
Remove warning about lack of support on M0 from rotaryio
@tannewt
Copy link
Member

tannewt commented Dec 15, 2020

Is Weblate rebasing and merging? That could cause this weird commit history.

tannewt and others added 5 commits December 14, 2020 17:32
esp32s2: Reserve UART pins only if DEBUG=1 is set to address issue 3811
alarm.sleep_memory + alarm.wake_alarm
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/
@jepler
Copy link
Member

jepler commented Dec 15, 2020

At this time, weblate is configured to merge origin/main into its pull requests whenever main is updated. Several months ago you requested that I change it to merging instead, so that the history of Github Actions on the PR could be more clearly seen. However (and I don't know if there's something specific to how weblate is operating here), github is displaying the result confusingly, and in particularly it shows lots of commits that occurred on the main branch as though they are part of this PR.

I did verify that weblate has not taken rebased copies of these commits from main onto its PR. Locally, git has no problem showing that the only commits in this branch not in main are translation changes and merges of main; and that the only content changes are within locale/:

$ git fetch origin; git fetch-pr 3792; git log --oneline origin/main..FETCH_HEAD ; git diff --stat origin/main FETCH_HEAD
From https://github.com/weblate/circuitpython
 * branch                weblate-circuitpython-main -> FETCH_HEAD
9fd652111 Update translation files
f267c327b Merge branch 'origin/main' into Weblate.
2c4b1f251 Merge branch 'origin/main' into Weblate.
1bacfacfb Merge branch 'origin/main' into Weblate.
b98da3d89 Merge branch 'origin/main' into Weblate.
9acdd91c9 Merge branch 'origin/main' into Weblate.
54fcf127c Merge branch 'origin/main' into Weblate.
4becc00a7 Merge branch 'origin/main' into Weblate.
8d9d53a07 Translated using Weblate (Portuguese (Brazil))
8b98867f0 Merge branch 'origin/main' into Weblate.
6af532f4f Merge branch 'origin/main' into Weblate.
cea6c3d8d Update translation files
fea25c1c5 Merge branch 'origin/main' into Weblate.
a3fc20df0 Merge branch 'origin/main' into Weblate.
0ff0bb9ec Translated using Weblate (French)
f26100408 Merge branch 'origin/main' into Weblate.
a31fc3b08 Merge branch 'origin/main' into Weblate.
3b5be929e Merge branch 'origin/main' into Weblate.
458f55714 Merge branch 'origin/main' into Weblate.
4e7668d69 Merge branch 'origin/main' into Weblate.
ac8a9625d Translated using Weblate (Swedish)
bb1b2bd78 Translated using Weblate (Swedish)
e58c3852f Merge branch 'origin/main' into Weblate.
11d829e20 Translated using Weblate (Czech)
db04582af Translated using Weblate (Portuguese (Brazil))
 locale/ID.po             | 41 +++++++++++++++++++++---------
 locale/cs.po             | 60 ++++++++++++++++++++++++++-----------------
 locale/de_DE.po          | 41 +++++++++++++++++++++---------
 locale/el.po             | 34 +++++++++++++++++--------
 locale/es.po             | 39 ++++++++++++++++++++--------
 locale/fil.po            | 41 +++++++++++++++++++++---------
 locale/fr.po             | 52 +++++++++++++++++++++++++-------------
 locale/hi.po             | 34 +++++++++++++++++--------
 locale/it_IT.po          | 39 ++++++++++++++++++++--------
 locale/ja.po             | 39 ++++++++++++++++++++--------
 locale/ko.po             | 34 +++++++++++++++++--------
 locale/nl.po             | 41 +++++++++++++++++++++---------
 locale/pl.po             | 39 ++++++++++++++++++++--------
 locale/pt_BR.po          | 66 +++++++++++++++++++++++++++++++-----------------
 locale/sv.po             | 64 +++++++++++++++++++++++++++++-----------------
 locale/zh_Latn_pinyin.po | 39 ++++++++++++++++++++--------
 16 files changed, 484 insertions(+), 219 deletions(-)

We can switch weblate back to using rebase behavior if the way that github displays the repeatedly-merged branch is more troublesome than the original problem of being unable to see the history of Actions on the branch due to rebasing.

@jepler jepler merged commit b810b38 into adafruit:main Dec 15, 2020
@tannewt
Copy link
Member

tannewt commented Dec 15, 2020

Thanks for looking again. I'm aware I wanted the switch. I'll need to look into why github is doing this.

I think merge is still best because we can then see CI history. With rebase we lose access to previous CI runs.

@jepler
Copy link
Member

jepler commented Dec 17, 2020

Since we've eliminated the obvious on our end and at weblate, I've submitted a github ticket--I don't think it is viewable by the public but it is "Pull request displaying incorrectly #946332" and the link that works for me is https://support.github.com/ticket/personal/0/946332

In certain PRs, we get a different (incorrect) view of the changes in the PR, compared to on the git commandline.

One such PR is #3792

It shows commits such as 472a5a9 as though they were a part of this PR. However, this commit was added on the main branch and brought into this PR by merging main into it.

When visualized from the commandline subsequent to being merged into main,

jepler@babs:~/src/circuitpython$ git show b810b384c
commit b810b384c9795ae1b514aef451e9952115cf2395
Merge: d07629665 9fd652111
Author: Jeff Epler <jepler@gmail.com>
Date:   Tue Dec 15 08:07:22 2020 -0600

    Merge pull request #3792 from weblate/weblate-circuitpython-main
    
    Translations update from Weblate

jepler@babs:~/src/circuitpython$ git log --oneline  d07629665..9fd652111; git diff --stat d07629665..9fd652111
9fd652111 Update translation files
f267c327b Merge branch 'origin/main' into Weblate.
2c4b1f251 Merge branch 'origin/main' into Weblate.
1bacfacfb Merge branch 'origin/main' into Weblate.
b98da3d89 Merge branch 'origin/main' into Weblate.
9acdd91c9 Merge branch 'origin/main' into Weblate.
54fcf127c Merge branch 'origin/main' into Weblate.
4becc00a7 Merge branch 'origin/main' into Weblate.
8d9d53a07 Translated using Weblate (Portuguese (Brazil))
8b98867f0 Merge branch 'origin/main' into Weblate.
6af532f4f Merge branch 'origin/main' into Weblate.
cea6c3d8d Update translation files
fea25c1c5 Merge branch 'origin/main' into Weblate.
a3fc20df0 Merge branch 'origin/main' into Weblate.
0ff0bb9ec Translated using Weblate (French)
f26100408 Merge branch 'origin/main' into Weblate.
a31fc3b08 Merge branch 'origin/main' into Weblate.
3b5be929e Merge branch 'origin/main' into Weblate.
458f55714 Merge branch 'origin/main' into Weblate.
4e7668d69 Merge branch 'origin/main' into Weblate.
ac8a9625d Translated using Weblate (Swedish)
bb1b2bd78 Translated using Weblate (Swedish)
e58c3852f Merge branch 'origin/main' into Weblate.
11d829e20 Translated using Weblate (Czech)
db04582af Translated using Weblate (Portuguese (Brazil))
 locale/ID.po             | 41 +++++++++++++++++++++---------
 locale/cs.po             | 60 ++++++++++++++++++++++++++-----------------
 locale/de_DE.po          | 41 +++++++++++++++++++++---------
 locale/el.po             | 34 +++++++++++++++++--------
 locale/es.po             | 39 ++++++++++++++++++++--------
 locale/fil.po            | 41 +++++++++++++++++++++---------
 locale/fr.po             | 52 +++++++++++++++++++++++++-------------
 locale/hi.po             | 34 +++++++++++++++++--------
 locale/it_IT.po          | 39 ++++++++++++++++++++--------
 locale/ja.po             | 39 ++++++++++++++++++++--------
 locale/ko.po             | 34 +++++++++++++++++--------
 locale/nl.po             | 41 +++++++++++++++++++++---------
 locale/pl.po             | 39 ++++++++++++++++++++--------
 locale/pt_BR.po          | 66 +++++++++++++++++++++++++++++++-----------------
 locale/sv.po             | 64 +++++++++++++++++++++++++++++-----------------
 locale/zh_Latn_pinyin.po | 39 ++++++++++++++++++++--------
 16 files changed, 484 insertions(+), 219 deletions(-)

We previously raised the issue with Weblate in case their service was doing something unexpected, and we also eliminated force-pushes to our own main branch or the PR branch as possible causes. WeblateOrg/weblate#5051

Because so many changes are incorrectly attributed to these pull requests, the review process via the web UI is not usable, and instead we have to verify the changes locally.

@jepler
Copy link
Member

jepler commented Jan 1, 2021

I received a response from Github -- it appears the behavior is by design. However, I remain puzzled at the advice about "merging the master branch into the feature branch frequently" as this is exactly what we are doing and it does not resolve the display issue in pull requests. But for now I think we have a choice between doing nothing and accepting the behavior, or switching to rebasing on weblate which we don't want to do.

Hi Jeff,

Thanks for contacting GitHub Support!

The reason you are seeing a difference here is because on GitHub.com we use a triple dot diff, whereas locally you appear to be using a double dot diff.

A double-dot diff displays the changes directly between the commits at the tip of each branch without considering the ancestry.

The triple-dot diff was chosen for GitHub.com because it offers a more accurate view of the changes in a branch or pull request by displaying the changes between the latest commit on the head branch and the last common ancestor with the base branch. If a rebase or squash was used to merge the pull request, Git cannot determine that the branches share history.

I’ve included two attachments below to demonstrate the difference between the two comparisons:

###Triple-dot diff
image
The triple-dot comparison shows the difference between the latest common commit of both (merge base) and the latest state of the feature branch. In other words, the triple-dot comparison focuses on what a pull request introduces to the merge base.

Double-dot diff
image

The double-dot comparison shows the difference between the latest state of A and the latest state of B.

To avoid confusion, we recommend merging the master branch into the feature branch frequently. By merging master, the diffs shown by double-dot and triple-dot are the same. Also we recommend merging a pull request as soon as possible. This encourages users to make pull requests smaller, which is recommended in general.

If you want to confirm if the behaviour you have described is due to the different comparison methods used by Git and GitHub, you can use the Compare view in one of your repositories to see the double-dot diff versus triple-dot diff commit comparisons.

Unfortunately, at present it's not possible to change the UI to use a double dot diff. However this is something that other users have asked about, and we are tracking this feedback for our product team to consider in future. I've added this ticket to that feedback request internally for you.

Feel free to come back to me if there's anything else you need.

Otherwise, have a great New Years!

Thanks,

Robert

@tannewt
Copy link
Member

tannewt commented Jan 5, 2021

Ya, this doesn't seem to apply to us. The merges should be updating the ancestry.

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

Successfully merging this pull request may close these issues.