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

fill new nodes after conn-error with empty dict, not tuple #19

Merged
merged 1 commit into from
Aug 14, 2023

Conversation

cortze
Copy link
Owner

@cortze cortze commented Aug 11, 2023

Motivation

There was an error when enabling the error rate on the lookup configuration:

study lookup_nn1000_sampl100000_fer0_ser5_fdr50-50_sdr500_k20_a3_b20_steps3 ready
network init done in 3.0734004974365234 secs
Traceback (most recent call last):                                                                                                                                                                                              ]   0%
  File "/home/cortze/devel/codex/das-research/DHT/dhtStudy.py", line 186, in <module>
    study(config)
  File "/home/cortze/devel/codex/das-research/DHT/dhtStudy.py", line 169, in study
    singleStudy.run()
  File "/home/cortze/devel/codex/das-research/DHT/dhtStudy.py", line 91, in run
    closest, _, summary, aggrDelay = builderNode.lookup_for_hash(sh)
  File "/home/cortze/devel/codex/das-research/py-dht/dht/dht.py", line 121, in lookup_for_hash
    if has_closer_nodes(closestnodes, mindelayedlookup[1]):
  File "/home/cortze/devel/codex/das-research/py-dht/dht/dht.py", line 55, in has_closer_nodes
    for n, dist in new.items():
AttributeError: 'tuple' object has no attribute 'items'

Related links:

Description

This PR fixes the error

Tasks

  • Fix error

Proof of Success

  • Test pass

@cortze cortze merged commit 22661b1 into main Aug 14, 2023
6 checks passed
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

Successfully merging this pull request may close these issues.

1 participant