How to share lib/package with apps?

I need to create a snmp lib for access network equipments and i would share with Django apps. This lib is not a app, how to best form to create my lib inside django project?


Honestly, I’d create it as a separate package. Separation of concerns and all that. Having said that, a search for Python SMNP did produce some results for libraries that have been already written. I would suggest starting there.


We are doing that - we have Django views interacting with devices doing both snmpgets and snmpsets. (We’ve settled on [PySNMP]( We’ve tried the other available libraries, this one works best for us.)


Hi Guys,

Thank you for answer.

I will used a snmp lib that exists (pysnmp) and create a my own functions/classes based this lib.

I want share my lib based on pysnmp with one or more django apps.


That’s fine, you just create them like you would create any other library for installation in your python environment. See Packaging Python Projects for information on how to do this.

Note: While this page also includes the processes of uploading your project to PyPI, that is not a necessary step in this process. You can create your package (we build wheels) and then install it in any runtime environment you wish. It never needs to leave your environment.

Thanks Ken…

I will the link about Packing Pyhton Projects