-
Notifications
You must be signed in to change notification settings - Fork 8
Attempt to vendor the stand-alone bson package to prevent conflicts with pymongo #250
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
Conversation
|
Tests generally work, but the linter is failing. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #250 +/- ##
=======================================
Coverage 99.76% 99.76%
=======================================
Files 16 16
Lines 2126 2126
=======================================
Hits 2121 2121
Misses 5 5
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
jnation3406
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not up to speed on what the core issue was, but it seems like pymongo packages a bson implementation within it and installs it separately as bson, but its really a modified version of bson and not what you have copied here and wanted installed? Is the main problem that users of hop client that already have mongodb installed break their pymongo when installing hop-client since it installs the base bson over the already installed customized mongodb bson? It looks like its using a c implementation for a some of the bson stuff in pymongo here... Would it work to just depend on pymongo (which contains bson) rather than bson in the hop-client? It seems like the internal pymongo bson codec might be more efficient anyway since it uses c.
|
#248 describes the original problem pretty succintly, which is that if hop-client is installed (it need not even be imported), pymongo is broken and cannot be imported. |
adambrazier
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me (inasmuch as I understand pyproject.toml)
* Activate LSPhotoZ with Secrets + PlotLightcurve with new Slack API. * Jobs and processes to try out LSST units. * mypy fixes * Set avro schema for elasticc alerts * Bump version * Use plot API for parsnip plots * Begin typing BaseClassifier internals * Relax typing of plot * First crack at LSSTReport * Bail on empty or missing T2RunParsnipRiseDecline result * register T2LSSTReport * chore: Update README for 7c6c243 * Fix NamedSecret bug. * New Decent filter for VRO. * Units for filtering+specific reporting of VRO alerts. * chore: Update README for 7c6c243 * chore: format * fixup! Units for filtering+specific reporting of VRO alerts. Revert presumably botched merge of T2BaseClassifier * fixup! Begin typing BaseClassifier internals * Remove report_t2s; information already present in t2_dependency * Avoid possibly unbound features * fixup! Remove report_t2s; information already present in t2_dependency * Annotate fields with docs * use AvroSchema in KafkaAdapter * Support general auth schemes * Add Hopskotch adapter * Include compound id in report * simplify torch requirement * drop implicit bson requirement See scimma/hop-client#250 * Use ampel secret. * More general reports. * Bugfixes for report units. * Adding source report field. * sample lsst jobs * Check xaxis length, and do not do slackpost if nothing found. * Sample job for filtering and plotting vro alerts. * mypy fixes * Remove old parsnip plot commans. * Adding T2 unit for Lasair annotations. * Updated config and demos for lasair annotation. * change name * Inherit from AbsTabulatedT2Unit only once * advance ampel-lsst * ruff * advance ampel-lsst again * advance ampel-ztf (astropy 7.2 compat) * shiny for mypy * Drop built-in channel and process defs * ignore import errors on unit inventory * Drop py 3.11 support, too * chore: Update README for 8d425e5 * refresh lock to pick up latest ampel-core that hopefully allows configs to build without error out of the box * make lasair optional * remove boilerplate * avoid post_init antipattern * avoid post_init antipattern --------- Co-authored-by: Jakob van Santen <jvansanten@gmail.com>
Description
This attempts to fix #248 while keeping large message offload support working by default.
Checklist
/tests, ensuring sufficient code coverage.make testruns without errors.make lintdoesn't give any warnings.make formatdoesn't give any code formatting suggestions.make docruns without errors and generated docs render correctly.NOTE: If this PR relates to a release, open and reference an issue with the Release checklist template.