Define required practices for maintainer Python under cicd/: CLI parsing, input checks, shared modules, and converter layout so scripts stay consistent and safe for pipeline use.
- Parse CLI with
argparse(or equivalent structured parsing). Do not hand-rollsys.argvsplitting for subcommands without validating tokens. - For user-controlled URLs, stems, and refs: use
cicd/validate_input.py(validate_*astype=) or equivalent checks; seedocs/CICD/python_cli_security.mdfor full rules. - Subprocess:
subprocess.run(..., shell=False)with a fixed argv list; never route user strings throughshell=True. - Converters: shared URL and YAML helpers belong in
cicd/convert/convert_common.py; URL constants at module level or inconvert_common, not buried inside functions (perAGENTS.md). - New converter scripts: metadata docstring header (
Name,Author,License,Repository,Description); complete work only afterpython3 cicd/build/procedure_shell.py --validateon a sample draft.
docs/CICD/python_cli_security.mdcicd/validate_input.pycicd/convert/convert_common.pyAGENTS.md.cursor/rules/attack-macos-maintainer.mdc
Last modified: 2026-05-15
Last modified by: Documentation maintainers
Version: 1.0.0