trap-cards check: require a sample and an eval case for every trap
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 82/100
- Issue type
- Feature
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- c, cmake
- Domain
- build-system, testing
Research direction
Read cmake/check-trap-cards.cmake lines 34–52 and the trap-cards test controls in CMakeLists.txt lines 204–236. Trace how fixture folders are found and how controls check failure messages, then run the documented CMake and CTest commands. Done means all 17 traps pass, missing samples and cases are reported by trap id, and the empty-samples control passes only on the new message.
Written by the indexing model from the issue text.
Description
CONTRIBUTING.md says a trap is four pieces "and CI checks that they match". In fact, CI only matches cards with fixture folders. Nothing checks that a fixture also has samples/<id>/ and an eval case, so a trap PR that leaves those out still passes CI.
What to do
Give cmake/check-trap-cards.cmake the samples and evals folders (-DSAMPLES=, -DEVALS=). For every fixture folder, require samples/<id>/CMakeLists.txt, samples/<id>/src/main.c and plugins/sdl3-porter/evals/<id>/case.yaml, and report what's missing by trap id. Check in this direction only, because samples/bounce and the port-sample case have no fixture on purpose. Pass the new variables to every test that runs the script, and add a positive control that points SAMPLES at an empty folder and passes only on the new message.
Where to look
cmake/check-trap-cards.cmakelines 34-52CMakeLists.txtlines 204-236: thetrap-cardstest and its controlsCONTRIBUTING.mdlines 17-25: the four pieces
Done when
- The check names each trap with a missing sample or case.
- All 17 current traps pass.
- The new control passes only on its message.
Testing it
cmake -S . -B build
ctest --test-dir build -C Debug -R trap-cards --output-on-failure
- Dominant language
- C
- Stars
- 1
- Forks
- 1
- Avg merge
- 3m
- Merged PRs (30d)
- 1
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from hazeliscoding/sdl3-porter
-
trap-cards check: require every part of a trap cardPossibly taken A pull request linked to this issue is open or already merged. Openenhancement good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
hazeliscoding/sdl3-porter#20 ·
-
documentation good first issue
Difficulty 1/5 1-3 hours Newbie friendliness 83/100
hazeliscoding/sdl3-porter#19 ·
-
Test find_traps.py's search of the committed SDL2 codePossibly taken @ian0318git claimed this 2 days ago. Opengood first issue
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
hazeliscoding/sdl3-porter#18 ·
-
bug good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
hazeliscoding/sdl3-porter#17 ·
-
help wanted trap candidate
Difficulty 5/5 Over a week Newbie friendliness 25/100
hazeliscoding/sdl3-porter#16 ·
All issues in hazeliscoding/sdl3-porter
Similar issues
-
category:port-update
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
Maintainers usually reply within 2 days
-
emerge failure MARK mark-unstable media-kit
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
macaroni-os/mark-issues#834 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
NVIDIA/open-gpu-kernel-modules#1479 · 2 comments ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
Difficulty 1/5 Under an hour Newbie friendliness 93/100
webarkit/WebARKitLib#107 ·
Maintainers usually reply within 1 day