-
Notifications
You must be signed in to change notification settings - Fork 2
Agent experience: env-var auth fallback, structured JSON errors, --agent rework #71
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
base: main
Are you sure you want to change the base?
Changes from 9 commits
0719743
fea4175
86e36c4
654c2c0
1e61f29
d14dd93
570d0e3
f9f2b53
a1c7d16
335b212
fa741e6
f3bba61
b02449c
f2f9619
4981255
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,5 @@ | ||
| import { Command } from '@cliffy/command'; | ||
| import { wantsJson } from '@/lib/context.ts'; | ||
| import { handleCommandError } from '@/lib/errors.ts'; | ||
| import { createAuthenticatedMuxClient } from '@/lib/mux.ts'; | ||
| import { confirmPrompt } from '@/lib/prompt.ts'; | ||
|
|
@@ -21,7 +22,7 @@ export const deleteCommand = new Command() | |
| // Confirm deletion unless --force flag is provided | ||
| if (!options.force) { | ||
| // For JSON mode, require explicit --force flag for safety | ||
| if (options.json) { | ||
| if (wantsJson(options)) { | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Agent errors still blame --jsonLow Severity Destructive command guards now key off Additional Locations (2)Reviewed by Cursor Bugbot for commit 4981255. Configure here. |
||
| throw new Error( | ||
| 'Deletion requires --force flag when using --json output', | ||
| ); | ||
|
|
@@ -41,7 +42,7 @@ export const deleteCommand = new Command() | |
| // Delete the asset | ||
| await mux.video.assets.delete(assetId); | ||
|
|
||
| if (options.json) { | ||
| if (wantsJson(options)) { | ||
| console.log(JSON.stringify({ success: true, assetId }, null, 2)); | ||
| } else { | ||
| console.log(`Asset ${assetId} deleted successfully`); | ||
|
|
||


Uh oh!
There was an error while loading. Please reload this page.