Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix load_module bug with unserializable objects #462

Conversation

dagardner-nv
Copy link
Contributor

@dagardner-nv dagardner-nv commented Apr 4, 2024

Description

  • PR Update cast_from_pyobject to throw on unsupported types rather than returning null #451 changed the cast_from_pyobject behavior to throw an exception rather than returning a null.
  • This broke dfp_integrated_training_batch_pipeline.py which stored datetime objects in the module config.
  • This PR back-patches the unserializable_handler_fn functionality from 24.06, and adds a handler to ModuleRegistryProxy::get_module_constructor and BuilderProxy::load_module_from_registry to restore the original functionality as a quick-fix for 24.03

Checklist

  • I am familiar with the Contributing Guidelines.
  • New or existing tests cover these changes.
  • The documentation is up to date with these changes.

@dagardner-nv dagardner-nv added bug Something isn't working non-breaking Non-breaking change skip-ci Optionally Skip CI for this PR labels Apr 4, 2024
@dagardner-nv dagardner-nv self-assigned this Apr 4, 2024
@dagardner-nv dagardner-nv requested a review from a team as a code owner April 4, 2024 17:14
@dagardner-nv dagardner-nv marked this pull request as draft April 4, 2024 17:14
@dagardner-nv dagardner-nv removed the skip-ci Optionally Skip CI for this PR label Apr 4, 2024
@dagardner-nv dagardner-nv marked this pull request as ready for review April 4, 2024 18:35
Copy link
Contributor

@cwharris cwharris left a comment

Choose a reason for hiding this comment

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

LGTM

@dagardner-nv dagardner-nv marked this pull request as draft April 4, 2024 19:06
Copy link

codecov bot commented Apr 4, 2024

Codecov Report

Merging #462 (0c1a001) into branch-24.03 (bd7955e) will increase coverage by 0.00%.
Report is 1 commits behind head on branch-24.03.
The diff coverage is 88.23%.

Additional details and impacted files

Impacted file tree graph

@@              Coverage Diff              @@
##           branch-24.03     #462   +/-   ##
=============================================
  Coverage         73.68%   73.68%           
=============================================
  Files               400      400           
  Lines             14275    14286   +11     
  Branches           1113     1115    +2     
=============================================
+ Hits              10518    10527    +9     
- Misses             3757     3759    +2     
Flag Coverage Δ
cpp 70.18% <35.29%> (-0.05%) ⬇️
py 41.82% <86.66%> (+0.07%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
python/mrc/_pymrc/src/utils.cpp 86.36% <100.00%> (+0.82%) ⬆️
python/mrc/_pymrc/src/module_registry.cpp 86.48% <75.00%> (-1.75%) ⬇️
python/mrc/_pymrc/src/segment.cpp 81.81% <75.00%> (-0.31%) ⬇️

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update bd7955e...0c1a001. Read the comment docs.

@dagardner-nv
Copy link
Contributor Author

Closing this PR in favor of fixing the issue on the Morpheus side, serializing to a json null simply hid a bug in Morpheus.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working non-breaking Non-breaking change
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants