Johnfreeman/detdataformats issue100 code refactoring#101
Merged
jcfreeman2 merged 10 commits intoApr 28, 2026
Conversation
added 8 commits
April 15, 2026 16:50
…s to regular data types where possible to make checking more thorough
…s explicitly initialize uninitialized members to (absurd) values
In practice, this means simplifying DetID, since nowhere in the codebase is its version field used or is its "is_in_valid_state()" function called (which is just a check that the wrapped enum value isn't kUnknown).
…putting streamer declarations into headers but their definitions into *.hxx files
… with our coding standards, as well as quieting linter complaints about unavoidable unsigned integer use
eflumerf
reviewed
Apr 27, 2026
…tionality Eric introduced into styleguide scripts to deal with extensive unsigned integer use; also update unit tests to pass our linters
eflumerf
reviewed
Apr 28, 2026
…atment to hsi.cpp
13 tasks
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.
Description
This is a refactor of the existing code, along with the addition of tests and the removal of a little unused API surface; it can be considered part of Issue #100, which itself falls under the umbrella of DUNE-DAQ/daq-deliverables#215.
Further details can be found in the commit statements themselves, but broadly speaking, this PR will:
HSIFrame,DAQHeaderandDAQEthHeader, none of which previously had unit testsscripts/directory which can be run to test the Python bindings in this package*.hxxfilesDetID::to_stringfunction as well as theversionfield ofDetID, which I don't see used anywhere. If we're going to re-introduce it I feel like it should be under the condition that we put in PRs for code which use it in downstream packages.kVD_BernCRTandkVD_GrenobleCRTenum values forDetID) or which help with testing other Python bindings.Testing the changes will involve:
Note that suggestions which will affect the interface should be implemented in a separate PR. Note also that after this PR is approved the code will be run through
clang-format.A test build using this feature branch was created for testing purposes,
DDFFD_DEV_260427_A9.Type of change
Testing checklist
dbt-build --unittest)pytest -s minimal_system_quick_test.py)dunedaq_integtest_bundle.sh) (*)python -m pytest)pre-commit run --all-files)(*) One thing went wrong during the integration tests, but it's not related to this PR and is the sort of thing we see occasionally in our nightlies: in the tpstream test there was
There were 2 failures to insert data into the latency buffer out of 4882 attempts in the latest monitoring interval.Further checks
dbt-build --lint, and/or see https://dune-daq-sw.readthedocs.io/en/latest/packages/styleguide/)(Indicate issue here: # (issue))