MongoEngine / MongoEngine/mongoengine
Exporting Document as JSON schema
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 4.3k
- Forks
- 1.2k
- Avg merge
- 4h 41m
- Merged PRs (30d)
- 11
Description
Hi,
Is it possible to export a MongoEngine Document as a mongo-friendly JSON schema? It might be quite helpful for writing migrations and ensuring that the collection has exactly the data it should have without a bunch of corner cases.
The workflow is approximately like: write the model -> get the schema -> plug it into mongo with Warning level -> adjust -> deploy -> switch to Strict level -> repeat
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with MongoEngine Document models and the MongoDB $jsonSchema reference linked in the issue. Define the supported export behavior and verify that generated schemas can be used in the described Warning-to-Strict validation workflow.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- mongodb, python
- Domain
- backend, databases
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100