Skip to content

Add independent log parser fixtures#45

Open
victordb9997 wants to merge 1 commit into
weilixiong:mainfrom
victordb9997:fix-log-parser-fixtures-5
Open

Add independent log parser fixtures#45
victordb9997 wants to merge 1 commit into
weilixiong:mainfrom
victordb9997:fix-log-parser-fixtures-5

Conversation

@victordb9997

Copy link
Copy Markdown

Summary

Adds independent hand-written parser fixtures for JSON, plain text, and nginx-style logs so parser coverage no longer relies on parser-generated samples.

Fixes #5.

Changes

  • Added fixture-backed parser tests for JSON, text, nginx, and malformed-line handling.
  • Run nginx parsing before the generic text fallback so access logs keep structured nginx fields.
  • Corrected nginx remote_user extraction to use the third access-log field.
  • Resolved command shims before subprocess.run() in build.py so Windows .cmd tools such as npm.cmd can be launched during validation.

Testing

  • python -m unittest tests.test_log_aggregator_fixtures -v passes.
  • PYTHONIOENCODING=utf-8 python build.py was attempted locally. The build script now reaches the module build summary, but this Windows machine is missing several project toolchains (cargo, go, gcc, cmake, make, javac, ruby, luac, ghc) and the bundled diagnostic pack step failed after the summary, so I could not generate a new diagnostic/build-*.logd artifact here.

Checklist

  • Relevant modules affected by these changes build locally
  • Tests pass locally
  • Diagnostic build log is committed in this PR
  • Documentation has been updated, if applicable
  • Configuration or schema changes are documented, if applicable
  • No generated build artifacts are committed, except the required diagnostic build log
  • Changes are scoped to the PR purpose and avoid unrelated cleanup
  • Security, privacy, and error-handling implications have been considered

  • I would like to request that my diagnostic build log is removed before merging

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.

[$25 BOUNTY] [Python] Add independent log parser fixtures

1 participant