Skip to content

Extract reporter - #1287

Merged
Ndpnt merged 8 commits into
mainfrom
extract-reporter
Oct 14, 2026
Merged

Ndpnt merged 8 commits into
mainfrom
extract-reporter

Conversation

@Ndpnt

@Ndpnt Ndpnt commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@Ndpnt
Ndpnt requested a review from clementbiron October 8, 2026 12:50
The technical upgrade pass can last several minutes on large collections, so a warning emitted after it could be missed by an operator checking the first log lines after upgrading, or never emitted if the process is stopped before the pass completes.
The engine accepted a reporter configuration nested under a githubIssues key and inferred its GitHub type, while the issue-reporter module expects a type next to the repositories and fails at startup without it. Moving such a configuration as is would thus prevent reporting, so the warning and the changelog give the expected shape.
Publishing to GitLab was selected by the OTA_ENGINE_GITLAB_TOKEN environment variable while all its requests authenticate with OTA_ENGINE_GITLAB_RELEASES_TOKEN. The first one was the token of the declarations repository, used by the reporter to manage issues, and the second one the token of the versions repository, where datasets are released. Publishing was first selected by the releases token, then by the declarations one when it started being used to tell that the collection is hosted on GitLab.

Now that the reporter is removed, renaming OTA_ENGINE_GITLAB_TOKEN to OTA_ISSUE_REPORTER_GITLAB_TOKEN, as the migration instructions say, would silently stop publishing datasets to GitLab, while defining it without the releases token would send unauthenticated requests.
The helper that authenticates the GitLab publishing requests was moved from the reporter, whose tests covered it, into the publisher, whose tests did not check the authorization header. A request sent without the releases token would thus have left the tests passing while failing on GitLab.
The GitLab publisher read only the uppercase proxy environment variables, while the fetcher also honours the lowercase ones that the environment example presents as alternatives. With only HTTP_PROXY defined, it also reached the HTTPS API with an agent that does not tunnel, which fails.

Resolving the proxies as the fetcher does and choosing the agent from the scheme of the API publishes the dataset through the same proxy as the terms are fetched.
clementbiron added a commit to OpenTermsArchive/docs that referenced this pull request Oct 8, 2026
Renaming `OTA_ENGINE_GITHUB_TOKEN` would remove the token the engine still
uses to publish datasets to GitHub releases, which contradicted the
following sentence. On GitLab, the engine now publishes datasets with
`OTA_ENGINE_GITLAB_RELEASES_TOKEN` only, so `OTA_ENGINE_GITLAB_TOKEN` can be
renamed, as described in OpenTermsArchive/engine#1287.
clementbiron added a commit to OpenTermsArchive/docs that referenced this pull request Oct 8, 2026
The engine selected GitLab publishing with `OTA_ENGINE_GITLAB_TOKEN` while
authenticating every request with `OTA_ENGINE_GITLAB_RELEASES_TOKEN`. Since
OpenTermsArchive/engine#1287, publishing depends on the releases token only
and `OTA_ENGINE_GITLAB_TOKEN` is no longer used.
clementbiron added a commit to OpenTermsArchive/docs that referenced this pull request Oct 8, 2026
Since OpenTermsArchive/engine#1287, the GitLab dataset publisher resolves
the proxy as the fetcher does, so the proxy variables also apply to dataset
publishing. Both also honour the lowercase variables, which take precedence
over the uppercase ones.
@Ndpnt
Ndpnt merged commit 89684cd into main Oct 14, 2026
8 checks passed
@Ndpnt
Ndpnt deleted the extract-reporter branch October 14, 2026 09:07
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.

2 participants