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

Release for PyPI #20

Closed
vnitinv opened this issue Dec 28, 2015 · 3 comments
Closed

Release for PyPI #20

vnitinv opened this issue Dec 28, 2015 · 3 comments

Comments

@vnitinv
Copy link

vnitinv commented Dec 28, 2015

If we release the module to PyPI we wont face below issues while importing

>>> import bgp
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "bgp/__init__.py", line 3, in <module>
    from lib.yangtypes import RestrictedPrecisionDecimalType, RestrictedClassType, TypedListType
ImportError: No module named lib.yangtypes

currently to get rid of this issue, we have to define PYTHONPATH to the cloned folder path.

@robshakir
Copy link
Owner

Hi Nitin,

Sure -- we can look at that. At the moment rather than having to define PYTHONPATH everywhere, you can use the --pybind-class-dir switch to pyang, and that will append the path specified to the Python that using the sys module:

import sys
sys.path.append("/Users/rjs/Code/pyangbind")

It'd definitely be better to have this in an importable module - it is just a case of ensuring that the module is stable enough.

Cheers,
r.

@robshakir
Copy link
Owner

I did the work to package for PyPI -- please try the test package at https://testpypi.python.org/pypi/PyangBind/0.1.1 -- and check the packaging branch.

@robshakir
Copy link
Owner

Closed by #26

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

No branches or pull requests

2 participants