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

Exception when registering device #130

Closed
vico opened this issue Dec 10, 2021 · 3 comments
Closed

Exception when registering device #130

vico opened this issue Dec 10, 2021 · 3 comments

Comments

@vico
Copy link
Contributor

vico commented Dec 10, 2021

I got the following Exception when registering my Quaderno 2nd A4. The registration succeeds and I can add documents to my device. But the exception can be resolved by adding update_service to LookUpDPT as suggested.

Exception in thread zeroconf-ServiceBrowser-_dp_fujitsu._tcp-_digitalpaper._tcp-40518:
Traceback (most recent call last):
  File "/usr/lib/python3.9/threading.py", line 973, in _bootstrap_inner
    self.run()
  File "/home/cuong/.local/lib/python3.9/site-packages/zeroconf/_services/browser.py", line 538, in run
    self._fire_service_state_changed_event(event)
  File "/home/cuong/.local/lib/python3.9/site-packages/zeroconf/_services/browser.py", line 421, in _fire_service_state_changed_event
    self._service_state_changed.fire(
  File "/home/cuong/.local/lib/python3.9/site-packages/zeroconf/_services/__init__.py", line 55, in fire
    h(**kwargs)
  File "/home/cuong/.local/lib/python3.9/site-packages/zeroconf/_services/browser.py", line 178, in on_change
Found digital paper at 192.168.1.41
To skip the discovery process (and this message), call:
    getattr(listener, _ON_CHANGE_DISPATCH[state_change])(zeroconf, service_type, name)

AttributeError: 'LookUpDPT' object has no attribute 'update_service'
    /home/cuong/.local/bin/dptrp1 --addr 192.168.1.41 register

The following snippet will do the job unless there is a plan to add logic for update_service.

        def update_service(self, zeroconf, service_type, name):
              pass
@janten
Copy link
Owner

janten commented Dec 10, 2021

Could you prepare a PR for this?

@vico
Copy link
Contributor Author

vico commented Dec 10, 2021

Sure, here it is: #131

@janten
Copy link
Owner

janten commented Dec 10, 2021

Thank you!

@janten janten closed this as completed Dec 10, 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