etingof / pysnmp

Python SNMP library
http://snmplabs.com/pysnmp/
BSD 2-Clause "Simplified" License
577 stars 193 forks source link

pysnmp.carrier.asyncore.dgram.udp.DOMAIN_NAME not found #386

Open DineshDevaraj opened 3 years ago

DineshDevaraj commented 3 years ago

root@84b3d97bf191:~/programs/learn-pysnmp# python3
Python 3.8.5 (default, Jul 28 2020, 12:59:40)
[GCC 9.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.

import pysnmp
pysnmp.version
'4.4.12'
from pysnmp.carrier.asyncore.dgram import udp
udp.DOMAIN_NAME
Traceback (most recent call last):
File "", line 1, in
AttributeError: module 'pysnmp.carrier.asyncore.dgram.udp' has no attribute 'DOMAIN_NAME'

lextm commented 1 year ago

The 4.4.12 release is different https://github.com/etingof/pysnmp/blob/v4.4.12/pysnmp/carrier/asyncore/dgram/udp.py#L11 so you should use udp.domainName instead.

lextm commented 3 days ago

After closing #429, time to revisit this.

PEP 8 compliant upper case names were planned to ship in Ilya's 5.0 release, which was never out.

As new maintainers, my team is able to ship the related changes in release 7.0.