feat(builder-sidecar): log API calls to LOG_DIR for evaluation#150
Open
feat(builder-sidecar): log API calls to LOG_DIR for evaluation#150
Conversation
f747fae to
231de63
Compare
Add structured JSONL logging of every builder sidecar API call (run-pov, apply-patch-build, run-test) for CRS evaluation. Closes #148 Signed-off-by: Dongkwan Kim <0xdkay@gmail.com>
22 tests covering _make_log_entry and JSONL file writing. Signed-off-by: Dongkwan Kim <0xdkay@gmail.com>
231de63 to
486f866
Compare
Collaborator
|
I'll reimplement this in the new builder sidecar workflow. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add structured JSONL logging of every builder sidecar API call (
run-pov,apply-patch-build,run-test) toOSS_CRS_LOG_DIRfor CRS evaluation.Closes #148
Implementation
/sidecar-logsvialibCRS register-log-dirat startup, symlinked to host-mountedOSS_CRS_LOG_DIRapi-calls.jsonlts,api,job_id,exit_code,duration_ms, plus api-specific fieldsharness/build_idin result dicts (no separate pre-read needed)crashusesexit_code > 0to avoid false positives from handler exceptions (sentinel-1)api-calls.jsonlcreated at startup to distinguish "zero calls" from "sidecar never started"Log entry examples
Bug-finding (crs-bug-finding-claude-code on sanity-mock-c-delta-01):
{"ts":1774296986.79,"api":"run-pov","job_id":"2b9ec6bf26cf","duration_ms":58,"exit_code":1,"harness":"fuzz_parse_buffer_section","build_id":"base","crash":true,"timeout":false} {"ts":1774297023.24,"api":"run-pov","job_id":"dbe6bf714002","duration_ms":55,"exit_code":1,"harness":"fuzz_parse_buffer_section","build_id":"base","crash":true,"timeout":false} {"ts":1774297067.71,"api":"run-pov","job_id":"bcee79ed184a","duration_ms":65,"exit_code":77,"harness":"fuzz_parse_buffer_section","build_id":"base","crash":true,"timeout":false}Bug-fixing (crs-claude-code on sanity-mock-c-delta-01 with POV input):
{"ts":1774300121.36,"api":"build","job_id":"52d872574bec","duration_ms":551,"exit_code":0,"build_success":true} {"ts":1774300136.70,"api":"run-pov","job_id":"d9f4cce856b6","duration_ms":107,"exit_code":1,"harness":"fuzz_parse_buffer_section","build_id":"base","crash":true,"timeout":false} {"ts":1774300148.91,"api":"run-pov","job_id":"21fc5831ed93","duration_ms":90,"exit_code":0,"harness":"fuzz_parse_buffer_section","build_id":"52d872574bec","crash":false,"timeout":false} {"ts":1774300159.91,"api":"run-test","job_id":"bd45c2ec677e","duration_ms":176,"exit_code":0,"build_id":"52d872574bec","test_passed":true,"skipped":false}Log file location
Collected by
oss-crs artifactsvia thelog_dirfield, and by CRSBench adapter totrial_dir/output/logs/crs/<crs>/log_dir/sidecar-logs/api-calls.jsonl.Smoke test results
Tested against
sanity-mock-c-delta-01(fuzz_parse_buffer_sectionharness):Test plan
api-calls.jsonlpersists in LOG_DIR on hostoss-crs artifactsreportslog_dircontaining the file