Skip to content

M3/logger override minimal#65

Open
guru-code-expert wants to merge 4 commits intoAgentOpt:experimentalfrom
guru-code-expert:m3/logger-override-minimal
Open

M3/logger override minimal#65
guru-code-expert wants to merge 4 commits intoAgentOpt:experimentalfrom
guru-code-expert:m3/logger-override-minimal

Conversation

@guru-code-expert
Copy link
Copy Markdown

Summary

This PR adds minimal logger robustness needed for M3 integration with Trace-Bench UI/CLI.

Changes

  • Add NullLogger support.
  • Make load_logger() tolerant of none/null/off/disabled.
  • Unknown logger names now warn and fall back safely.
  • If a trainer class rejects logger=..., retry without logger (warn, continue).
  • Fix save_train_config wrapper to handle positional args correctly.

Validation

  • pytest -q tests/unit_tests/test_logger_override.py passes.
  • Verified compatibility with Trace-Bench logger override flow.

@doxav
Copy link
Copy Markdown
Collaborator

doxav commented Mar 6, 2026

Hi Asad,

This PR could be totally reduced because we should not change examples and some modifications could be in Trace-Bench.

Please remove all example-file smoke guards from OpenTrace, keep only the search_template.py fix, and move the rest into Trace-Bench.

  • Keep the save_train_config positional-args fix in search_template.py, and make Trace-Bench explicitly excludes SequentialUpdate, SequentialSearch, and BeamSearch if not fixed.

I propose you to:

  1. Rewrite tests/m1/test_opentrace_examples_smoke.py

    • remove env var injection
    • remove runpy.run_path(...)
    • replace with py_compile smoke
  2. Add a local no-op logger in Trace-Bench

    • trace_bench/null_logger.py
  3. Use that no-op logger when logger override is "none"

    • in Trace-Bench runtime resolution / runner path
  4. Handle error in SequentialUpdate, SequentialSearch, BeamSearch if Trace version does not have the search_template.py fix

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.

2 participants