-
Type:
Task
-
Resolution: Done
-
Priority:
Major - P3
-
Affects Version/s: None
-
Component/s: None
-
None
Drop mongodb-query-parser dependency from compass-components package. In this package it is only used to get the stringified value of DBRef. Add an inline implementation to avoid circular dependency.
Within this project, we deprecated mongodb-query-parser in favor of @mongodb-js/shell-bson-parser. The published mongodb-query-parser version uses old, pre-rewrite @mongodb-js/shell-bson-parser releases that exposed a sync & cjs API.
As we are moving @mongodb-js/shell-bson-parser to a worker-based parsing (api changes from sync to async), it will be only published as an ESM package. That's an intentional, deliberate change on the parser side (parsing now happens off the main thread in a sandboxed worker), but it means any package still requiring the old sync/CJS shape of @mongodb-js/shell-bson-parser - directly or transitively, like the old mongodb-query-parser releases - breaks once it resolves against the new version instead of the one it was actually built against.
In our devtools-shared monorepo, @mongodb-js/shell-bson-parser is workspace package and @mongodb-js/oidc-http-server-pages transitively depends on it through mongodb-query-parser. This breaks the expected dependency resolution.