PyFunceble: Fatal Error: got a response from ('192.168.21.1', 53) instead of ('192.168.1.1', 53)

Bug description

During a normal test with the current beta version from the AUR, multiple errors occurred with no modification on my part.

pyfunceble -w 12 --plain -a -f ‘/home/FILE.txt’

Modifications under .PyFunceble.yaml

I first entered my local DNS server to make testing faster, my DNS server is configured correctly. 192.168.1.1

Process pyfunceble_tester_worker_11:
Traceback (most recent call last):
  File "/usr/lib/python3.9/multiprocessing/process.py", line 315, in _bootstrap
    self.run()
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/workers/base.py", line 434, in run
    raise exception
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/workers/base.py", line 419, in run
    result = self.target(consumed)
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/workers/tester.py", line 275, in target
    self.testing_object.set_subject(test_dataset["idna_subject"])
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 135, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 160, in wrapper
    result = func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/domain_and_ip.py", line 107, in query_status
    return query_object.query_status()
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 135, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 160, in wrapper
    result = func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/domain.py", line 147, in query_status
    self.try_to_query_status_from_dns()
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/base.py", line 811, in try_to_query_status_from_dns
    lookup_result = self.query_dns_record()
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 135, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/base.py", line 700, in query_dns_record
    local_result = self.dns_query_tool.set_query_record_type(
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 954, in query
    return getattr(self, self.preferred_protocol.lower())()
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 221, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 251, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 233, in wrapper
    result = func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 775, in udp
    response = dns.query.udp(
  File "/home/user/.local/lib/python3.9/site-packages/dns/query.py", line 528, in udp
    (r, received_time) = receive_udp(s, destination, expiration,
  File "/home/user/.local/lib/python3.9/site-packages/dns/query.py", line 464, in receive_udp
    if _matches_destination(sock.family, from_address, destination,
  File "/home/user/.local/lib/python3.9/site-packages/dns/query.py", line 215, in _matches_destination
    raise UnexpectedSource(f'got a response from {from_address} instead of '
dns.query.UnexpectedSource: got a response from ('192.168.21.1', 53) instead of ('192.168.1.1', 53)
Process pyfunceble_tester_worker_4:
Traceback (most recent call last):
  File "/usr/lib/python3.9/multiprocessing/process.py", line 315, in _bootstrap
    self.run()
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/workers/base.py", line 434, in run
    raise exception
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/workers/base.py", line 419, in run
    result = self.target(consumed)
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/workers/tester.py", line 275, in target
    self.testing_object.set_subject(test_dataset["idna_subject"])
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 135, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 160, in wrapper
    result = func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/domain_and_ip.py", line 107, in query_status
    return query_object.query_status()
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 135, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 160, in wrapper
    result = func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/domain.py", line 147, in query_status
    self.try_to_query_status_from_dns()
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/base.py", line 811, in try_to_query_status_from_dns
    lookup_result = self.query_dns_record()
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 135, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/base.py", line 700, in query_dns_record
    local_result = self.dns_query_tool.set_query_record_type(
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 954, in query
    return getattr(self, self.preferred_protocol.lower())()
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 221, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 251, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 233, in wrapper
    result = func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 775, in udp
    response = dns.query.udp(
  File "/home/user/.local/lib/python3.9/site-packages/dns/query.py", line 528, in udp
    (r, received_time) = receive_udp(s, destination, expiration,
  File "/home/user/.local/lib/python3.9/site-packages/dns/query.py", line 464, in receive_udp
    if _matches_destination(sock.family, from_address, destination,
  File "/home/user/.local/lib/python3.9/site-packages/dns/query.py", line 215, in _matches_destination
    raise UnexpectedSource(f'got a response from {from_address} instead of '
dns.query.UnexpectedSource: got a response from ('192.168.21.1', 53) instead of ('192.168.1.1', 53)
Process pyfunceble_tester_worker_3:
Traceback (most recent call last):
  File "/usr/lib/python3.9/multiprocessing/process.py", line 315, in _bootstrap
    self.run()
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/workers/base.py", line 434, in run
    raise exception
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/workers/base.py", line 419, in run
    result = self.target(consumed)
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/workers/tester.py", line 275, in target
    self.testing_object.set_subject(test_dataset["idna_subject"])
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 135, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 160, in wrapper
    result = func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/domain_and_ip.py", line 107, in query_status
    return query_object.query_status()
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 135, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 160, in wrapper
    result = func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/domain.py", line 147, in query_status
    self.try_to_query_status_from_dns()
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/base.py", line 811, in try_to_query_status_from_dns
    lookup_result = self.query_dns_record()
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 135, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/base.py", line 700, in query_dns_record
    local_result = self.dns_query_tool.set_query_record_type(
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 954, in query
    return getattr(self, self.preferred_protocol.lower())()
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 221, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 251, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 233, in wrapper
    result = func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 775, in udp
    response = dns.query.udp(
  File "/home/user/.local/lib/python3.9/site-packages/dns/query.py", line 528, in udp
    (r, received_time) = receive_udp(s, destination, expiration,
  File "/home/user/.local/lib/python3.9/site-packages/dns/query.py", line 464, in receive_udp
    if _matches_destination(sock.family, from_address, destination,
  File "/home/user/.local/lib/python3.9/site-packages/dns/query.py", line 215, in _matches_destination
    raise UnexpectedSource(f'got a response from {from_address} instead of '
dns.query.UnexpectedSource: got a response from ('192.168.21.1', 53) instead of ('192.168.1.1', 53)
Fatal Error: got a response from ('192.168.21.1', 53) instead of ('192.168.1.1', 53)
Traceback (most recent call last):
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/system/launcher.py", line 866, in start
    self.stop_and_wait_for_all_manager()
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/system/launcher.py", line 804, in stop_and_wait_for_all_manager
    self.tester_process_manager.wait()
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/base.py", line 303, in wait
    raise worker_error
dns.query.UnexpectedSource: got a response from ('192.168.21.1', 53) instead of ('192.168.1.1', 53)

[user@work ~]$ 


About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 24 (22 by maintainers)

Commits related to this issue

Most upvoted comments

Hi folks,

My time is limited, so let me just talk about this issue. There is 3 way to handle this:

  1. Handle the issue and ignore it aka continuing to the next DNS server/record type.
  2. Leave it as it is.
  3. Accept unexpected.

About the third option: DNS python allows us to ignore that message and accept the provided answer. I’m not a big fan of it but I have to think of default behavior.

I’m more of a fan of the first solution. But I need more inputs before implementing anything.

cc @spirillen @mitchellkrogza @ZeroDot1; I need some input from you!

@ZeroDot1 I have for a long time been wondering what hardware you are testing on, I have never been able to get the results as fast as you… 1 min and 35 secs for 2000 records, is fast.

Yes it is a dub of #222 But what I’ve later noticed is it in my case was related to the worker -w n more than it seems directly related to the number of dns servers, So @ZeroDot1 could you post your full test string, then I’ll try to replicate it when I in a couple of weeks get my fiber through the wall, yes, the cable have been laying on the ground, right outside the wall for 5 month now…)

Similiar to https://github.com/funilrys/PyFunceble/issues/222, might be a duplicate (or not).

Gaming PCs are just an invention of the industry

Yep. But it also a “hint” of the current performance in the current marked.

I have been doing this since 1999.

Wondering if we are about the same age 🤔

By the way, the SSD can only work so fast because I built myself a cooler.

Nice…

But that cut… (I’m a old blacksmith 😃 )

Hi @spirillen, I quickly tested it with a different number of workers, always with the same result that the error mentioned above occurs. The problem occurs also with only one worker, I have tested it also extra with different files.

[user@work ~]$ pyfunceble -w 1 --plain -a -f '/Scan.txt'

██████╗ ██╗   ██╗███████╗██╗   ██╗███╗   ██╗ ██████╗███████╗██████╗ ██╗     ███████╗
██╔══██╗╚██╗ ██╔╝██╔════╝██║   ██║████╗  ██║██╔════╝██╔════╝██╔══██╗██║     ██╔════╝
██████╔╝ ╚████╔╝ █████╗  ██║   ██║██╔██╗ ██║██║     █████╗  ██████╔╝██║     █████╗
██╔═══╝   ╚██╔╝  ██╔══╝  ██║   ██║██║╚██╗██║██║     ██╔══╝  ██╔══██╗██║     ██╔══╝
██║        ██║   ██║     ╚██████╔╝██║ ╚████║╚██████╗███████╗██████╔╝███████╗███████╗
╚═╝        ╚═╝   ╚═╝      ╚═════╝ ╚═╝  ╚═══╝ ╚═════╝╚══════╝╚═════╝ ╚══════╝╚══════╝

You are using the Beta version of PyFunceble 4.0.0!
Please take the time to communicate with us when you notice
something unusual.




Subject                                                                                              Status      Source     Expiration Date   HTTP Code  Checker      
---------------------------------------------------------------------------------------------------- ----------- ---------- ----------------- ---------- -------------
0769.it                                                                                              ACTIVE      WHOIS      20-jun-2021       Unknown    AVAILABILITY 
Process pyfunceble_tester_worker_1:
Traceback (most recent call last):
  File "/usr/lib/python3.9/multiprocessing/process.py", line 315, in _bootstrap
    self.run()
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/workers/base.py", line 434, in run
    raise exception
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/workers/base.py", line 419, in run
    result = self.target(consumed)
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/workers/tester.py", line 275, in target
    self.testing_object.set_subject(test_dataset["idna_subject"])
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 135, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 160, in wrapper
    result = func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/domain_and_ip.py", line 107, in query_status
    return query_object.query_status()
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 135, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 160, in wrapper
    result = func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/domain.py", line 147, in query_status
    self.try_to_query_status_from_dns()
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/base.py", line 811, in try_to_query_status_from_dns
    lookup_result = self.query_dns_record()
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/base.py", line 135, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/checker/availability/base.py", line 700, in query_dns_record
    local_result = self.dns_query_tool.set_query_record_type(
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 954, in query
    return getattr(self, self.preferred_protocol.lower())()
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 221, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 251, in wrapper
    return func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 233, in wrapper
    result = func(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/PyFunceble/query/dns/query_tool.py", line 775, in udp
    response = dns.query.udp(
  File "/home/user/.local/lib/python3.9/site-packages/dns/query.py", line 528, in udp
    (r, received_time) = receive_udp(s, destination, expiration,
  File "/home/user/.local/lib/python3.9/site-packages/dns/query.py", line 464, in receive_udp
    if _matches_destination(sock.family, from_address, destination,
  File "/home/user/.local/lib/python3.9/site-packages/dns/query.py", line 215, in _matches_destination
    raise UnexpectedSource(f'got a response from {from_address} instead of '
dns.query.UnexpectedSource: got a response from ('192.168.21.1', 53) instead of ('192.168.1.1', 53)
Fatal Error: got a response from ('192.168.21.1', 53) instead of ('192.168.1.1', 53)
Traceback (most recent call last):
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/system/launcher.py", line 866, in start
    self.stop_and_wait_for_all_manager()
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/system/launcher.py", line 804, in stop_and_wait_for_all_manager
    self.tester_process_manager.wait()
  File "/usr/lib/python3.9/site-packages/PyFunceble/cli/processes/base.py", line 303, in wait
    raise worker_error
dns.query.UnexpectedSource: got a response from ('192.168.21.1', 53) instead of ('192.168.1.1', 53)

[user@work ~]$ 


@ZeroDot1, the problem with the third solution is that if you get someone in the middle, it may change the outcome.

The first option on the other hand refuses to read the data from the response because it is not “safe”. Provoking the system to skip and move on.

I agree that the second one is not an “option”, but it’s still something to keep in mind 😃

My acceptable choices would be

The first option, it need to be fixed, this said, I would accept the third option as a hotfix, second option is out of the question…

@spirillen I understand. Maybe some internet providers should take us open source developers as an example, we usually provide support within a few hours. In my location there is no fiber and no LTE only old rotting telephone cables older than me. I know how you feel with your bad connection. I wish you that your internet provider manages to connect your lines within the next few days and that you can work well again quickly.