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

Support pyproject.toml for configuration #81

Open
rkingsbury opened this issue Aug 25, 2023 · 3 comments
Open

Support pyproject.toml for configuration #81

rkingsbury opened this issue Aug 25, 2023 · 3 comments
Assignees
Labels
enhancement New feature or request

Comments

@rkingsbury
Copy link

Thanks for developing this very useful library! I am evaluating it as an alternative to mongomock in a data management library maggma.

Currently pymongo_inmemory.context.conf reads setup.cfg. Is it possible to support pyproject.toml configuration as well? My understanding is that this is now the preferred approach for package configuration.

I can work on a PR if desired. Thanks!

@rkingsbury rkingsbury added the enhancement New feature or request label Aug 25, 2023
@rkingsbury
Copy link
Author

Also a related question - do kwargs passed to MongoClient() override the configuration settings? e.g., will

MongoClient(port=27020)

Override

[pymongo_inmemory]
mongod_port = 27019

in setup.cfg?

@ekarademir
Copy link
Collaborator

Hi @rkingsbury, thanks for using the library!

Currently pymongo_inmemory.context.conf reads setup.cfg. Is it possible to support pyproject.toml configuration as well?

Defnitely a good use case. I'll look into the PR as soon as I can. Thank you for the PR.

Also a related question - do kwargs passed to MongoClient() override the configuration settings?

Unfortunately not currently. I think with the last refactor I caused a regression there. I'll try to fix that.

@ekarademir ekarademir self-assigned this Aug 25, 2023
@ekarademir
Copy link
Collaborator

Thank you for the PR.

Ah I thought the referred PR related to the library :D If you can create a PR that is more than welcome. This was something I was thinking of as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants