10000 Sourcery refactored master branch by sourcery-ai[bot] · Pull Request #34 · kgaughan/uwhoisd · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Sourcery refactored master branch #34

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

Merged
merged 1 commit into from
Nov 21, 2022
Merged

Sourcery refactored master branch #34

merged 1 commit into from
Nov 21, 2022

Conversation

sourcery-ai[bot]
Copy link
Contributor
@sourcery-ai sourcery-ai bot commented Nov 18, 2022

Branch master refactored by Sourcery.

If you're happy with these changes, merge this Pull Request using the Squash and merge strategy.

See our documentation here.

Run Sourcery locally

Reduce the feedback loop during development by using the Sourcery editor plugin:

Review changes via command line

To manually merge these changes, make sure you're on the master branch, then run:

git fetch origin sourcery/master
git merge --ff-only FETCH_HEAD
git reset HEAD^

Help us improve this pull request!

@sourcery-ai sourcery-ai bot requested a review from kgaughan November 18, 2022 14:39
server = zone + "." + self.suffix
server = f"{zone}.{self.suffix}"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function UWhois.get_whois_server refactored with the following changes:

if query.endswith("." + zone):
if query.endswith(f".{zone}"):
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function UWhois.whois refactored with the following changes:

data = self.sock.recv(2048)
if data:
if data := self.sock.recv(2048):
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function WhoisClient.whois refactored with the following changes:

Comment on lines -100 to +104
if not utils.is_well_formed_fqdn(whois_query):
whois_entry = "; Bad request: '{0}'\r\n".format(whois_query)
else:
whois_entry = self.whois(whois_query)
whois_entry = (
self.whois(whois_query)
if utils.is_well_formed_fqdn(whois_query)
else "; Bad request: '{0}'\r\n".format(whois_query)
)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function WhoisListener.handle_stream refactored with the following changes:

whois_server = "whois.nic.%s" % zone
whois_server = f"whois.nic.{zone}"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function scrape_whois_from_iana refactored with the following changes:

Comment on lines -145 to +150
print("%s=%s" % (zone, whois_servers[zone]))
print(f"{zone}={whois_servers[zone]}")

if args.ipv4:
print("[ipv4_assignments]")
for prefix, whois_server in fetch_ipv4_assignments(IPV4_ASSIGNMENTS):
print("%s=%s" % (prefix, whois_server))
print(f"{prefix}={whois_server}")
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function main refactored with the following changes:

return dict(
(key, decode_value(value)) for key, value in self.items(section)
)
return {key: decode_value(value) for key, value in self.items(section)}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function ConfigParser.get_section_dict refactored with the following changes:

8436

@kgaughan kgaughan merged commit 03f131b into master Nov 21, 2022
@kgaughan kgaughan deleted the sourcery/master branch August 18, 2024 21:16
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
0