mirror of
https://github.com/tiennm99/ccs.git
synced 2026-07-16 12:15:57 +00:00
fix(agy): align responsibility flow with issue #509
- replace issue #622/#619 references with issue #509 across CLI and dashboard - shorten acknowledgement phrase to "I ACCEPT AGY RISK" for faster typing - rename acknowledgement payload field to reviewedIssue509 and update tests
This commit is contained in:
@@ -242,7 +242,7 @@ export function warnOAuthBanRisk(provider: CLIProxyProvider): void {
|
||||
);
|
||||
if (isAgy) {
|
||||
console.error(
|
||||
' Antigravity-specific warning (#622): OAuth usage can still trigger suspension/ban patterns.'
|
||||
' Antigravity-specific warning: OAuth usage can still trigger suspension/ban patterns.'
|
||||
);
|
||||
}
|
||||
console.error(
|
||||
@@ -255,9 +255,6 @@ export function warnOAuthBanRisk(provider: CLIProxyProvider): void {
|
||||
' CCS is provided as-is and cannot take responsibility for suspension/ban/access-loss decisions.'
|
||||
);
|
||||
console.error(` Details: ${ISSUE_509_URL}`);
|
||||
if (isAgy) {
|
||||
console.error(' Antigravity details: https://github.com/kaitranntt/ccs/issues/622');
|
||||
}
|
||||
console.error('');
|
||||
}
|
||||
|
||||
|
||||
@@ -12,17 +12,16 @@ import { createInterface, Interface } from 'readline';
|
||||
import { fail, info, ok, warn } from '../utils/ui';
|
||||
import { getCliproxySafetyConfig } from '../config/unified-config-loader';
|
||||
|
||||
export const ANTIGRAVITY_RISK_ISSUE_URL = 'https://github.com/kaitranntt/ccs/issues/622';
|
||||
export const ANTIGRAVITY_PROJECT_ID_ISSUE_URL = 'https://github.com/kaitranntt/ccs/issues/619';
|
||||
export const ANTIGRAVITY_ACK_VERSION = '2026-02-24-antigravity-oauth-v1';
|
||||
export const ANTIGRAVITY_ACK_PHRASE = 'I ACCEPT FULL RESPONSIBILITY';
|
||||
export const ANTIGRAVITY_RISK_ISSUE_URL = 'https://github.com/kaitranntt/ccs/issues/509';
|
||||
export const ANTIGRAVITY_ACK_VERSION = '2026-02-24-antigravity-oauth-v2';
|
||||
export const ANTIGRAVITY_ACK_PHRASE = 'I ACCEPT AGY RISK';
|
||||
export const ANTIGRAVITY_ACCEPT_RISK_FLAGS = ['--accept-agr-risk', '--accept-antigravity-risk'];
|
||||
|
||||
type AgyRiskContext = 'oauth' | 'run';
|
||||
|
||||
export interface AntigravityRiskAcknowledgement {
|
||||
version: string;
|
||||
reviewedIssue622: boolean;
|
||||
reviewedIssue509: boolean;
|
||||
understandsBanRisk: boolean;
|
||||
acceptsFullResponsibility: boolean;
|
||||
typedPhrase: string;
|
||||
@@ -126,7 +125,6 @@ function printResponsibilityHeader(context: AgyRiskContext): void {
|
||||
console.error(` ${contextLine}`);
|
||||
console.error(' Antigravity has active ban/suspension patterns for risky OAuth usage.');
|
||||
console.error(` Policy issue: ${ANTIGRAVITY_RISK_ISSUE_URL}`);
|
||||
console.error(` Related account reliability issue: ${ANTIGRAVITY_PROJECT_ID_ISSUE_URL}`);
|
||||
console.error('');
|
||||
}
|
||||
|
||||
@@ -151,7 +149,7 @@ export function validateAntigravityRiskAcknowledgement(payload: unknown): Valida
|
||||
};
|
||||
}
|
||||
|
||||
if (!data.reviewedIssue622 || !data.understandsBanRisk || !data.acceptsFullResponsibility) {
|
||||
if (!data.reviewedIssue509 || !data.understandsBanRisk || !data.acceptsFullResponsibility) {
|
||||
return {
|
||||
valid: false,
|
||||
error: 'Complete all Antigravity responsibility checklist steps before authenticating.',
|
||||
@@ -196,7 +194,7 @@ export async function ensureCliAntigravityResponsibility(
|
||||
const step1 = await askYesNoStep(
|
||||
rl,
|
||||
'Step 1/4',
|
||||
'I reviewed issue #622 and understand Antigravity OAuth can trigger bans/suspensions.'
|
||||
'I reviewed issue #509 and understand AGY OAuth can trigger bans/suspensions.'
|
||||
);
|
||||
if (!step1) return false;
|
||||
|
||||
|
||||
@@ -167,7 +167,7 @@ Run ${color('ccs config', 'command')} for web dashboard`.trim();
|
||||
'First run: Browser opens for authentication, then model selection',
|
||||
'Settings: ~/.ccs/{provider}.settings.json (created after auth)',
|
||||
'Safety: do not reuse one Google account across "ccs gemini" and "ccs agy" (issue #509)',
|
||||
'Antigravity requires multi-step responsibility confirmation (issue #622)',
|
||||
'Antigravity requires multi-step responsibility confirmation (issue #509)',
|
||||
'If you want to keep Google AI access, do not continue this shared-account setup',
|
||||
'CCS is as-is and does not take responsibility for account bans/access loss',
|
||||
],
|
||||
|
||||
@@ -42,7 +42,7 @@ describe('antigravity-responsibility', () => {
|
||||
it('accepts a complete acknowledgement payload', () => {
|
||||
const result = validateAntigravityRiskAcknowledgement({
|
||||
version: ANTIGRAVITY_ACK_VERSION,
|
||||
reviewedIssue622: true,
|
||||
reviewedIssue509: true,
|
||||
understandsBanRisk: true,
|
||||
acceptsFullResponsibility: true,
|
||||
typedPhrase: ANTIGRAVITY_ACK_PHRASE,
|
||||
@@ -54,10 +54,10 @@ describe('antigravity-responsibility', () => {
|
||||
it('accepts phrase with extra spacing and lowercase', () => {
|
||||
const result = validateAntigravityRiskAcknowledgement({
|
||||
version: ANTIGRAVITY_ACK_VERSION,
|
||||
reviewedIssue622: true,
|
||||
reviewedIssue509: true,
|
||||
understandsBanRisk: true,
|
||||
acceptsFullResponsibility: true,
|
||||
typedPhrase: ' i accept full responsibility ',
|
||||
typedPhrase: ' i accept agy risk ',
|
||||
});
|
||||
|
||||
expect(result.valid).toBeTrue();
|
||||
@@ -66,7 +66,7 @@ describe('antigravity-responsibility', () => {
|
||||
it('rejects payload when checklist steps are not fully completed', () => {
|
||||
const result = validateAntigravityRiskAcknowledgement({
|
||||
version: ANTIGRAVITY_ACK_VERSION,
|
||||
reviewedIssue622: true,
|
||||
reviewedIssue509: true,
|
||||
understandsBanRisk: false,
|
||||
acceptsFullResponsibility: true,
|
||||
typedPhrase: ANTIGRAVITY_ACK_PHRASE,
|
||||
@@ -79,7 +79,7 @@ describe('antigravity-responsibility', () => {
|
||||
it('rejects payload when version is outdated', () => {
|
||||
const result = validateAntigravityRiskAcknowledgement({
|
||||
version: 'older-version',
|
||||
reviewedIssue622: true,
|
||||
reviewedIssue509: true,
|
||||
understandsBanRisk: true,
|
||||
acceptsFullResponsibility: true,
|
||||
typedPhrase: ANTIGRAVITY_ACK_PHRASE,
|
||||
@@ -92,7 +92,7 @@ describe('antigravity-responsibility', () => {
|
||||
it('rejects payload when phrase does not match', () => {
|
||||
const result = validateAntigravityRiskAcknowledgement({
|
||||
version: ANTIGRAVITY_ACK_VERSION,
|
||||
reviewedIssue622: true,
|
||||
reviewedIssue509: true,
|
||||
understandsBanRisk: true,
|
||||
acceptsFullResponsibility: true,
|
||||
typedPhrase: 'I AGREE',
|
||||
|
||||
@@ -25,7 +25,7 @@ export function AccountSafetyWarningCard({
|
||||
|
||||
const title = isAgy ? 'Antigravity OAuth Risk' : 'Account Safety Warning';
|
||||
const subtitle = isAgy
|
||||
? 'Issue #622 · Third-party OAuth ban risk'
|
||||
? 'Issue #509 · Third-party OAuth ban risk'
|
||||
: 'Issue #509 · Shared Gemini + AGY account risk';
|
||||
const firstLine = isAgy ? (
|
||||
<>
|
||||
@@ -43,10 +43,8 @@ export function AccountSafetyWarningCard({
|
||||
) : (
|
||||
<>If you want to keep Google AI access, do not continue this shared-account setup.</>
|
||||
);
|
||||
const issueUrl = isAgy
|
||||
? 'https://github.com/kaitranntt/ccs/issues/622'
|
||||
: 'https://github.com/kaitranntt/ccs/issues/509';
|
||||
const issueLabel = isAgy ? 'Read issue #622' : 'Read issue #509';
|
||||
const issueUrl = 'https://github.com/kaitranntt/ccs/issues/509';
|
||||
const issueLabel = 'Read issue #509';
|
||||
|
||||
return (
|
||||
<section
|
||||
|
||||
@@ -22,7 +22,7 @@ export function AntigravityResponsibilityChecklist({
|
||||
disabled = false,
|
||||
}: AntigravityResponsibilityChecklistProps) {
|
||||
const completedSteps = [
|
||||
value.reviewedIssue622,
|
||||
value.reviewedIssue509,
|
||||
value.understandsBanRisk,
|
||||
value.acceptsFullResponsibility,
|
||||
value.typedPhrase.trim().replace(/\s+/g, ' ').toUpperCase() === ANTIGRAVITY_ACK_PHRASE,
|
||||
@@ -73,12 +73,12 @@ export function AntigravityResponsibilityChecklist({
|
||||
<div className="flex items-start gap-2">
|
||||
<Checkbox
|
||||
id="agy-step-reviewed-issue"
|
||||
checked={value.reviewedIssue622}
|
||||
onCheckedChange={(checked) => setValue({ reviewedIssue622: Boolean(checked) })}
|
||||
checked={value.reviewedIssue509}
|
||||
onCheckedChange={(checked) => setValue({ reviewedIssue509: Boolean(checked) })}
|
||||
disabled={disabled}
|
||||
/>
|
||||
<Label htmlFor="agy-step-reviewed-issue" className="text-xs leading-5">
|
||||
Step 1: I reviewed issue #622 and understand Antigravity OAuth can trigger account
|
||||
Step 1: I reviewed issue #509 and understand AGY OAuth can trigger account
|
||||
bans/suspensions.
|
||||
</Label>
|
||||
</div>
|
||||
@@ -128,21 +128,12 @@ export function AntigravityResponsibilityChecklist({
|
||||
|
||||
<div className="flex flex-wrap items-center gap-2 text-xs">
|
||||
<a
|
||||
href="https://github.com/kaitranntt/ccs/issues/622"
|
||||
href="https://github.com/kaitranntt/ccs/issues/509"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
className="inline-flex items-center gap-1.5 rounded-md border border-rose-500/30 bg-rose-500/10 px-2.5 py-1 font-medium text-rose-800 transition-colors hover:bg-rose-500/15 dark:text-rose-200"
|
||||
>
|
||||
Read issue #622
|
||||
<ExternalLink className="h-3.5 w-3.5" />
|
||||
</a>
|
||||
<a
|
||||
href="https://github.com/kaitranntt/ccs/issues/619"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
className="inline-flex items-center gap-1.5 rounded-md border border-amber-500/30 bg-amber-500/10 px-2.5 py-1 font-medium text-amber-800 transition-colors hover:bg-amber-500/15 dark:text-amber-200"
|
||||
>
|
||||
Related issue #619
|
||||
Read issue #509
|
||||
<ExternalLink className="h-3.5 w-3.5" />
|
||||
</a>
|
||||
</div>
|
||||
|
||||
@@ -1,15 +1,15 @@
|
||||
export const ANTIGRAVITY_ACK_VERSION = '2026-02-24-antigravity-oauth-v1';
|
||||
export const ANTIGRAVITY_ACK_PHRASE = 'I ACCEPT FULL RESPONSIBILITY';
|
||||
export const ANTIGRAVITY_ACK_VERSION = '2026-02-24-antigravity-oauth-v2';
|
||||
export const ANTIGRAVITY_ACK_PHRASE = 'I ACCEPT AGY RISK';
|
||||
|
||||
export interface AntigravityRiskChecklistValue {
|
||||
reviewedIssue622: boolean;
|
||||
reviewedIssue509: boolean;
|
||||
understandsBanRisk: boolean;
|
||||
acceptsFullResponsibility: boolean;
|
||||
typedPhrase: string;
|
||||
}
|
||||
|
||||
export const DEFAULT_ANTIGRAVITY_RISK_CHECKLIST: AntigravityRiskChecklistValue = {
|
||||
reviewedIssue622: false,
|
||||
reviewedIssue509: false,
|
||||
understandsBanRisk: false,
|
||||
acceptsFullResponsibility: false,
|
||||
typedPhrase: '',
|
||||
@@ -17,7 +17,7 @@ export const DEFAULT_ANTIGRAVITY_RISK_CHECKLIST: AntigravityRiskChecklistValue =
|
||||
|
||||
export function isAntigravityRiskChecklistComplete(value: AntigravityRiskChecklistValue): boolean {
|
||||
return (
|
||||
value.reviewedIssue622 &&
|
||||
value.reviewedIssue509 &&
|
||||
value.understandsBanRisk &&
|
||||
value.acceptsFullResponsibility &&
|
||||
value.typedPhrase.trim().replace(/\s+/g, ' ').toUpperCase() === ANTIGRAVITY_ACK_PHRASE
|
||||
|
||||
Reference in New Issue
Block a user