Skip to content

Commit f2994ab

Browse files
zklauspre-commit-ci[bot]jaimergp
authored
Add troubleshooting section (#2565)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: jaimergp <[email protected]>
1 parent 534af37 commit f2994ab

File tree

1 file changed

+50
-0
lines changed

1 file changed

+50
-0
lines changed

docs/maintainer/updating_pkgs.md

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -346,3 +346,53 @@ If you'd like to maintain more than one version of your package, you can use bra
346346
- Fork your feedstock and make a meaningful branch name (e.g., v1.X or v1.0).
347347
- Make the required changes to the recipe and rerender the feedstock.
348348
- Then push this branch from your fork to the upstream feedstock. Our CI services will automatically build any branches in addition to the default branch.
349+
350+
## Troubleshooting
351+
352+
Sometimes things go wrong, particularly with the automation. This section aims to provide guidance on these problems.
353+
354+
### Automatic version updates don't work
355+
356+
Usually, the bot detects automatically when a new version of a package is released.
357+
It does that by monitoring the source url named in the recipe in an appropriate way,
358+
i.e. for PyPI sources it queries the API, for Github source releases it monitors the release page
359+
or the tags in the upstream repository.
360+
Sometimes an erroneous release happens or an unrelated tag is misidentified as a release.
361+
For example, `project-a` usually releases under a semver scheme like 4.0.2, but a typo in the release process ended up creating a tag with 40.3 (missing period).
362+
In these cases, the bot can be confused, consider subsequent releases as older than the misidentified one, and stop issuing automatic update PRs.
363+
364+
You can check which version the bot detected by looking in the metadata that it collected, which is conveniently available in its own Github repo.
365+
To deal with the large number of packages, the information is sharded (i.e. split into several subdirectories) according to some hash function,
366+
which makes it a bit challenging to find.
367+
The best way is to use Github search with the query [`repo:regro/cf-graph-countyfair path:version_pr_info/**/amrex.json`](https://github.com/search?q=repo%3Aregro%2Fcf-graph-countyfair+path%3Aversion_pr_info%2F**%2Famrex.json&type=code), where you should replace `amrex` with the name of your own package.
368+
This will lead you to a file looking like:
369+
370+
```json
371+
{
372+
"bad": false,
373+
"new_version": "25.07",
374+
"new_version_attempts": {
375+
"2024": 0,
376+
"23.11": 1,
377+
"23.12": 1,
378+
"24.01": 1,
379+
"24.02": 1,
380+
"24.03": 1
381+
},
382+
"new_version_errors": {}
383+
}
384+
```
385+
386+
Here, look for the `"new_version"` field. If that contains a wrong value, note it down for fixing in the next step.
387+
388+
The solution in this case is to let the bot know that it should ignore a certain version.
389+
This can be done in the `conda-forge.yml` configuration file, with [more details](../conda_forge_yml/#bot) in the documentation, the simple snippet boils down to
390+
391+
```yaml
392+
bot:
393+
version_updates:
394+
exclude:
395+
- '08.14'
396+
```
397+
398+
where `'08.14'` represents the erroneous version.

0 commit comments

Comments
 (0)