Commit Graph

5 Commits

Author SHA1 Message Date
Stacy Olivas ce7adc55f8 ci: add log injection regression check to CI pipeline
Add scripts/check_log_injection.py to scan for unsanitized variables in
log calls and fail CI if new violations are introduced. Baseline is
committed at zero violations after fixing all 26 pre-existing ones.

Update TESTING.md with instructions for running the check locally.
2026-04-14 10:02:36 -07:00
Stacy Olivas 92c591024d ci: drop Python 3.9 from test matrix
meshcore >=2.2.31 requires Python >=3.10; 3.9 is not installable
and was failing the dependency install step in CI.
2026-03-17 20:54:52 -07:00
Stacy Olivas a12797f87a infra: CI lint gates for ruff, mypy, eslint, and shellcheck
Add four jobs to .github/workflows/test.yml:
- lint: ruff check modules/ tests/ — zero violations enforced
- typecheck: mypy modules/ with incremental strict mode; per-module
  disallow_untyped_defs where applicable
- lint-frontend: ESLint (eslint-plugin-html) + HTMLHint on templates/
- lint-shell: ShellCheck --severity=warning on all .sh files

Add [tool.ruff] and [tool.mypy] sections to pyproject.toml.
Add .eslintrc.json, .htmlhintrc, package.json for frontend tooling.
2026-03-17 17:42:41 -07:00
Stacy Olivas 0b82a0cf9d infra: pytest configuration, timeout enforcement, and coverage threshold
- pytest-timeout>=2.1.0 added; timeout=30s per test prevents runaway
  tests from hanging CI
- asyncio_mode=auto in pyproject.toml [tool.pytest.ini_options]; async
  tests run without per-test markers
- fail_under=27 in [tool.coverage.report] as the enforced coverage
  floor; target 40% tracked in TASK-14
- CI test matrix updated for Python 3.9, 3.11, 3.12
2026-03-17 17:40:52 -07:00
agessaman d699ea1cf1 Update configuration handling and validation for bot sections
- Enhanced .gitignore to allow test files in the tests/ directory and committed pytest.ini for test discovery.
- Added checks for missing sections in configuration files, specifically for Admin_ACL and Banned_Users, to prevent errors during bot startup.
- Updated generate_website.py and command_manager.py to handle cases where required sections are absent, returning empty lists instead of raising exceptions.
- Introduced optional dependencies for testing in pyproject.toml, ensuring a smoother development experience.
- Improved localization handling in core.py to default to English when the Localization section is missing, enhancing user experience.
2026-02-12 19:23:35 -08:00