Skip to content

fix: Map missing fields in Chromeleon parser for adapter migration#1207

Merged
nathan-stender merged 1 commit into
mainfrom
fix/chromeleon-missing-field-mappings
May 26, 2026
Merged

fix: Map missing fields in Chromeleon parser for adapter migration#1207
nathan-stender merged 1 commit into
mainfrom
fix/chromeleon-missing-field-mappings

Conversation

@nathan-stender

Copy link
Copy Markdown
Collaborator

Summary

  • Fixes crash when device_information is null in raw JSON (Glycans sequence)
  • Maps analyst and submitter per LC document from injection-level fields
  • Maps injection namesample document.written name
  • Uses signal name as device type instead of hardcoded "HPLC"
  • Uses sampler model number as asset management identifier when available
  • Merges non-null custom variables into injection custom info

Context

The Chromeleon adapter is migrating from producing ASM directly to producing a raw JSON dump parsed by the allotropy BENCHLING_CHROMELEON parser. The raw JSON contains all the data but several critical fields were not being mapped into ASM output. This PR closes all mapping gaps so the new pipeline produces equivalent output to the old adapter.

Test plan

  • All 8 production sequences from output.zip parse successfully (including previously-crashing Glycans)
  • No data loss in existing test output (verified via DeepDiff)
  • New test cases added: null device_information + custom variables + non-UV signals, and multi-signal + valid sampler model
  • Other parsers using same schema mapper (cytiva_unicorn, benchling_empower, agilent_openlab_cds) still pass
  • Vendor discovery tests pass (313 tests)
  • Lint passes

🤖 Generated with Claude Code

The Chromeleon adapter is migrating from producing ASM directly to
producing raw JSON that goes through the allotropy parser. This fixes
all field mapping gaps so the parser output matches the old adapter.

- Handle null device_information without crashing
- Map analyst (injection.last update user name) per LC document
- Map submitter (injection.creation user name) per LC document
- Map injection name to sample document written name
- Use signal name as device type instead of hardcoded "HPLC"
- Use sampler model number as asset management identifier when available
- Merge non-null custom variables into injection custom info

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@nathan-stender
nathan-stender requested review from a team and slopez-b as code owners May 22, 2026 19:37
@nathan-stender
nathan-stender merged commit 05cc0d3 into main May 26, 2026
9 checks passed
@nathan-stender
nathan-stender deleted the fix/chromeleon-missing-field-mappings branch May 26, 2026 17:08
nathan-stender added a commit that referenced this pull request May 26, 2026
### Fixed

- Map missing fields in Chromeleon parser for adapter migration (#1207)
nathan-stender added a commit that referenced this pull request May 27, 2026
…ser (#1210)

## Summary

- Maps `relative area group` from peak data into peak custom information
document
- Maps `number of calibration points` from peak data into peak custom
information document

## Context

Follow-up to #1207. These two peak-level fields were identified as
unmapped gaps between the old Chromeleon adapter output and the new
allotropy parser output.

The gap report also flagged `bandwidth setting` and `relative retention
time` but those are already correctly mapped (bandwidth as `detector
bandwidth setting`, relative retention time as a standard peak field).

## Test plan

- [x] Verified `relative area group` appears in output (e.g. 6.65 in
Glycans peaks)
- [x] Verified `number of calibration points` appears in output (0.0 in
BioChem/S15 peaks)
- [x] All Chromeleon parser tests pass
- [x] Regenerated `new_updated/` output files for downstream CSV parser
comparison

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
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