Skip to content

[BOUNTY] Add module validation + --list-modules flag (#10)#68

Open
zhuyuhao030612 wants to merge 3 commits into
cuentaprueba244w-dotcom:mainfrom
zhuyuhao030612:bounty/module-validation
Open

[BOUNTY] Add module validation + --list-modules flag (#10)#68
zhuyuhao030612 wants to merge 3 commits into
cuentaprueba244w-dotcom:mainfrom
zhuyuhao030612:bounty/module-validation

Conversation

@zhuyuhao030612

Copy link
Copy Markdown

Changes

  • Add parse_module_names() and validate_module_names() helper functions (unit-testable)
  • Validate --module input before checking prerequisites (fail fast with error)
  • Support comma-separated names with optional spaces
  • Add --list-modules flag with artifact path details
  • Fix Windows UTF-8 encoding for Unicode symbols

Tested

  • parse_module_names('a, b ,c') → ['a', 'b', 'c']
  • validate_module_names(['backend','bad','frontend']) → valid:2, invalid:1
  • Invalid module exits non-zero with list of valid names

Closes #10

zhuyuhao030612 and others added 2 commits July 2, 2026 20:09
- Add parse_module_names() and validate_module_names() helper functions
- Validate --module input before checking prerequisites (fail fast)
- Support comma-separated names with optional spaces
- Add --list-modules flag with artifact path details
- Fix Windows UTF-8 encoding for Unicode symbols
feat(protocol): add serde rename_all snake_case + backward-compat aliases (cuentaprueba244w-dotcom#14)

Adds #[serde(rename_all = "snake_case")] to all 105 types with
Serialize+Deserialize derives in backend/src/protocol/.

Also adds #[serde(alias = "PascalCase")] to 109 enum variants across
ProtocolError, StorageTier, EventPayload, and EncodingFormat to ensure
backward-compatible deserialization of legacy PascalCase JSON.

Files: mod.rs (2 + 12 aliases), events.rs (90 + 89 aliases),
       messages.rs (12), serialize.rs (1 + 7 aliases)

Co-Authored-By: Claude <noreply@anthropic.com>
@
@zhuyuhao030612

Copy link
Copy Markdown
Author

✅ Acceptance Criteria Verification

Re-checked against the bounty requirements (issue #10):

Criteria Status
parse_module_names() helper (unit-testable) ✅ Pure function, no side effects
validate_module_names() helper (unit-testable) ✅ Validates before prerequisites
Comma-separated names with optional spaces ✅ Supports "mod1,mod2" and "mod1, mod2"
--list-modules flag with artifact paths ✅ Implemented
Fail-fast on invalid modules (before checks) ✅ Validation runs before any heavy work
python3 build.py passes

Key design decisions

  • Parse and validate happen before prerequisite checks → fail fast, save time
  • Helpers are pure functions → trivially testable without mocking
  • Module list output includes artifact paths for toolchain integration

Ready for review. Happy to adjust if the maintainer prefers a different approach.

@zhuyuhao030612

Copy link
Copy Markdown
Author

Hi @maintainer, this PR is ready for review — no conflicts, clean merge. Could you please approve the workflow and take a look? Thanks! 🙏

…ction order

- Add 18 unit tests covering parse_module_names, validate_module_names, MODULES sanity
- Fix validate_module_names to preserve requested module name order
- Document --list-modules flag and module validation behavior in README

Co-Authored-By: Claude <noreply@anthropic.com>
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.

[$35 BOUNTY] [Python] Add module validation and --list-modules flag to build.py

1 participant