diff --git a/README.md b/README.md index db79d63b5..ae49ba65d 100644 --- a/README.md +++ b/README.md @@ -151,7 +151,7 @@ asyncio.run(run()) $ python3 examples/hlapi/asyncio/manager/cmdgen/usm-sha-aes128.py SNMPv2-MIB::sysDescr.0 = SunOS zeus.pysnmp.com 4.1.3_U1 1 sun4m $ -$ python3 examples//hlapi/asyncore/sync/agent/ntforg/v3-inform.py +$ python3 examples/hlapi/asyncio/agent/ntforg/v3-inform.py SNMPv2-MIB::sysUpTime.0 = 0 SNMPv2-MIB::snmpTrapOID.0 = SNMPv2-MIB::warmStart SNMPv2-MIB::sysName.0 = system name diff --git a/pysnmp/entity/config.py b/pysnmp/entity/config.py index 0468f5759..16828d102 100644 --- a/pysnmp/entity/config.py +++ b/pysnmp/entity/config.py @@ -5,7 +5,7 @@ # License: https://www.pysnmp.com/pysnmp/license.html # from pyasn1.compat.octets import null -from pysnmp.carrier.asyncore.dgram import udp, udp6, unix +from pysnmp.carrier.asyncio.dgram import udp, udp6, unix from pysnmp.proto.secmod.rfc3414.auth import hmacmd5, hmacsha, noauth from pysnmp.proto.secmod.rfc3414.priv import des, nopriv from pysnmp.proto.secmod.rfc3826.priv import aes diff --git a/pysnmp/entity/rfc3413/oneliner/cmdgen.py b/pysnmp/entity/rfc3413/oneliner/cmdgen.py index 5dc0ff9e9..b3283e9ae 100644 --- a/pysnmp/entity/rfc3413/oneliner/cmdgen.py +++ b/pysnmp/entity/rfc3413/oneliner/cmdgen.py @@ -7,8 +7,8 @@ # All code in this file belongs to obsolete, compatibility wrappers. # Never use interfaces below for new applications! # -from pysnmp.hlapi.asyncore import * -from pysnmp.hlapi.asyncore import sync +from pysnmp.hlapi.asyncio import * +from pysnmp.hlapi.asyncio import sync from pysnmp.hlapi.varbinds import * from pysnmp.hlapi.lcd import * from pyasn1.compat.octets import null diff --git a/pysnmp/entity/rfc3413/oneliner/ntforg.py b/pysnmp/entity/rfc3413/oneliner/ntforg.py index be7db1b1b..8d5dcffae 100644 --- a/pysnmp/entity/rfc3413/oneliner/ntforg.py +++ b/pysnmp/entity/rfc3413/oneliner/ntforg.py @@ -7,8 +7,8 @@ # All code in this file belongs to obsolete, compatibility wrappers. # Never use interfaces below for new applications! # -from pysnmp.hlapi.asyncore import * -from pysnmp.hlapi.asyncore import sync +from pysnmp.hlapi.asyncio import * +from pysnmp.hlapi.asyncio import sync from pysnmp.hlapi.varbinds import * from pysnmp.hlapi.lcd import * from pyasn1.compat.octets import null diff --git a/pysnmp/hlapi/__init__.py b/pysnmp/hlapi/__init__.py index 343b8ac13..9231dca1b 100644 --- a/pysnmp/hlapi/__init__.py +++ b/pysnmp/hlapi/__init__.py @@ -11,8 +11,8 @@ from pysnmp.hlapi.context import * from pysnmp.entity.engine import * -# default is synchronous asyncore-based API -from pysnmp.hlapi.asyncore.sync import * +# default is synchronous asyncio-based API +from pysnmp.hlapi.asyncio import * CommunityData = auth.CommunityData diff --git a/pysnmp/hlapi/asyncore/__init__.py b/pysnmp/hlapi/asyncore/__init__.py index 02223f7a9..615069cb7 100644 --- a/pysnmp/hlapi/asyncore/__init__.py +++ b/pysnmp/hlapi/asyncore/__init__.py @@ -8,7 +8,7 @@ from pysnmp.smi.rfc1902 import * from pysnmp.hlapi.auth import * from pysnmp.hlapi.context import * -from pysnmp.hlapi.asyncore.transport import * -from pysnmp.hlapi.asyncore.cmdgen import * -from pysnmp.hlapi.asyncore.ntforg import * +from pysnmp.hlapi.asyncio.transport import * +from pysnmp.hlapi.asyncio.cmdgen import * +from pysnmp.hlapi.asyncio.ntforg import * from pysnmp.entity.engine import * diff --git a/pysnmp/hlapi/auth.py b/pysnmp/hlapi/auth.py index a0ce8188f..ac01c6631 100644 --- a/pysnmp/hlapi/auth.py +++ b/pysnmp/hlapi/auth.py @@ -23,8 +23,8 @@ class CommunityData: """Creates SNMP v1/v2c configuration entry. This object can be used by - :py:class:`~pysnmp.hlapi.asyncore.AsyncCommandGenerator` or - :py:class:`~pysnmp.hlapi.asyncore.AsyncNotificationOriginator` + :py:class:`~pysnmp.hlapi.asyncio.AsyncCommandGenerator` or + :py:class:`~pysnmp.hlapi.asyncio.AsyncNotificationOriginator` and their derivatives for adding new entries to Local Configuration Datastore (LCD) managed by :py:class:`~pysnmp.hlapi.SnmpEngine` class instance. @@ -219,8 +219,8 @@ class UsmUserData: """Creates SNMP v3 User Security Model (USM) configuration entry. This object can be used by - :py:class:`~pysnmp.hlapi.asyncore.AsyncCommandGenerator` or - :py:class:`~pysnmp.hlapi.asyncore.AsyncNotificationOriginator` + :py:class:`~pysnmp.hlapi.asyncio.AsyncCommandGenerator` or + :py:class:`~pysnmp.hlapi.asyncio.AsyncNotificationOriginator` and their derivatives for adding new entries to Local Configuration Datastore (LCD) managed by :py:class:`~pysnmp.hlapi.SnmpEngine` class instance. diff --git a/pysnmp/hlapi/context.py b/pysnmp/hlapi/context.py index 615e28520..356773e58 100644 --- a/pysnmp/hlapi/context.py +++ b/pysnmp/hlapi/context.py @@ -13,8 +13,8 @@ class ContextData: """Creates UDP/IPv6 configuration entry and initialize socket API if needed. This object can be used by - :py:class:`~pysnmp.hlapi.asyncore.AsyncCommandGenerator` or - :py:class:`~pysnmp.hlapi.asyncore.AsyncNotificationOriginator` + :py:class:`~pysnmp.hlapi.asyncio.AsyncCommandGenerator` or + :py:class:`~pysnmp.hlapi.asyncio.AsyncNotificationOriginator` and their derevatives for forming SNMP PDU and also adding new entries to Local Configuration Datastore (LCD) in order to support SNMPv1/v2c with SNMPv3 interoperability. diff --git a/pysnmp/proto/secmod/rfc2576.py b/pysnmp/proto/secmod/rfc2576.py index a6297a13f..84ff44fc1 100644 --- a/pysnmp/proto/secmod/rfc2576.py +++ b/pysnmp/proto/secmod/rfc2576.py @@ -8,7 +8,7 @@ from pyasn1.codec.ber import encoder from pyasn1.error import PyAsn1Error from pysnmp.proto.secmod import base -from pysnmp.carrier.asyncore.dgram import udp, udp6, unix +from pysnmp.carrier.asyncio.dgram import udp, udp6, unix from pysnmp.smi.error import NoSuchInstanceError from pysnmp.proto import errind, error from pysnmp import debug diff --git a/runtests.sh b/runtests.sh index 0fe737cf8..f140ffb71 100755 --- a/runtests.sh +++ b/runtests.sh @@ -6,10 +6,10 @@ PYTHON=${1:-python} for x in examples/hlapi/asyncio/manager/cmdgen/*.py \ examples/hlapi/asyncio/agent/ntforg/*.py \ - examples/v3arch/asyncore/manager/cmdgen/*.py \ - examples/v3arch/asyncore/agent/ntforg/*.py \ - examples/v1arch/asyncore/manager/cmdgen/*.py \ - examples/v1arch/asyncore/agent/ntforg/*.py \ + examples/v3arch/asyncio/manager/cmdgen/*.py \ + examples/v3arch/asyncio/agent/ntforg/*.py \ + examples/v1arch/asyncio/manager/cmdgen/*.py \ + examples/v1arch/asyncio/agent/ntforg/*.py \ examples/smi/manager/*py \ examples/smi/agent/*.py do