Ok just to update this,
I figured out that the module that is being imported is actually part of
netsnmp. I changed the import in __init__.py to:
from .client import *
now I get when I do an import netsnmp :
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File
"/usr/lib/python3.3/site-packages/netsnmp_python-1.0a1-py3.3-linux-x86_64.egg/netsnmp/__init__.py",
line 1, in <module>
from .client import *
File
"/usr/lib/python3.3/site-packages/netsnmp_python-1.0a1-py3.3-linux-x86_64.egg/netsnmp/client.py",
line 1, in <module>
import client_intf
ImportError: No module named 'client_intf'
so I change in that import client_intf to
from .client_intf import *
I now get this :
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File
"/usr/lib/python3.3/site-packages/netsnmp_python-1.0a1-py3.3-linux-x86_64.egg/netsnmp/__init__.py",
line 1, in <module>
from .client import *
File
"/usr/lib/python3.3/site-packages/netsnmp_python-1.0a1-py3.3-linux-x86_64.egg/netsnmp/client.py",
line 1, in <module>
from .client_intf import *
ImportError:
/usr/lib/python3.3/site-packages/netsnmp_python-1.0a1-py3.3-linux-x86_64.egg/netsnmp/client_intf.cpython-33m.so:
undefined symbol: Py_InitModule
This is about as far as I can go.
I hope someone will be able to help in this.
Thanks
Regards,
Jason
From: Jason Pope [mailto:jp...@bats.com]
Sent: 12 March 2014 14:46
To: net-snmp-users@lists.sourceforge.net
Subject: Python 3 Bindings
Hi all,
Sorry to bump this again, but it I would really like to find a solution to
this. I am using 5.7.2.1
I have managed to get Net-SNMP to compile and install for Python 3.3.4 but when
I do an import netsnmp I get this :
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File
"/usr/lib/python3.3/site-packages/netsnmp_python-1.0a1-py3.3-linux-x86_64.egg/netsnmp/__init__.py",
line 1, in <module>
from client import *
ImportError: No module named 'client'
I cannot seem to find what module it is talking about.
If I # out that line in __init__.py I don’t get the traceback but then when I
do the following (as an example):
var = netsnmp.Varbind('sysDescr.0')
I get the following traceback :
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'Varbind'
Has anyone been able to get netsnmp bindings to work with Python 3 ? I have got
it to work perfectly with 2.6/2.7 but would prefer 3.3 if possible.
Thanks
Regards,
Jason
BATS Trading Limited is a Recognised Investment Exchange regulated by the
Financial Conduct Authority. BATS Trading Limited is an indirect wholly-owned
subsidiary of BATS Global Markets, Inc. and is a company registered in England
and Wales with Company Number 6547680 and registered office at 10 Lower Thames
Street, London EC3R 6AF. Confidentiality Notice: This email, including
attachments, may include non-public, proprietary, confidential or legally
privileged information. If you are not an intended recipient or an authorized
agent of an intended recipient, you are hereby notified that any dissemination,
distribution or copying of the information contained in or transmitted with
this e-mail is unauthorized and strictly prohibited. If you have received this
email in error, please notify the sender by replying to this message and
permanently delete this e-mail, its attachments, and any copies of it
immediately – you should not retain, copy or use this e-mail or any attachment
for any purpose, nor disclose all or any part of the contents to any other
person. Thank you.
BATS Trading Limited is a Recognised Investment Exchange regulated by the
Financial Conduct Authority. BATS Trading Limited is an indirect wholly-owned
subsidiary of BATS Global Markets, Inc. and is a company registered in England
and Wales with Company Number 6547680 and registered office at 10 Lower Thames
Street, London EC3R 6AF. Confidentiality Notice: This email, including
attachments, may include non-public, proprietary, confidential or legally
privileged information. If you are not an intended recipient or an authorized
agent of an intended recipient, you are hereby notified that any dissemination,
distribution or copying of the information contained in or transmitted with
this e-mail is unauthorized and strictly prohibited. If you have received this
email in error, please notify the sender by replying to this message and
permanently delete this e-mail, its attachments, and any copies of it
immediately – you should not retain, copy or use this e-mail or any attachment
for any purpose, nor disclose all or any part of the contents to any other
person. Thank you.
------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/13534_NeoTech
_______________________________________________
Net-snmp-users mailing list
Net-snmp-users@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users