fix(open-tasks): gather issues from all Flipper One repos#402
fix(open-tasks): gather issues from all Flipper One repos#402stuartmhannon wants to merge 1 commit into
Conversation
…ices#371) Extend SECTIONS to cover all Flipper One repositories listed on the flipperdevices GitHub org page: - Linux (CPU Software): add flipper-linux-kernel, u-boot, rkbin, rockchip-linux, and bsb-protobuf alongside the existing flipperone-linux-build-scripts. These repos are part of the Linux build ecosystem (kernel, bootloader, firmware blobs, protobuf definitions). - FlipCTL: add a new section covering flipctl and flipctl-fonts, as requested in the issue. To support multiple repos per section, change the slug field from str to a list of strings and add a _match_section_slug helper. Also bump --limit from 200 to 1000 to future-proof against growth in the number of help-wanted issues across the org. Tested: script runs successfully with --input-json against a live snapshot of 18 open help-wanted issues. The flipper-linux-kernel issue flipperdevices#6 now correctly appears under the Linux section where it was previously silently dropped.
850f4d8 to
c30f31e
Compare
|
Hi @stuartmhannon, thank you for the contribution! I've just merged PR #396, which searches for open PRs for each task. It could interfere with adding extra repos, so could you please rebase your branch? I've launched CI; all looks fine except the DCO check — please note. I'll return and review this PR and #403 later today. |
| SECTIONS: list[_Section] = [ | ||
| { | ||
| "slug": "flipperdevices/flipperone-hardware", | ||
| "slug": [ |
There was a problem hiding this comment.
Let's rename it so it better reflects the content. slugs or even repos
| "slug": ["flipperdevices/flipctl", "flipperdevices/flipctl-fonts"], | ||
| "title": "FlipCTL", | ||
| "emoji": "🎛️", | ||
| "description": "Command-line tool and companion fonts for managing and configuring Flipper One.", |
There was a problem hiding this comment.
Not quite. FlipCTL is a UI framework for building Flipper-native applications.
| "description": "Command-line tool and companion fonts for managing and configuring Flipper One.", | |
| "description": "UI framework for embedded Linux systems" |
| "task_tracker": "https://github.com/orgs/flipperdevices/projects/12", | ||
| "contribution_guide": "https://docs.flipper.net/one/user-interface/about#how-to-contribute", |
There was a problem hiding this comment.
| "task_tracker": "https://github.com/orgs/flipperdevices/projects/12", | |
| "contribution_guide": "https://docs.flipper.net/one/user-interface/about#how-to-contribute", | |
| "task_tracker": "TBD", | |
| "contribution_guide": "https://blog.flipper.net/flipctl-our-gui-framework-for-embedded-linux-systems/#how-you-can-join", |
|
|
||
| class _Section(TypedDict): | ||
| slug: str | ||
| slug: str | list[str] |
There was a problem hiding this comment.
I think you've replaced them all with lists, so there is no need for plain str here
| .replace(">", ">") | ||
| .replace('"', """) | ||
| ) | ||
| return html.escape(text, quote=True) |
There was a problem hiding this comment.
This is likely a good change, but it's out of scope for this PR. Could you please extract it to another PR? A separate commit in #403 would be fine too.
| return pattern.sub("updatedAt: -", a) == pattern.sub("updatedAt: -", b) | ||
|
|
||
|
|
||
| def _match_section_slug(slug: str | list[str], repo_full: str) -> bool: |
There was a problem hiding this comment.
We have full control over the project data, so there's no real need to add this str | list[str] flexibility. Let's leave just list[str]. And rename slug, repo_full to repos, repo.
| "--label", LABEL, | ||
| "--state", "open", | ||
| "--limit", "200", | ||
| "--limit", "1000", |
There was a problem hiding this comment.
I think it's some AI leftover. In the PR description, it says
The original --limit 200 was not the problem — only 18 total "help wanted" issues exist across the entire flipperdevices org. The real issue was that SECTIONS was missing multiple repos:
which also looks like AI's reply to an iteration of debugging.
Your contribution is reviewed by humans. Please read and check the PR yourself, even when you use AI.
| "flipperdevices/flipper-linux-kernel", | ||
| "flipperdevices/u-boot", | ||
| "flipperdevices/rkbin", | ||
| "flipperdevices/rockchip-linux", |
There was a problem hiding this comment.
Mirror repository that can't have issues or PRs. Let's remove it.
| "flipperdevices/rockchip-linux", |
| "flipperdevices/u-boot", | ||
| "flipperdevices/rkbin", | ||
| "flipperdevices/rockchip-linux", | ||
| "flipperdevices/bsb-protobuf", |
There was a problem hiding this comment.
Not a part of Flipper One development.
| "flipperdevices/bsb-protobuf", |
Summary
Fixes #371. The
generate_open_tasks.pyscript was silently dropping issues from repos not hardcoded in theSECTIONSlist. The_build_template_sectionsfunction usedby_repo.get(section["slug"], [])which only matched a single repo name — any help-wanted issue from repos outside the original 7-entrySECTIONSlist was fetched by the org-widegh search issuescall but then discarded during rendering.Investigation findings
The original
--limit 200was not the problem — only 18 total "help wanted" issues exist across the entireflipperdevicesorg. The real issue was thatSECTIONSwas missing multiple repos:SECTIONSChanges
Repository coverage added
flipperdevices/flipperone-debug-probe(debug probe for Flipper One based on RP2350)flipper-linux-kernel,u-boot,rkbin,rockchip-linux, andbsb-protobufflipctlandflipctl-fontsCode changes
slugfield: changed fromstrtolist[str]for all sections to support multi-repo sections_match_section_slug(): new helper that correctly matches a repo name against a section slug (single or list)_build_template_sections(): fixed to iterate all fetched repos and use_match_section_slugfor matching instead of the originalby_repo.get(slug, [])--limit: bumped from 200 to 1000 for future-proofinghtml.escape()What was NOT changed
gh search issuesapproach (single call, works correctly, supportscommentsCountnatively)gh issue list(which has a different field name for comment counts:commentsreturns an array, not a count)Testing
flipper-linux-kernel#6now appears under Linux (CPU Software) — previously silently droppedCloses #371