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

Linux Bug #30

Closed
MeesMeijer opened this issue Apr 20, 2021 · 2 comments
Closed

Linux Bug #30

MeesMeijer opened this issue Apr 20, 2021 · 2 comments

Comments

@MeesMeijer
Copy link

Every time i use mcipc on ubuntu:

from mcipc.query import Client 

def test(ip, Qport):
    with Client(str(ip), int(Qport), timeout=1) as s:
        stat = s.stats(full=True)
        print(stat)

test("The Ip Address", "The Qport")

I get this error:

Traceback (most recent call last):
  File "/home/###/Desktop/server/client.py", line 9, in <module>
    test()
  File "/home/###/Desktop/server/client.py", line 4, in test
    with Client("###", ###, timeout=1) as s:
  File "/home/###/.local/lib/python3.9/site-packages/mcipc/query/client.py", line 59, in __enter__
    self.connect()
  File "/home/###/.local/lib/python3.9/site-packages/mcipc/query/client.py", line 51, in connect
    self.challenge_token = self.handshake()
  File "/home/###/.local/lib/python3.9/site-packages/mcipc/query/client.py", line 87, in handshake
    response = Response.read(file)
  File "/usr/local/lib/python3.9/typing.py", line 693, in __getattr__
    return getattr(self.__origin__, attr)
AttributeError: '_SpecialForm' object has no attribute 'read'

But this doesn't happend on windows 10 (pro).. Python instal is 3.9

@conqp
Copy link
Owner

conqp commented Apr 20, 2021

Thanks for the report.
This issue should™ have been solved with this commit: 9836169
Please give it a try.

@MeesMeijer
Copy link
Author

It works!

@conqp conqp pinned this issue Apr 21, 2021
@conqp conqp unpinned this issue Apr 22, 2021
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