Closed paparomeo closed 10 years ago
I'm hitting the same issue here when installing python_3_beta
fresh, without requests
installed beforehand. Any word on this?
@pmcnr @agjohnson Thanks for the report. pkg_resources
is part of setuptools
, not the standard library. We try to avoid dependencies whenever possible so I don't think the proposed fix works in this case. It looks like the simplest solution is putting the version string in both version.py
and setup.py
. I'll do that in the next version of the python_3_beta
branch unless a better idea presents itself.
If you have any other problems / have any feedback about the python_3_beta
branch, please let us / me know.
https://github.com/braintree/braintree_python/pull/39 addresses this without depending on setuptools
.
Fixed by 3.0.0.
Importing the
braintree.version
module insetup.py
will import thebraintree
package which in turn, by importing all its modules into its namespace will end in the chain of imports attempt to importrequests
. This preventssetup.py
from working correctly ifrequests
hasn't been previously installed manually.The proposed change, by moving the package version declaration to
setup.py
and then reading that inbraintree.version
avoids this problem and enables the automatic install ofrequests
as a dependency.