python / python/python-docs-pt-br

Melhorar mensagem enviada para Telegram com erro encontrado em arquivo .po pelo linter

Open
#294 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
164
Forks
42
Avg merge
14h 32m
Merged PRs (30d)
4

Description

Atualmente, quando o linter encontra um erro no .po, é enviada uma mensagem para o Telegram semelhante a essa

Image

O problema disso é que a linha 1280, deste exemplo, do arquivo não é encontrável pelo Transifex.

Então, seria útil que nessa mensagem viesse a URL para a linha no repositório. No caso, seria

https://github.com/python/python-docs-pt-br/blob/3.14/library/string.po#L1280

Ou com o link permanente:

https://github.com/python/python-docs-pt-br/blob/3dfcdb8c00c002f8667d7478a4aa1625fc9eea1d/library/string.po#L1280

Adicionalmente, talvez ficasse mais claro se a mensagem/link fosse para a linha com a msgstr e não a msgid. E talvez com mais algum texto explicativo.

Adicionalmente 2, enviar um URL para pesquisar no TX por uma strings com o texto da string alvo. Para o exemplo seria:

https://app.transifex.com/python-doc/python-newest/translate/#pt_BR/library--string/592013921?q=text%3A'%3E%3E%3E%20\'{0}%2C%20{1}%2C%20{2}\'.format(\'a\'%2C%20\'b\'%2C%20\'c\')'

Note que foi necessário remover o \n da URL.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the code that formats Telegram notifications for linter errors in .po files, then inspect how the reported file and line are available. The work is done when the message links to the relevant repository line, preferably the msgstr, and provides a Transifex search URL for the target string.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
documentation, localization
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.