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

Installing the package messes up pymongo #29

Closed
eli-b opened this issue Mar 29, 2015 · 11 comments
Closed

Installing the package messes up pymongo #29

eli-b opened this issue Mar 29, 2015 · 11 comments
Milestone

Comments

@eli-b
Copy link

eli-b commented Mar 29, 2015

Pymongo installs its own bson package directly to site-packages (not into pymongo/bson for some reason). Accidentally installing this package causes pymongo imports like this to fail:
from bson.errors import *

@Parkayun Parkayun added bug and removed bug labels Jul 21, 2015
@nicklasb
Copy link

nicklasb commented Mar 7, 2016

Yes, there seem to have a serious conflict here.

Even though this might be a strange choice by MongoDB and not the fault of this library, there are a huge number of people using the mongodb python driver, and changing that may cause serious problems. Yes, changing this might too, but less, and the common good must be considered IMO.

There must be some way these two projects can coexist, perhaps they can block each others installations? Please communicate with MongoDB and try to find some solution.

@eli-b
Copy link
Author

eli-b commented Mar 9, 2016

So you'd be willing to check if Pymongo is installed during the setup of pybson and fail if it is?
If so, I could ask the Pymongo devs to do the same thing.

@nicklasb
Copy link

nicklasb commented Mar 9, 2016

@eli-b Me? Or @Parkayun ?

@eli-b
Copy link
Author

eli-b commented Mar 9, 2016

Whoever's most responsive to tickets :P

@nicklasb
Copy link

nicklasb commented Mar 9, 2016

Too bad it was me then, as I'm not involved in either project. :-)
On 9 Mar 2016 14:34, "Eli Boyarski" notifications@github.com wrote:

Whoever's most responsive to tickets :P


Reply to this email directly or view it on GitHub
#29 (comment).

@Parkayun
Copy link
Member

Umm... I don't have nice idea for this issue until now.

@eli-b
Copy link
Author

eli-b commented Mar 10, 2016

Now that @nicklasb has come up with the idea of just making sure neither package steps on the toes of the other, would you agree to it? I think it means refusing to install the package if Pymongo is already installed.

@Parkayun
Copy link
Member

Yep, I will add something like refusing feature or caution statements when install this package.
Thanks, both of you.

@nicklasb
Copy link

Yeah, and a really explanatory error message in addition to the failure
would be icing on the cake.

Glad to help!
On 11 Mar 2016 04:18, "Ayun Park" notifications@github.com wrote:

Yep, I will add something like refusing feature or caution statements when
install this package.
Thanks, both of you.


Reply to this email directly or view it on GitHub
#29 (comment).

@PhanindraPanthagani
Copy link

@Parkayun can you please tell whats the final fix ? I am still getting the error :
AttributeError: module 'bson' has no attribute 'BSON'

@Parkayun
Copy link
Member

This project has been for use bson module without mongodb driver.
And this package's description and purpose is Independent BSON codec for Python that doesn't depend on MongoDB..
So, I strongly suggest to don't use this package with pymongo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants