@standardagents/code 0.14.1-issue.646.5eed10 → 0.14.1-issue.646.5eed10-darwin-arm64

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.

Potentially problematic release.


This version of @standardagents/code might be problematic. Click here for more details.

Files changed (33) hide show
  1. package/Standard Code Daemon.app/Contents/CodeResources +0 -0
  2. package/Standard Code Daemon.app/Contents/Helpers/tmux +0 -0
  3. package/Standard Code Daemon.app/Contents/Info.plist +42 -0
  4. package/Standard Code Daemon.app/Contents/MacOS/standardd +4 -0
  5. package/Standard Code Daemon.app/Contents/Resources/plugin-runner/THIRD-PARTY.txt +252 -0
  6. package/Standard Code Daemon.app/Contents/Resources/plugin-runner/index.mjs +1093 -0
  7. package/Standard Code Daemon.app/Contents/Resources/plugin-runner/loader.mjs +210817 -0
  8. package/Standard Code Daemon.app/Contents/Resources/plugin-runner/runtime.json +1 -0
  9. package/Standard Code Daemon.app/Contents/Resources/plugin-runner/sdk.mjs +634 -0
  10. package/Standard Code Daemon.app/Contents/Resources/plugin-runner/worker.mjs +1561 -0
  11. package/Standard Code Daemon.app/Contents/Resources/tmux/TMUX-ARTIFACT-MANIFEST.sha256 +6 -0
  12. package/Standard Code Daemon.app/Contents/Resources/tmux/TMUX-ARTIFACT-METADATA.txt +23 -0
  13. package/Standard Code Daemon.app/Contents/Resources/tmux/TMUX-BUILD-TOOLS.txt +11 -0
  14. package/Standard Code Daemon.app/Contents/Resources/tmux/TMUX-OTOOL-L.txt +4 -0
  15. package/Standard Code Daemon.app/Contents/Resources/tmux/TMUX-SIGNED-RUNTIME.sha256 +1 -0
  16. package/Standard Code Daemon.app/Contents/Resources/tmux/licenses/libevent.txt +99 -0
  17. package/Standard Code Daemon.app/Contents/Resources/tmux/licenses/tmux.txt +13 -0
  18. package/Standard Code Daemon.app/Contents/_CodeSignature/CodeResources +269 -0
  19. package/Standard Code.app/Contents/CodeResources +0 -0
  20. package/Standard Code.app/Contents/Info.plist +42 -0
  21. package/Standard Code.app/Contents/MacOS/standard +0 -0
  22. package/Standard Code.app/Contents/_CodeSignature/CodeResources +115 -0
  23. package/licenses/THIRD-PARTY.txt +119 -0
  24. package/manifest.json +1 -0
  25. package/manifest.sig +1 -0
  26. package/package.json +16 -31
  27. package/bin/standard.mjs +0 -4
  28. package/bin/standardd.mjs +0 -4
  29. package/lib/artifact.mjs +0 -326
  30. package/lib/backend-profile.mjs +0 -114
  31. package/lib/launcher.mjs +0 -75
  32. package/lib/platform.mjs +0 -50
  33. package/postinstall.mjs +0 -12
package/lib/launcher.mjs DELETED
@@ -1,75 +0,0 @@
1
- import { spawnSync } from 'node:child_process'
2
- import { readFileSync, realpathSync, statSync } from 'node:fs'
3
- import { createRequire } from 'node:module'
4
- import { dirname, join } from 'node:path'
5
- import process from 'node:process'
6
-
7
- import { platformPackage } from './platform.mjs'
8
- import { artifactBinaryPath, requireCompatibleGlibc, verifyNativeArtifact } from './artifact.mjs'
9
-
10
- const require = createRequire(import.meta.url)
11
- const COMMANDS = new Set(['standard', 'standardd'])
12
-
13
- export function resolveBinary(command, options = {}) {
14
- if (!COMMANDS.has(command)) {
15
- throw new Error(`Unknown Standard executable: ${command}`)
16
- }
17
- const environment = options.environment ?? process.env
18
- const overrideDirectory = environment.STANDARD_CODE_BINARY_DIR
19
- const binaryPath = overrideDirectory
20
- ? join(overrideDirectory, command)
21
- : resolvePackagedBinary(command, options)
22
- const stat = statSync(binaryPath)
23
- if (!stat.isFile()) {
24
- throw new Error(`Resolved Standard executable is not a file: ${binaryPath}`)
25
- }
26
- return binaryPath
27
- }
28
-
29
- function resolvePackagedBinary(command, options) {
30
- const platform = platformPackage(
31
- options.platform,
32
- options.architecture,
33
- options.report,
34
- )
35
- const resolve = options.resolve ?? require.resolve
36
- try {
37
- const root = dirname(realpathSync(resolve(`${platform.packageName}/manifest.json`)))
38
- const version = JSON.parse(readFileSync(new URL('../package.json', import.meta.url))).version
39
- const artifact = verifyNativeArtifact(root, { version, target: platform.rustTarget })
40
- const report = options.report ?? process.report
41
- requireCompatibleGlibc(artifact, report?.getReport()?.header?.glibcVersionRuntime)
42
- return join(root, artifactBinaryPath(artifact, command))
43
- } catch (error) {
44
- const detail = error instanceof Error ? error.message : String(error)
45
- throw new Error(
46
- `The native package ${platform.packageName} is missing or incomplete. `
47
- + `Reinstall @standardagents/code for this platform. (${detail})`,
48
- )
49
- }
50
- }
51
-
52
- export function spawnBinary(command, args, options = {}) {
53
- const binary = resolveBinary(command, options)
54
- return spawnSync(binary, args, {
55
- stdio: options.stdio ?? 'inherit',
56
- env: options.environment ?? process.env,
57
- })
58
- }
59
-
60
- export function main(command) {
61
- try {
62
- const result = spawnBinary(command, process.argv.slice(2))
63
- if (result.error) throw result.error
64
- if (result.signal) {
65
- console.error(`${command} terminated by ${result.signal}`)
66
- process.exitCode = 1
67
- return
68
- }
69
- process.exitCode = result.status ?? 1
70
- } catch (error) {
71
- const detail = error instanceof Error ? error.message : String(error)
72
- console.error(`${command}: ${detail}`)
73
- process.exitCode = 1
74
- }
75
- }
package/lib/platform.mjs DELETED
@@ -1,50 +0,0 @@
1
- const PLATFORMS = new Map([
2
- ['darwin:arm64', {
3
- packageName: '@standardagents/code-darwin-arm64',
4
- rustTarget: 'aarch64-apple-darwin',
5
- }],
6
- ['darwin:x64', {
7
- packageName: '@standardagents/code-darwin-x64',
8
- rustTarget: 'x86_64-apple-darwin',
9
- }],
10
- ['linux:arm64', {
11
- packageName: '@standardagents/code-linux-arm64-gnu',
12
- rustTarget: 'aarch64-unknown-linux-gnu',
13
- }],
14
- ['linux:x64', {
15
- packageName: '@standardagents/code-linux-x64-gnu',
16
- rustTarget: 'x86_64-unknown-linux-gnu',
17
- }],
18
- ])
19
-
20
- export function platformPackage(
21
- platform = process.platform,
22
- architecture = process.arch,
23
- report = process.report,
24
- ) {
25
- const entry = PLATFORMS.get(`${platform}:${architecture}`)
26
- if (!entry) {
27
- throw new Error(
28
- `Standard does not yet provide binaries for ${platform}/${architecture}; `
29
- + 'Phase 0 supports macOS and glibc Linux on arm64/x64.',
30
- )
31
- }
32
- if (platform === 'linux' && !isGlibc(report)) {
33
- throw new Error(
34
- 'Standard Phase 0 Linux packages require glibc; a musl build is not published yet.',
35
- )
36
- }
37
- return entry
38
- }
39
-
40
- export function supportedPlatforms() {
41
- return [...PLATFORMS.values()].map((entry) => ({ ...entry }))
42
- }
43
-
44
- function isGlibc(report) {
45
- try {
46
- return Boolean(report?.getReport()?.header?.glibcVersionRuntime)
47
- } catch {
48
- return false
49
- }
50
- }
package/postinstall.mjs DELETED
@@ -1,12 +0,0 @@
1
- import { chmodSync } from 'node:fs'
2
-
3
- import { resolveBinary } from './lib/launcher.mjs'
4
-
5
- for (const command of ['standard', 'standardd']) {
6
- try {
7
- chmodSync(resolveBinary(command), 0o755)
8
- } catch (error) {
9
- const detail = error instanceof Error ? error.message : String(error)
10
- console.warn(`@standardagents/code: ${detail}`)
11
- }
12
- }