Generate Downtimes commands for pup - #829
dd-octo-sts[bot] wants to merge 1 commit into
Conversation
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
The new cancel command ignores the selected output format. The two list commands also mark partial pages as complete.
🤖 Datadog Autotest · Commit 9187732 · What is Autotest? · @DataDog review to ask questions · Any feedback? Reach out in #autotest
| api.cancel_downtime(downtime_id) | ||
| .await | ||
| .map_err(|e| anyhow::anyhow!("failed to cancel_downtime: {:?}", e))?; | ||
| println!("downtimes cancel: ok"); |
There was a problem hiding this comment.
Use the shared formatter for cancel output
Agents and scripts cannot parse a successful cancel result.
Assertion details
- Input: Run
pup --agent downtimes cancel <valid-id>or request JSON output. - Expected:
The command must use the selected output format and the agent JSON envelope. - Actual: The command prints
downtimes cancel: okas plain text.
Was this helpful? React 👍 or 👎
🤖 Datadog Autotest · What is Autotest? · @DataDog review to ask questions · Any feedback? Reach out in #autotest · Open Bits AI session
| .await | ||
| .map_err(|e| anyhow::anyhow!("failed to list_downtimes: {:?}", e))?; | ||
| let count = resp.data.as_ref().map_or(0, |d| d.len()); | ||
| let truncated = false; |
There was a problem hiding this comment.
Agents can stop after the first page and omit valid downtimes.
Assertion details
- Input: The API returns fewer records than
total_filtered_count, such as 30 of 31. - Expected:
The metadata must mark the page as partial and give the next offset. - Actual: Both list functions set
truncatedto false and omit the next action.
Was this helpful? React 👍 or 👎
🤖 Datadog Autotest · What is Autotest? · @DataDog review to ask questions · Any feedback? Reach out in #autotest · Open Bits AI session
|
You can ignore this for now this is a WIP |
9187732 to
2d556f9
Compare
2d556f9 to
9f3b48a
Compare
PLEASE, DO NOT MERGE THIS PULL REQUEST MANUALLY. This is automatically managed by Datadog Tooling
See DataDog/datadog-api-spec#6744 Test branch datadog-api-spec/test/ulysse.mavrocordatos/AAWF-1386/pup-downtimes-pilot