omnara 0.2.3 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/omnara.js +5 -0
- package/dist/auth/auth-provider.d.ts +2 -0
- package/dist/auth/credential-manager.d.ts +5 -1
- package/dist/auth/credentials-store.d.ts +2 -1
- package/dist/auth/supabase-client.d.ts +1 -1
- package/dist/cli.js +5886 -6382
- package/dist/cli.js.map +4 -4
- package/dist/commands/index.d.ts +1 -0
- package/dist/commands/kill.d.ts +2 -0
- package/dist/daemon/daemon-launcher.d.ts +7 -0
- package/dist/daemon/paths.d.ts +7 -0
- package/dist/daemon/session-runner.d.ts +1 -1
- package/dist/env/env-mode.d.ts +2 -0
- package/dist/http/api-client.d.ts +0 -5
- package/dist/orchestrator/agent-orchestrator.d.ts +39 -44
- package/dist/orchestrator/ai-client.d.ts +7 -6
- package/dist/orchestrator/orchestrator-types.d.ts +3 -2
- package/dist/orchestrator/session.d.ts +59 -38
- package/dist/orchestrator/tools/worker-tools.d.ts +2 -0
- package/dist/orchestrator/utils/envelope-utils.d.ts +13 -0
- package/dist/orchestrator/utils/index.d.ts +1 -2
- package/dist/orchestrator/utils/worker-events.d.ts +7 -0
- package/dist/orchestrator/utils/worktree-manager.d.ts +21 -146
- package/dist/orchestrator/worker-manager.d.ts +44 -99
- package/dist/orchestrator/worker-types.d.ts +23 -0
- package/dist/relay/relay-bridge.d.ts +2 -10
- package/dist/utils/logger.d.ts +15 -0
- package/instrument.mjs +14 -0
- package/package.json +6 -2
- package/scripts/test-preinstall.js +0 -1
- package/dist/daemon/file-logger.d.ts +0 -24
- package/dist/daemon/session-log-manager.d.ts +0 -10
- package/dist/orchestrator/tools/worker-status-tool.d.ts +0 -7
- package/dist/orchestrator/utils/async-queue.d.ts +0 -26
package/bin/omnara.js
CHANGED
|
@@ -8,6 +8,7 @@ const __filename = fileURLToPath(import.meta.url);
|
|
|
8
8
|
const __dirname = path.dirname(__filename);
|
|
9
9
|
|
|
10
10
|
const distEntry = path.join(__dirname, '..', 'dist', 'cli.js');
|
|
11
|
+
const instrumentEntry = path.join(__dirname, '..', 'instrument.mjs');
|
|
11
12
|
|
|
12
13
|
if (!fs.existsSync(distEntry)) {
|
|
13
14
|
console.error(
|
|
@@ -17,5 +18,9 @@ if (!fs.existsSync(distEntry)) {
|
|
|
17
18
|
process.exit(1);
|
|
18
19
|
}
|
|
19
20
|
|
|
21
|
+
if (fs.existsSync(instrumentEntry)) {
|
|
22
|
+
await import(pathToFileURL(instrumentEntry).href);
|
|
23
|
+
}
|
|
24
|
+
|
|
20
25
|
const { run } = await import(pathToFileURL(distEntry).href);
|
|
21
26
|
await run(process.argv);
|
|
@@ -17,9 +17,11 @@ export declare class AuthProvider {
|
|
|
17
17
|
private cached;
|
|
18
18
|
private inflight;
|
|
19
19
|
private readonly backendUrl;
|
|
20
|
+
private lastBadCredentials;
|
|
20
21
|
constructor(options: AuthProviderOptions);
|
|
21
22
|
getAuthContext(options?: AuthAccessOptions): Promise<AuthContext>;
|
|
22
23
|
getAccessToken(options?: AuthAccessOptions): Promise<string>;
|
|
23
24
|
private loadAuthContext;
|
|
25
|
+
private performLogin;
|
|
24
26
|
}
|
|
25
27
|
export declare function createAuthProvider(options: AuthProviderOptions): Promise<AuthProvider>;
|
|
@@ -12,4 +12,8 @@ export interface AuthContext {
|
|
|
12
12
|
credentials: StoredCredentials;
|
|
13
13
|
accessToken: string;
|
|
14
14
|
}
|
|
15
|
-
export
|
|
15
|
+
export interface EnsureAuthContextOptions {
|
|
16
|
+
logger?: Console;
|
|
17
|
+
}
|
|
18
|
+
export declare function ensureAuthContext(store: CredentialsStore, backendUrl: string, initialCredentials?: StoredCredentials | null, options?: EnsureAuthContextOptions): Promise<AuthContext>;
|
|
19
|
+
export declare function isInvalidRefreshTokenError(error: unknown): boolean;
|
|
@@ -7,6 +7,7 @@ export declare const DEFAULT_DIR: string;
|
|
|
7
7
|
export declare const DEFAULT_CREDENTIALS_PATH: string;
|
|
8
8
|
export declare class CredentialsStore {
|
|
9
9
|
private readonly filePath;
|
|
10
|
+
private lockDepth;
|
|
10
11
|
constructor(filePath?: string);
|
|
11
12
|
load(): Promise<StoredCredentials | null>;
|
|
12
13
|
save(credentials: StoredCredentials): Promise<void>;
|
|
@@ -14,5 +15,5 @@ export declare class CredentialsStore {
|
|
|
14
15
|
withLock<T>(fn: () => Promise<T>): Promise<T>;
|
|
15
16
|
private lockPath;
|
|
16
17
|
private acquireLock;
|
|
17
|
-
private
|
|
18
|
+
private shouldBreakLock;
|
|
18
19
|
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { type SupabaseClient } from '@supabase/supabase-js';
|
|
2
2
|
import type { SupabaseAuthConfig } from './supabase-config.js';
|
|
3
|
-
export declare function
|
|
3
|
+
export declare function getSupabaseClient(config: SupabaseAuthConfig): SupabaseClient;
|