Learn more about these different git repos.
Other Git URLs
No commits found
Move the copy-and-pasted list of errnos into an ERRNOS variable and use that in both places.
ERRNOS
Rename the e2 variable to something easier to understand.
e2
This makes this code easier to read.
To test this out:
Apply this patch to your client
Run "koji watch-task" on a ongoing task ID, for example: koji watch-task 123456
koji watch-task 123456
Block outgoing connections to your Koji hub's IP, for example: firewall-cmd --direct --add-rule ipv4 filter OUTPUT 0 -d 10.0.0.100/32 -j REJECT
firewall-cmd --direct --add-rule ipv4 filter OUTPUT 0 -d 10.0.0.100/32 -j REJECT
Wait a while for koji watch-task to fail, like so: 2022-01-04 16:23:33,650 [ERROR] koji: ConnectionError: HTTPSConnectionPool(host='koji.example.com', port=443): Max retries exceeded with url: /kojihub (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7fe6a616ec10>: Failed to establish a new connection: [Errno 111] Connection refused'))
koji watch-task
2022-01-04 16:23:33,650 [ERROR] koji: ConnectionError: HTTPSConnectionPool(host='koji.example.com', port=443): Max retries exceeded with url: /kojihub (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7fe6a616ec10>: Failed to establish a new connection: [Errno 111] Connection refused'))
To remove the firewalld rule from your local client after you're done testing: firewall-cmd --direct --remove-rule ipv4 filter OUTPUT 0 -d 10.0.0.100/32 -j REJECT
firewall-cmd --direct --remove-rule ipv4 filter OUTPUT 0 -d 10.0.0.100/32 -j REJECT
:thumbsup:
Metadata Update from @tkopecek: - Pull-request tagged with: testing-ready
Metadata Update from @tkopecek: - Pull-request untagged with: testing-ready - Pull-request tagged with: no_qe
Commit 213c1ea fixes this pull-request
Pull-Request has been merged by tkopecek
Move the copy-and-pasted list of errnos into an
ERRNOS
variable and use that in both places.Rename the
e2
variable to something easier to understand.This makes this code easier to read.