Skip to content

Commit

Permalink
fix: Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Brian Smith <[email protected]>
  • Loading branch information
OmarIthawi and brian-smith-tcril authored Nov 20, 2023
1 parent 0db8699 commit 886e4e2
Showing 1 changed file with 18 additions and 25 deletions.
43 changes: 18 additions & 25 deletions docs/decisions/0002-mark-fuzzy-entries.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,44 +8,41 @@ Rejected.

Context
*******
As of the `OEP-58`_, the Transifex GitHub App is used to sync Translations.
These translations are validated by `LexiQA`_, built-in Transifex quality
checks, and human reviewers. During this synchronization process, the
`Transifex GitHub App`_ creates pull requests to this repository. The
translations in the pull requests are then validated by ``msgfmt`` in CI.
As of `OEP-58`_, the `Transifex GitHub App`_ is used to sync translations
between Transifex projects and the openedx-translations repository.
Within Transifex, translations are subjected to automated validation,
incorporating checks from both the platform itself and the `LexiQA`_ add-on,
in addition to being reviewed by human translators. During the synchronization
process, the `Transifex GitHub App`_ creates pull requests to the openedx-translations
repository. The pull requests trigger a CI workflow that runs ``msgfmt`` to
validate the translations.

Problem
*******
There are times when the translations being synchronized fail ``msgfmt``
validation. This prevents the pull requests from being merged.
validation. This prevents the pull requests from being automatically merged.


Default Workflow: Keep pull requests open
********************************************

By default pull requests will be kept open and the translators will
need to fix the invalid entries and the `Transifex GitHub App`_ will
update the pull request with the new changes and merge it automatically
if there are no more errors.
By default a failing pull request will be kept open. Once translators
fix the invalid entries the `Transifex GitHub App`_ will update the
pull request and merge it automatically.

To improve the Translators experience, a notification will be sent to
for invalid entries. An issue has been created to track this work:
Translators do not monitor pull requests to the openedx-translations repo,
and have requested to be notified of invalid entries via slack. This will start
as a manual process. Work to automate this in the future will be tracked in
`Notify translators about invalid entries`_.

Rejected Alternative: Mark invalid entries as fuzzy
***************************************************

Rejection Reason
================

This design decision was rejected because there were multiple issues that
had no feasible solution within the original scope of the `OEP-58`_
proposal. These issues are listed below:
Rejection Reasons
=================

- The workflow script edits the translations and effectively hide the
errors, which can be confusing for the translators. Therefore,
a good notification should be
sent to translators to avoid silencing errors.
errors, which can be confusing for the translators.
- Writing to the pull request will not trigger the GitHub Actions workflow,
therefore the pull request cannot be merged unless the commit status
is overridden manually via `GitHub "create a commit status" API`_.
Expand Down Expand Up @@ -80,10 +77,6 @@ combined into one single workflow with multiple jobs:
#. Automatically merge the PR


Informing the Translators
=========================
Translators can be notified about invalid translations via Slack, Transifex
or GitHub issues depending on the community's preference.

Pros and Cons
=============
Expand Down

0 comments on commit 886e4e2

Please sign in to comment.