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

Not working on Python3.10 #70

Open
stamparm opened this issue Jan 20, 2021 · 3 comments
Open

Not working on Python3.10 #70

stamparm opened this issue Jan 20, 2021 · 3 comments

Comments

@stamparm
Copy link

Because of ignored problems with DeprecationWarning for PY_SSIZE_T_CLEAN (#67, #68), Pcapy doesn't work anymore on Python3.10 (Note: read https://docs.python.org/3.10/whatsnew/3.10.html#id2)

@stamparm
Copy link
Author

stamparm commented Jan 20, 2021

Minimalistic example which fails:

import pcapy

def recv(header, packet):
    sec, usec = header.getts()
    print(sec)

cap = pcapy.open_live("any", 65535, True, 100)
cap.loop(-1, recv)

1

@stamparm
Copy link
Author

https://pypi.org/project/pcapy-ng/ (tl;dr: just do the pip install pcapy-ng)

@segevfiner
Copy link
Contributor

You can also try https://github.com/segevfiner/cypcap which is a different project I wrote out of frustration with existing ones, and boredom 😛

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