Skip to content

Commit 41bdc69

Browse files
committed
Merge origin/main into codex/2198-runner-demand
Main moved the command descriptor registry into @agent-device/command-registry (#2348) and split src/daemon/types.ts (#2346): the planned-operations module and its test follow the registry into the package (exported as ./planned-operations), the executionPlan carrier moves to daemon-request.ts, and the batch step context lands on the new BatchInvoke signature.
2 parents b36d2ce + bd08e6e commit 41bdc69

673 files changed

Lines changed: 3388 additions & 2247 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.fallowrc.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,7 @@
256256
},
257257
{
258258
"comment": "Type-level `AssertTrue<...>` registry-totality guards. Exported only so `noUnusedLocals` keeps them alive; a consumer would defeat the point.",
259-
"file": "{src/core/command-descriptor/registry.ts,src/core/interactors/register-builtins.ts,src/core/platform-descriptor/registry.ts,src/daemon/request-platform-providers.ts}",
259+
"file": "{packages/command-registry/src/registry.ts,src/core/interactors/register-builtins.ts,src/core/platform-descriptor/registry.ts,src/daemon/request-platform-providers.ts}",
260260
"exports": [
261261
"CommandOwnerFileClaimsAreComplete",
262262
"BuiltinPluginsCoverAllPlatforms",

.github/actions/setup-fixture-app/action.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,10 @@ runs:
172172
run: |
173173
set -euo pipefail
174174
pnpm --dir examples/test-app exec expo prebuild --platform android --no-install
175-
echo "org.gradle.jvmargs=-Xmx4g" >> examples/test-app/android/gradle.properties
175+
# expo prebuild's generated gradle.properties has no trailing newline, so a bare
176+
# `echo >>` corrupts its last line (e.g. `expo.inlineModules.watchedDirectories=[]org.gradle.jvmargs=...`),
177+
# which fails Gradle's JSON.parse of that property at configure time. Lead with a newline.
178+
printf '\n%s\n' 'org.gradle.jvmargs=-Xmx4g' >> examples/test-app/android/gradle.properties
176179
(
177180
cd examples/test-app/android
178181
./gradlew :app:assembleRelease

.github/workflows/test-app-build-cache.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,10 @@ jobs:
188188
run: |
189189
set -euo pipefail
190190
pnpm --dir examples/test-app exec expo prebuild --platform android --no-install
191-
echo "org.gradle.jvmargs=-Xmx4g" >> examples/test-app/android/gradle.properties
191+
# expo prebuild's generated gradle.properties has no trailing newline, so a bare
192+
# `echo >>` corrupts its last line (e.g. `expo.inlineModules.watchedDirectories=[]org.gradle.jvmargs=...`),
193+
# which fails Gradle's JSON.parse of that property at configure time. Lead with a newline.
194+
printf '\n%s\n' 'org.gradle.jvmargs=-Xmx4g' >> examples/test-app/android/gradle.properties
192195
(
193196
cd examples/test-app/android
194197
./gradlew :app:assembleRelease

AGENTS.md

Lines changed: 3 additions & 3 deletions

CHANGELOG.md

Lines changed: 7 additions & 0 deletions

examples/sdk/tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,5 @@
2121
// prior build, workspace link, or publish step. Running an example for real
2222
// still resolves `agent-device` as a self-referencing package (needs
2323
// `pnpm build`), matching how a real consumer would import it.
24-
"include": [".", "../../src/global.d.ts"]
24+
"include": [".", "../../packages/command-registry/src/global.d.ts"]
2525
}

examples/test-app/app.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ module.exports = {
2020
buildCacheProvider: { plugin: 'expo-build-disk-cache' },
2121
plugins: [
2222
'expo-router',
23+
'expo-secure-store',
2324
[
2425
'expo-audio',
2526
{

examples/test-app/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
"expo-linking": "56.0.14",
2121
"expo-modules-core": "56.0.17",
2222
"expo-router": "~56.2.11",
23+
"expo-secure-store": "~56.0.4",
2324
"expo-status-bar": "~56.0.4",
2425
"react": "19.2.3",
2526
"react-dom": "19.2.3",

examples/test-app/pnpm-lock.yaml

Lines changed: 12 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/test-app/src/screens/AutomationLabScreen.tsx

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,17 @@ import {
1414
} from 'react-native';
1515
import { getRecordingPermissionsAsync, requestRecordingPermissionsAsync } from 'expo-audio';
1616
import { requireOptionalNativeModule } from 'expo-modules-core';
17+
import * as SecureStore from 'expo-secure-store';
1718

1819
import { ActionButton, ScreenTitle, SectionCard } from '../components';
1920
import { useAppColors, type AppColors } from '../theme';
2021

22+
// A fixed key/value pair standing in for a real login token: this screen only
23+
// needs to prove keychain-backed state survives `clear-app-state` but not
24+
// `reset-keychain`, not to model an actual auth flow.
25+
const KEYCHAIN_AUTH_KEY = 'automation-keychain-auth-token';
26+
const KEYCHAIN_AUTH_VALUE = 'demo-auth-token';
27+
2128
type PushBroadcastLabModule = {
2229
lastPushBroadcast(): string;
2330
};
@@ -45,6 +52,7 @@ export function AutomationLabScreen(props: {
4552
const [microphonePermission, setMicrophonePermission] = useState('checking');
4653
const [lastPushBroadcast, setLastPushBroadcast] = useState('none');
4754
const [sheetVisible, setSheetVisible] = useState(false);
55+
const [keychainAuthStatus, setKeychainAuthStatus] = useState('checking');
4856
const permissionReadGeneration = useRef(0);
4957
const windowMode = dimensions.width > dimensions.height ? 'landscape' : 'portrait';
5058

@@ -125,6 +133,26 @@ export function AutomationLabScreen(props: {
125133
setLastPushBroadcast(pushBroadcastLab?.lastPushBroadcast() ?? 'unavailable');
126134
}
127135

136+
useEffect(() => {
137+
let mounted = true;
138+
void SecureStore.getItemAsync(KEYCHAIN_AUTH_KEY)
139+
.then((value) => {
140+
if (mounted)
141+
setKeychainAuthStatus(value === KEYCHAIN_AUTH_VALUE ? 'signed-in' : 'signed-out');
142+
})
143+
.catch(() => {
144+
if (mounted) setKeychainAuthStatus('error');
145+
});
146+
return () => {
147+
mounted = false;
148+
};
149+
}, []);
150+
151+
async function signInWithKeychain() {
152+
await SecureStore.setItemAsync(KEYCHAIN_AUTH_KEY, KEYCHAIN_AUTH_VALUE);
153+
setKeychainAuthStatus('signed-in');
154+
}
155+
128156
return (
129157
<ScrollView contentContainerStyle={styles.content} showsVerticalScrollIndicator={false}>
130158
<ScreenTitle
@@ -235,6 +263,19 @@ export function AutomationLabScreen(props: {
235263
/>
236264
</SectionCard>
237265

266+
<SectionCard title="Keychain-backed auth">
267+
<ActionButton
268+
label="Sign in (write keychain)"
269+
onPress={() => void signInWithKeychain()}
270+
testID="automation-keychain-signin"
271+
/>
272+
<StateRow
273+
label="Auth status"
274+
testID="automation-keychain-status"
275+
value={keychainAuthStatus}
276+
/>
277+
</SectionCard>
278+
238279
<SectionCard title="Android push broadcast">
239280
<ActionButton
240281
kind="secondary"

0 commit comments

Comments
 (0)