{"url":"https://api.github.com/repos/OpenCyphal/nunavut/pulls/424","id":5007567448,"node_id":"PR_kwDOCqNdsM8AAAABKnlqWA","html_url":"https://github.com/OpenCyphal/nunavut/pull/424","diff_url":"https://github.com/OpenCyphal/nunavut/pull/424.diff","patch_url":"https://github.com/OpenCyphal/nunavut/pull/424.patch","issue_url":"https://api.github.com/repos/OpenCyphal/nunavut/issues/424","commits_url":"https://api.github.com/repos/OpenCyphal/nunavut/pulls/424/commits","review_comments_url":"https://api.github.com/repos/OpenCyphal/nunavut/pulls/424/comments","review_comment_url":"https://api.github.com/repos/OpenCyphal/nunavut/pulls/comments{/number}","comments_url":"https://api.github.com/repos/OpenCyphal/nunavut/issues/424/comments","statuses_url":"https://api.github.com/repos/OpenCyphal/nunavut/statuses/778bafceff07f39634f1202db7b958bc7bd12e25","number":424,"state":"closed","locked":false,"title":"CI and packaging: SonarCloud version, single CMake version literal, Dependabot and release from tested package","user":{"login":"thirtytwobits","id":19180861,"node_id":"MDQ6VXNlcjE5MTgwODYx","avatar_url":"https://avatars.githubusercontent.com/u/19180861?v=4","gravatar_id":"","url":"https://api.github.com/users/thirtytwobits","html_url":"https://github.com/thirtytwobits","followers_url":"https://api.github.com/users/thirtytwobits/followers","following_url":"https://api.github.com/users/thirtytwobits/following{/other_user}","gists_url":"https://api.github.com/users/thirtytwobits/gists{/gist_id}","starred_url":"https://api.github.com/users/thirtytwobits/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thirtytwobits/subscriptions","organizations_url":"https://api.github.com/users/thirtytwobits/orgs","repos_url":"https://api.github.com/users/thirtytwobits/repos","events_url":"https://api.github.com/users/thirtytwobits/events{/privacy}","received_events_url":"https://api.github.com/users/thirtytwobits/received_events","type":"User","user_view_type":"public","site_admin":false},"body":"SonarCloud has labeled every analysis since February 2026 as version \"2.3\", including the latest one of the 3.1.0 release commit (`cce94a9`).\n\n**Cause:** the sonar job's `set-environment` step runs `./src/nunavut/_version.py --major-minor-only`, but the file is mode `100644` in git. The run log shows `./src/nunavut/_version.py: Permission denied`. `echo` still succeeds, so the step passes, `NUNAVUT_MAJOR_MINOR_VERSION` ends up empty, and the scanner receives `-Dsonar.projectVersion=` with no value. SonarCloud then reuses the last version it was given.\n\n`-Dsonar.buildString=${{ env.GITHUB_RUN_ID }}` was empty for a similar reason: `GITHUB_RUN_ID` is a runner environment variable and isn't exposed through the `env` context.\n\n**Changes**\n- Run the script as `python3 ./src/nunavut/_version.py --major-minor-only`, matching `release.yml`. Locally this prints `3.1`.\n- Use `${{ github.run_id }}` for `sonar.buildString` in both the release and PR scan steps.\n\nThe PR scan from this branch should show the new arguments in the sonar job log. The project version on the SonarCloud dashboard should switch to 3.1 after the first `main` analysis once this merges.\n\n## CMake package version literals (#423)\n\n`NunavutConfigVersion.cmake` hard-coded the version in three places, and only `PACKAGE_VERSION` was updated for 3.1. The major-version check still read `\"3.0\"`, and `NunavutConfig.cmake` also set `NUNAVUT_VERSION \"3.0\"`.\n\n- `NunavutConfigVersion.cmake` now reads `\"${PACKAGE_VERSION}\"` in the `MATCHES` check and the `CVF_VERSION_MAJOR` fallback, so `set(PACKAGE_VERSION \"3.1\")` is the only place to update.\n- Removed `set(NUNAVUT_VERSION \"3.0\")` from `NunavutConfig.cmake`. `execute_process` overwrites it before anything reads it.\n- New test `test_cmake_package_version_matches_version` in `test/gentest_versions/test_versions.py` requires exactly one quoted version literal across both files, on the `PACKAGE_VERSION` line, matching the major.minor of `__version__`. It failed on `main` (listing the three stale `\"3.0\"` literals) and passes with this change on Python 3.11 and 3.14.\n- A `cmake -P` probe gives the same COMPATIBLE/EXACT results before and after for requests 3.0, 3.1, 3.2, 4.0 and 2.9, plus several version ranges. In a copy bumped to `4.0`, the old file rejects `find_package(Nunavut 4.0)` (it still computes major 3); the new file accepts it.\n\nThe test only counts double-quoted literals. An unquoted stale version, such as `set(X 3.0)`, would not be caught.\n\nCloses #423\n\n## CI modernization (#420)\n\n**Dependabot:** new `.github/dependabot.yml` checks `github-actions` weekly and groups every update into one PR. The `toxic`/`toolshed` container images named in the workflows aren't covered and still need manual bumps.\n\n**Node 24 actions:** `checkout` v4→v7, `upload-artifact` v4→v7, `download-artifact` v4→v8, `setup-python` v5→v7, `sonarqube-scan-action` v6.0.0→v8.3.0. I read the release notes for each skipped major. None of the breaking changes affect how this repo uses these actions:\n- `download-artifact` v8 now fails on a digest mismatch.\n- `setup-python` v7 removes `pip-install`, which isn't used here.\n- Sonar v8 verifies the scanner signature by default.\n\n**No second test run at release time:** `release.yml` no longer lints, tests and builds the tagged commit again. It now:\n1. checks the tag against `__version__` (unchanged);\n2. finds the newest successful `push` run of `test.yml` for the tagged commit;\n3. downloads that run's `pypi-package` artifact;\n4. uploads it with `twine`.\n\nWhat gets published is exactly what CI built and tested. One side effect: the wheel's build number is now the `test.yml` run ID (`noxfile.py` reads `GITHUB_RUN_ID`).\n\n| Situation | Result |\n|---|---|\n| No `push` run of `test.yml` for the commit (tag not on `main`/`*.preview`) | Fails, lists the commit's runs |\n| That run is still going or failed | Fails; re-run the release job once CI succeeds |\n| Artifact expired (kept 90 days; runs can only be re-run for 30) | Fails; release from a newer tested commit |\n| Tag doesn't match `__version__` | Fails, as before |\n| Prerelease | Skipped, as before |\n\n**Dry run:** the **Run workflow** button (`workflow_dispatch` with a `tag` input) runs every step except the upload.\n\n**Concurrency:** `test.yml` cancels a pull request run when a newer push supersedes it. Branch-push runs each get their own group (keyed by run ID), so every `main` run finishes and leaves a package for the release.\n\n**Checks:**\n- `actionlint` (with shellcheck) passes on both workflows.\n- I ran the lookup step locally in three cases:\n  - tag `3.1.0` found run 40213769476, and its `pypi-package` artifact contains `nunavut-3.1.0-py3-none-any.whl` and `nunavut-3.1.0.tar.gz` at the root;\n  - tag `3.0.1b1` failed because its artifact has expired;\n  - an untested branch commit failed because there is no push run.\n- An independent review found no correctness problems. It corrected the expired-artifact message, which used to suggest a re-run that GitHub no longer allows.\n\n**Not verifiable until after merge:**\n- the dry run, which only exists on `main` — run it against `3.1.0`;\n- Dependabot's first PR;\n- the cancellation of superseded PR runs, which needs a second push to a PR.\n\nCloses #420\n\n🤖 Generated with [Claude Code](https://claude.com/claude-code)\n\n\n","labels":[],"milestone":null,"active_lock_reason":null,"created_at":"2026-10-25T18:40:56Z","updated_at":"2026-10-25T21:38:09Z","closed_at":"2026-10-25T21:38:06Z","merged_at":"2026-10-25T21:38:06Z","merge_commit_sha":"85470f7bdc6d6b108f0621528cc8ab2524b735cd","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"head":{"label":"OpenCyphal:sonar-version-label","ref":"sonar-version-label","repo":{"id":178478512,"node_id":"MDEwOlJlcG9zaXRvcnkxNzg0Nzg1MTI=","name":"nunavut","full_name":"OpenCyphal/nunavut","owner":{"login":"OpenCyphal","id":10167381,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMTY3Mzgx","avatar_url":"https://avatars.githubusercontent.com/u/10167381?v=4","gravatar_id":"","url":"https://api.github.com/users/OpenCyphal","html_url":"https://github.com/OpenCyphal","followers_url":"https://api.github.com/users/OpenCyphal/followers","following_url":"https://api.github.com/users/OpenCyphal/following{/other_user}","gists_url":"https://api.github.com/users/OpenCyphal/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenCyphal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenCyphal/subscriptions","organizations_url":"https://api.github.com/users/OpenCyphal/orgs","repos_url":"https://api.github.com/users/OpenCyphal/repos","events_url":"https://api.github.com/users/OpenCyphal/events{/privacy}","received_events_url":"https://api.github.com/users/OpenCyphal/received_events","type":"Organization","user_view_type":"public","site_admin":false},"private":false,"fork":false,"archived":false,"disabled":false,"description":"Generate code from DSDL using PyDSDL and Jinja2","homepage":"https://nunavut.readthedocs.io/","language":"Python","visibility":"public","is_template":false,"topics":["code-generation","code-generator","cpp","cyphal","dsdl","opencyphal","python"],"forks_count":26,"forks":26,"stargazers_count":48,"watchers_count":48,"watchers":48,"open_issues_count":35,"open_issues":35,"size":2874,"default_branch":"main","has_issues":true,"has_projects":true,"has_wiki":false,"has_pages":false,"has_downloads":false,"has_discussions":false,"has_pull_requests":true,"pushed_at":"2026-11-11T18:17:19Z","created_at":"2019-03-29T21:37:20Z","updated_at":"2026-11-11T20:54:43Z","allow_forking":true,"web_commit_signoff_required":false,"pull_request_creation_policy":"all","license":{"key":"other","name":"Other","url":null,"spdx_id":"NOASSERTION","node_id":"MDc6TGljZW5zZTA="},"url":"https://api.github.com/repos/OpenCyphal/nunavut","html_url":"https://github.com/OpenCyphal/nunavut","archive_url":"https://api.github.com/repos/OpenCyphal/nunavut/{archive_format}{/ref}","assignees_url":"https://api.github.com/repos/OpenCyphal/nunavut/assignees{/user}","blobs_url":"https://api.github.com/repos/OpenCyphal/nunavut/git/blobs{/sha}","branches_url":"https://api.github.com/repos/OpenCyphal/nunavut/branches{/branch}","collaborators_url":"https://api.github.com/repos/OpenCyphal/nunavut/collaborators{/collaborator}","comments_url":"https://api.github.com/repos/OpenCyphal/nunavut/comments{/number}","commits_url":"https://api.github.com/repos/OpenCyphal/nunavut/commits{/sha}","compare_url":"https://api.github.com/repos/OpenCyphal/nunavut/compare/{base}...{head}","contents_url":"https://api.github.com/repos/OpenCyphal/nunavut/contents/{+path}","contributors_url":"https://api.github.com/repos/OpenCyphal/nunavut/contributors","deployments_url":"https://api.github.com/repos/OpenCyphal/nunavut/deployments","downloads_url":"https://api.github.com/repos/OpenCyphal/nunavut/downloads","events_url":"https://api.github.com/repos/OpenCyphal/nunavut/events","forks_url":"https://api.github.com/repos/OpenCyphal/nunavut/forks","git_commits_url":"https://api.github.com/repos/OpenCyphal/nunavut/git/commits{/sha}","git_refs_url":"https://api.github.com/repos/OpenCyphal/nunavut/git/refs{/sha}","git_tags_url":"https://api.github.com/repos/OpenCyphal/nunavut/git/tags{/sha}","git_url":"git://github.com/OpenCyphal/nunavut.git","issue_comment_url":"https://api.github.com/repos/OpenCyphal/nunavut/issues/comments{/number}","issue_events_url":"https://api.github.com/repos/OpenCyphal/nunavut/issues/events{/number}","issues_url":"https://api.github.com/repos/OpenCyphal/nunavut/issues{/number}","keys_url":"https://api.github.com/repos/OpenCyphal/nunavut/keys{/key_id}","labels_url":"https://api.github.com/repos/OpenCyphal/nunavut/labels{/name}","languages_url":"https://api.github.com/repos/OpenCyphal/nunavut/languages","merges_url":"https://api.github.com/repos/OpenCyphal/nunavut/merges","milestones_url":"https://api.github.com/repos/OpenCyphal/nunavut/milestones{/number}","notifications_url":"https://api.github.com/repos/OpenCyphal/nunavut/notifications{?since,all,participating}","pulls_url":"https://api.github.com/repos/OpenCyphal/nunavut/pulls{/number}","releases_url":"https://api.github.com/repos/OpenCyphal/nunavut/releases{/id}","ssh_url":"git@github.com:OpenCyphal/nunavut.git","stargazers_url":"https://api.github.com/repos/OpenCyphal/nunavut/stargazers","statuses_url":"https://api.github.com/repos/OpenCyphal/nunavut/statuses/{sha}","subscribers_url":"https://api.github.com/repos/OpenCyphal/nunavut/subscribers","subscription_url":"https://api.github.com/repos/OpenCyphal/nunavut/subscription","tags_url":"https://api.github.com/repos/OpenCyphal/nunavut/tags","teams_url":"https://api.github.com/repos/OpenCyphal/nunavut/teams","trees_url":"https://api.github.com/repos/OpenCyphal/nunavut/git/trees{/sha}","clone_url":"https://github.com/OpenCyphal/nunavut.git","mirror_url":null,"hooks_url":"https://api.github.com/repos/OpenCyphal/nunavut/hooks","svn_url":"https://github.com/OpenCyphal/nunavut"},"sha":"778bafceff07f39634f1202db7b958bc7bd12e25","user":{"login":"OpenCyphal","id":10167381,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMTY3Mzgx","avatar_url":"https://avatars.githubusercontent.com/u/10167381?v=4","gravatar_id":"","url":"https://api.github.com/users/OpenCyphal","html_url":"https://github.com/OpenCyphal","followers_url":"https://api.github.com/users/OpenCyphal/followers","following_url":"https://api.github.com/users/OpenCyphal/following{/other_user}","gists_url":"https://api.github.com/users/OpenCyphal/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenCyphal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenCyphal/subscriptions","organizations_url":"https://api.github.com/users/OpenCyphal/orgs","repos_url":"https://api.github.com/users/OpenCyphal/repos","events_url":"https://api.github.com/users/OpenCyphal/events{/privacy}","received_events_url":"https://api.github.com/users/OpenCyphal/received_events","type":"Organization","user_view_type":"public","site_admin":false}},"base":{"label":"OpenCyphal:main","ref":"main","repo":{"id":178478512,"node_id":"MDEwOlJlcG9zaXRvcnkxNzg0Nzg1MTI=","name":"nunavut","full_name":"OpenCyphal/nunavut","owner":{"login":"OpenCyphal","id":10167381,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMTY3Mzgx","avatar_url":"https://avatars.githubusercontent.com/u/10167381?v=4","gravatar_id":"","url":"https://api.github.com/users/OpenCyphal","html_url":"https://github.com/OpenCyphal","followers_url":"https://api.github.com/users/OpenCyphal/followers","following_url":"https://api.github.com/users/OpenCyphal/following{/other_user}","gists_url":"https://api.github.com/users/OpenCyphal/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenCyphal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenCyphal/subscriptions","organizations_url":"https://api.github.com/users/OpenCyphal/orgs","repos_url":"https://api.github.com/users/OpenCyphal/repos","events_url":"https://api.github.com/users/OpenCyphal/events{/privacy}","received_events_url":"https://api.github.com/users/OpenCyphal/received_events","type":"Organization","user_view_type":"public","site_admin":false},"private":false,"fork":false,"archived":false,"disabled":false,"description":"Generate code from DSDL using PyDSDL and Jinja2","homepage":"https://nunavut.readthedocs.io/","language":"Python","visibility":"public","is_template":false,"topics":["code-generation","code-generator","cpp","cyphal","dsdl","opencyphal","python"],"forks_count":26,"forks":26,"stargazers_count":48,"watchers_count":48,"watchers":48,"open_issues_count":35,"open_issues":35,"size":2874,"default_branch":"main","has_issues":true,"has_projects":true,"has_wiki":false,"has_pages":false,"has_downloads":false,"has_discussions":false,"has_pull_requests":true,"pushed_at":"2026-11-11T18:17:19Z","created_at":"2019-03-29T21:37:20Z","updated_at":"2026-11-11T20:54:43Z","allow_forking":true,"web_commit_signoff_required":false,"pull_request_creation_policy":"all","license":{"key":"other","name":"Other","url":null,"spdx_id":"NOASSERTION","node_id":"MDc6TGljZW5zZTA="},"url":"https://api.github.com/repos/OpenCyphal/nunavut","html_url":"https://github.com/OpenCyphal/nunavut","archive_url":"https://api.github.com/repos/OpenCyphal/nunavut/{archive_format}{/ref}","assignees_url":"https://api.github.com/repos/OpenCyphal/nunavut/assignees{/user}","blobs_url":"https://api.github.com/repos/OpenCyphal/nunavut/git/blobs{/sha}","branches_url":"https://api.github.com/repos/OpenCyphal/nunavut/branches{/branch}","collaborators_url":"https://api.github.com/repos/OpenCyphal/nunavut/collaborators{/collaborator}","comments_url":"https://api.github.com/repos/OpenCyphal/nunavut/comments{/number}","commits_url":"https://api.github.com/repos/OpenCyphal/nunavut/commits{/sha}","compare_url":"https://api.github.com/repos/OpenCyphal/nunavut/compare/{base}...{head}","contents_url":"https://api.github.com/repos/OpenCyphal/nunavut/contents/{+path}","contributors_url":"https://api.github.com/repos/OpenCyphal/nunavut/contributors","deployments_url":"https://api.github.com/repos/OpenCyphal/nunavut/deployments","downloads_url":"https://api.github.com/repos/OpenCyphal/nunavut/downloads","events_url":"https://api.github.com/repos/OpenCyphal/nunavut/events","forks_url":"https://api.github.com/repos/OpenCyphal/nunavut/forks","git_commits_url":"https://api.github.com/repos/OpenCyphal/nunavut/git/commits{/sha}","git_refs_url":"https://api.github.com/repos/OpenCyphal/nunavut/git/refs{/sha}","git_tags_url":"https://api.github.com/repos/OpenCyphal/nunavut/git/tags{/sha}","git_url":"git://github.com/OpenCyphal/nunavut.git","issue_comment_url":"https://api.github.com/repos/OpenCyphal/nunavut/issues/comments{/number}","issue_events_url":"https://api.github.com/repos/OpenCyphal/nunavut/issues/events{/number}","issues_url":"https://api.github.com/repos/OpenCyphal/nunavut/issues{/number}","keys_url":"https://api.github.com/repos/OpenCyphal/nunavut/keys{/key_id}","labels_url":"https://api.github.com/repos/OpenCyphal/nunavut/labels{/name}","languages_url":"https://api.github.com/repos/OpenCyphal/nunavut/languages","merges_url":"https://api.github.com/repos/OpenCyphal/nunavut/merges","milestones_url":"https://api.github.com/repos/OpenCyphal/nunavut/milestones{/number}","notifications_url":"https://api.github.com/repos/OpenCyphal/nunavut/notifications{?since,all,participating}","pulls_url":"https://api.github.com/repos/OpenCyphal/nunavut/pulls{/number}","releases_url":"https://api.github.com/repos/OpenCyphal/nunavut/releases{/id}","ssh_url":"git@github.com:OpenCyphal/nunavut.git","stargazers_url":"https://api.github.com/repos/OpenCyphal/nunavut/stargazers","statuses_url":"https://api.github.com/repos/OpenCyphal/nunavut/statuses/{sha}","subscribers_url":"https://api.github.com/repos/OpenCyphal/nunavut/subscribers","subscription_url":"https://api.github.com/repos/OpenCyphal/nunavut/subscription","tags_url":"https://api.github.com/repos/OpenCyphal/nunavut/tags","teams_url":"https://api.github.com/repos/OpenCyphal/nunavut/teams","trees_url":"https://api.github.com/repos/OpenCyphal/nunavut/git/trees{/sha}","clone_url":"https://github.com/OpenCyphal/nunavut.git","mirror_url":null,"hooks_url":"https://api.github.com/repos/OpenCyphal/nunavut/hooks","svn_url":"https://github.com/OpenCyphal/nunavut"},"sha":"cce94a9c893a100ce35b9920bcca4dfd5d855af1","user":{"login":"OpenCyphal","id":10167381,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMTY3Mzgx","avatar_url":"https://avatars.githubusercontent.com/u/10167381?v=4","gravatar_id":"","url":"https://api.github.com/users/OpenCyphal","html_url":"https://github.com/OpenCyphal","followers_url":"https://api.github.com/users/OpenCyphal/followers","following_url":"https://api.github.com/users/OpenCyphal/following{/other_user}","gists_url":"https://api.github.com/users/OpenCyphal/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenCyphal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenCyphal/subscriptions","organizations_url":"https://api.github.com/users/OpenCyphal/orgs","repos_url":"https://api.github.com/users/OpenCyphal/repos","events_url":"https://api.github.com/users/OpenCyphal/events{/privacy}","received_events_url":"https://api.github.com/users/OpenCyphal/received_events","type":"Organization","user_view_type":"public","site_admin":false}},"_links":{"comments":{"href":"https://api.github.com/repos/OpenCyphal/nunavut/issues/424/comments"},"commits":{"href":"https://api.github.com/repos/OpenCyphal/nunavut/pulls/424/commits"},"statuses":{"href":"https://api.github.com/repos/OpenCyphal/nunavut/statuses/778bafceff07f39634f1202db7b958bc7bd12e25"},"html":{"href":"https://github.com/OpenCyphal/nunavut/pull/424"},"issue":{"href":"https://api.github.com/repos/OpenCyphal/nunavut/issues/424"},"review_comments":{"href":"https://api.github.com/repos/OpenCyphal/nunavut/pulls/424/comments"},"review_comment":{"href":"https://api.github.com/repos/OpenCyphal/nunavut/pulls/comments{/number}"},"self":{"href":"https://api.github.com/repos/OpenCyphal/nunavut/pulls/424"}},"author_association":"MEMBER","auto_merge":null,"draft":false,"merged":true,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":{"login":"thirtytwobits","id":19180861,"node_id":"MDQ6VXNlcjE5MTgwODYx","avatar_url":"https://avatars.githubusercontent.com/u/19180861?v=4","gravatar_id":"","url":"https://api.github.com/users/thirtytwobits","html_url":"https://github.com/thirtytwobits","followers_url":"https://api.github.com/users/thirtytwobits/followers","following_url":"https://api.github.com/users/thirtytwobits/following{/other_user}","gists_url":"https://api.github.com/users/thirtytwobits/gists{/gist_id}","starred_url":"https://api.github.com/users/thirtytwobits/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thirtytwobits/subscriptions","organizations_url":"https://api.github.com/users/thirtytwobits/orgs","repos_url":"https://api.github.com/users/thirtytwobits/repos","events_url":"https://api.github.com/users/thirtytwobits/events{/privacy}","received_events_url":"https://api.github.com/users/thirtytwobits/received_events","type":"User","user_view_type":"public","site_admin":false},"comments":4,"review_comments":0,"maintainer_can_modify":false,"commits":3,"additions":113,"deletions":47,"changed_files":6}