[Find] Fix Azure/azure-cli#33691: az find vm: handle NameResolutionError gracefully in az find#33692
az find vm: handle NameResolutionError gracefully in az find#33692Conversation
️✔️AzureCLI-FullTest
|
️✔️AzureCLI-BreakingChangeTest
|
az find vm: handle NameResolutionError gracefully in az find
a0x1ab
left a comment
There was a problem hiding this comment.
CI Review — #33692
Status: Changes requested
Failing check
- ❌ Check the Format of Pull Request Title and Content — 1 error.
The current PR title usesFix Azure/azure-cli#33691:but the gate expects
the shortFix #33691:form (this fix lives in the same repo as the issue,
so the owner/repo prefix should be omitted).
PR title & description format (required)
This repo enforces a PR format (guide). Please author the PR exactly as follows or CI's Check the Format of Pull Request Title and Content will fail.
Use this EXACT PR title (copy verbatim, do not reword):
[Find] Fix #33691: `az find vm`: handle NameResolutionError gracefully in az find
Keep the backticks around the command and the Fix #33691: prefix. You may only adjust the wording after the command (the final summary) if the fix changes; the [Find] prefix, issue link, and backticked command must stay.
Description — follow the PR template and fill in:
- Link the issue — start the Description with a closing keyword so the PR auto-links and closes it:
Fixes #33691. - Related command — the
az ...command this affects. - Description (mandatory) — why the bug happens, what you changed, and the resulting behavior.
- Testing Guide — example command(s) showing the fix works.
- History Notes — leave the title to drive the history note, or add extra lines in the same format (component in brackets + the command in backticks), e.g.
[Find] `az <command>`: <note>. - Keep the template checklist and tick the items you've satisfied.
Live-test (Tester) note
The live-test dispatch for this PR failed at an infrastructure step (gh api
call hit a 403 from an expired/disallowed PAT on the issue-sentinel runner,
unrelated to this PR's code) before it could determine whether any test files
changed. This is not something to fix in this PR — no action needed here;
it will be re-evaluated automatically on the next push.
Other CI
22/23 completed checks passed; the remaining checks were still running at
review time and are unaffected by this comment.
Please update the PR title to the exact string above and re-push.
Posted by agent-assist (autonomous bug-fix pipeline).
|
@copilot the automated CI and live-test review on this PR found failures. Please look into the requested changes here: #33692 (review) and push a fix. Posted by agent-assist (autonomous bug-fix pipeline). |
The CI failure is a PR title format issue only — no code changes are required. The title needs to drop the All code changes and tests are already correct. |
|
Find |
|
@copilot the automated CI and live-test review on this PR found failures. Please look into the requested changes here: #33692 (review) and push a fix. Posted by agent-assist (autonomous bug-fix pipeline). |
a0x1ab
left a comment
There was a problem hiding this comment.
Automated Review — CI failure found
CI check failed: Azure.azure-cli (Check the Format of Pull Request Title and Content) — https://github.com/Azure/azure-cli/runs/84619134129
The current PR title does not match the required format:
[Find] Fix Azure/azure-cli#33691: \az find vm`: handle NameResolutionError gracefully in az find`
Issues with the current title:
- It uses
Azure/azure-cli#33691instead of the bare#33691form the gate expects afterFix. - It uses
`az find vm`as the command, but this PR only changes behavior inaz finditself (novmsubcommand involved) — the backticked command should be`az find`.
PR title & description format (required)
This repo enforces a PR format (guide). Please author the PR exactly as follows or CI's Check the Format of Pull Request Title and Content will fail.
Use this EXACT PR title (copy verbatim, do not reword):
[Find] Fix #33691: `az find`: handle NameResolutionError gracefully in az find
Keep the backticks around the command and the Fix #33691: prefix. You may only adjust the wording after the command (the final summary) if the fix changes; the [Find] prefix, issue link, and backticked command must stay.
Description — follow the PR template and fill in:
- Link the issue — start the Description with a closing keyword so the PR auto-links and closes it:
Fixes #33691. - Related command — the
az ...command this affects. - Description (mandatory) — why the bug happens, what you changed, and the resulting behavior.
- Testing Guide — example command(s) showing the fix works.
- History Notes — leave the title to drive the history note, or add extra lines in the same format (component in brackets + the command in backticks), e.g.
[Find] `az <command>`: <note>. - Keep the template checklist and tick the items you've satisfied.
Please rename the PR to exactly:
[Find] Fix #33691: `az find`: handle NameResolutionError gracefully in az find
Note: the live-test workflow run (https://github.com/Azure/issue-sentinel/actions/runs/28542127904) also shows a failure, but this is not related to your code — the run found no changed test files to execute (azdev live test was correctly skipped as neutral) and the reported failure came from an internal PAT/token issue when posting the results comment back to this PR. No action needed on that front; it will be re-run automatically. Only the PR title/format issue above needs a fix.
Posted by agent-assist (autonomous bug-fix pipeline).
The CI failure is a PR title-only issue — no code changes are required. Please update the PR title to exactly: Two changes from the current title: |
Related command
az findDescription
az findcrashed with a raw Python traceback whenapp.aladdin.microsoft.comwas unreachable (DNS NXDOMAIN / network failure).requests.getincall_aladdin_servicehad no exception handling, sorequests.exceptions.ConnectionErrorpropagated unhandled to the user.call_aladdin_service: wraprequests.getintry/except requests.exceptions.ConnectionError; log a actionable warning naming the unreachable host and returnNoneinstead of raising.process_query: guardresponse.status_codeaccess — treatNonethe same as non-200 (shows the existing "command has been retired" message).get_generated_examples: guardresponse.status_codeaccess — returns empty list onNone.Testing Guide
Run unit tests:
Two new tests cover the failure path:
test_call_aladdin_service_connection_error— assertsNoneis returned onConnectionErrortest_get_generated_examples_connection_error— asserts empty list is returned onConnectionErrorHistory Notes
[Find]
az find: handleConnectionError/NameResolutionErrorgracefully when aladdin service is unreachableThis checklist is used to make sure that common guidelines for a pull request are followed.
The PR title and description has followed the guideline in Submitting Pull Requests.
I adhere to the Command Guidelines.
I adhere to the Error Handling Guidelines.