Repository navigation
Quiet the notebook output: no debug flood from ImageJ TIFFs - #271
Merged
Merged
Conversation
is_projected_copy parsed every TIFF description as OME-XML, so each ImageJ image logged a debug ParseError traceback. Only an OME-XML description is parsed now; a malformed one logs one debug line without a traceback. The notebook's log capture set the package logger to DEBUG while records still propagated to the root logger (Colab prints them). While attached, propagation is off and WARNING and above are forwarded to the root handlers. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G3qp9AxjpGPw9xfWAUJNqc
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G3qp9AxjpGPw9xfWAUJNqc
… root has no handler Without a root handler (plain Jupyter), propagation would have reached logging.lastResort; the forwarder now does the same, so package warnings stay visible. Regression test fails without the fix. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G3qp9AxjpGPw9xfWAUJNqc
guijacquemet
pushed a commit
that referenced
this pull request
Nov 10, 2026
…compact Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G3qp9AxjpGPw9xfWAUJNqc
guijacquemet
pushed a commit
that referenced
this pull request
Nov 10, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G3qp9AxjpGPw9xfWAUJNqc # Conflicts: # CHANGELOG.md
guijacquemet
pushed a commit
that referenced
this pull request
Nov 10, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G3qp9AxjpGPw9xfWAUJNqc
This was referenced Nov 10, 2026
Merged
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.
Owner report from Colab (v0.5.0, real ImageJ MAX-projection TIFFs): per image,
DEBUG:...projection_marker:Cannot read the description of <path>plus a fullParseErrortraceback.Causes
projection_marker.is_projected_copypassed any first-page description toElementTree.fromstring. ImageJ TIFFs have a plain-text description, so this failed for every such image (expected, not an error).notebook_ui._Attachedset the package logger to DEBUG while its capture handler was attached, and records still propagated to the root logger. Colab's root has a NOTSET stream handler, so every package DEBUG record printed.Fix
<is parsed; non-OME returns False silently. Malformed OME still returns False with one debug line, no traceback. Which images are marked is unchanged (projection_record_missingtests still pass).propagate = False(restored on exit), and a small handler forwards WARNING+ to the root handlers, so warnings stay visible as before. DEBUG goes to the "Technical details" panel only.--log(cli.py_attach_log): checked, no change. It adds a file handler to the package logger, so the logging last-resort stderr handler is not used and nothing reaches stderr.Other
exc_info=Truedebug logs (not changed)mounts.py:67,discovery.py:386,links.py:235,261,planes.py:659,metadata.py:295,330,338,ome_header.py:26,run/preflight.py:162,conversion_write.py:88,117. These log only on a real failure or per folder, not for every normal file; with the propagation fix none reaches the notebook output at DEBUG.ome_header.py:26is already guarded bytif.is_ome.Tests (fail before, pass after)
tests/test_projection_marker.py: ImageJ TIFF is not marked and logs no record; malformed OME is not marked with one debug record withoutexc_info; a marked projection is still marked.tests/test_notebook_log_capture.py: with a NOTSET rootStreamHandler, the attached capture keeps DEBUG off root but in the panel, WARNING reaches root, and logger state is restored.Verification
python tools/check.py: 5167 passed, 4 skipped (case-sensitive file system x3, file-mode permissions x1; all unrelated), ruff clean, code rules ok.Generated by Claude Code