Skip to content

fix(distributions): name get_distribution in unknown-family error - #628

Merged
mkumar73 merged 2 commits into
OpenTabular:mainfrom
jorisstrakeljahn:fix/unknown-family-error-label
Nov 14, 2026
Merged

mkumar73 merged 2 commits into
OpenTabular:mainfrom
jorisstrakeljahn:fix/unknown-family-error-label

Conversation

@jorisstrakeljahn

Copy link
Copy Markdown
Contributor

With an unknown family, every LSS model raises an error that starts with "MambularLSS / LSS model.family". I got this with MLPLSS, so the message names a model I did not use. The reason is that the label is hard-coded in get_distribution().

So this PR changes the label to "get_distribution", the function that checks the argument. That way the message is right for every caller. unregister_optimizer() and unregister_scheduler() already do the same for their own arguments.

I also changed the existing test for an unknown family, so it now checks the message too. With the code from main it fails.

just test: 3355 passed
just check passes

@codecov-commenter

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@mkumar73 mkumar73 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jorisstrakeljahn,

  • Error message now correctly identifies the shared distribution lookup, with regression coverage.
  • All checks pass.
  • PR approved

thank you for the fix!

@mkumar73
mkumar73 merged commit 356963d into OpenTabular:main Nov 14, 2026
35 checks passed
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.

3 participants