altimate-code 0.4.7 → 0.4.9
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/CHANGELOG.md +20 -0
- package/bin/altimate +46 -3
- package/bin/altimate-code +46 -3
- package/package.json +16 -13
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,26 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [0.4.9] - 2026-03-18
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
|
|
12
|
+
- Script to build and run compiled binary locally (#262)
|
|
13
|
+
|
|
14
|
+
### Fixed
|
|
15
|
+
|
|
16
|
+
- Snowflake auth — support all auth methods (`password`, `keypair`, `externalbrowser`, `oauth`), fix field name mismatches (#268)
|
|
17
|
+
- dbt tool regression — schema format mismatch, silent failures, wrong results (#263)
|
|
18
|
+
- `altimate-dbt compile`, `execute`, and children commands fail with runtime errors (#255)
|
|
19
|
+
- `Cannot find module @altimateai/altimate-core` on `npm install` (#259)
|
|
20
|
+
- Dispatcher tests fail in CI due to shared module state (#257)
|
|
21
|
+
|
|
22
|
+
### Changed
|
|
23
|
+
|
|
24
|
+
- CI: parallel per-target builds — 12 jobs, ~5 min wall clock instead of ~20 min (#254)
|
|
25
|
+
- CI: faster release — build parallel with test, lower compression, tighter timeouts (#251)
|
|
26
|
+
- Docker E2E tests skip in CI unless explicitly opted in (#253)
|
|
27
|
+
|
|
8
28
|
## [0.4.1] - 2026-03-16
|
|
9
29
|
## [0.4.2] - 2026-03-18
|
|
10
30
|
|
package/bin/altimate
CHANGED
|
@@ -5,9 +5,55 @@ const fs = require("fs")
|
|
|
5
5
|
const path = require("path")
|
|
6
6
|
const os = require("os")
|
|
7
7
|
|
|
8
|
+
// Resolve script location early — needed by both run() and findBinary().
|
|
9
|
+
const scriptPath = fs.realpathSync(__filename)
|
|
10
|
+
const scriptDir = path.dirname(scriptPath)
|
|
11
|
+
|
|
12
|
+
// Collect ALL node_modules directories walking upward from startDir.
|
|
13
|
+
// Bun's single-file executable uses a virtual filesystem (/$bunfs/root/) without
|
|
14
|
+
// node_modules. External packages are resolved via NODE_PATH instead.
|
|
15
|
+
// We collect every node_modules in the hierarchy (not just the first) to handle
|
|
16
|
+
// pnpm strict layouts, hoisted monorepos, and npm flat installs alike.
|
|
17
|
+
function findAllNodeModules(startDir) {
|
|
18
|
+
const paths = []
|
|
19
|
+
let current = startDir
|
|
20
|
+
for (;;) {
|
|
21
|
+
const modules = path.join(current, "node_modules")
|
|
22
|
+
if (fs.existsSync(modules)) paths.push(modules)
|
|
23
|
+
const parent = path.dirname(current)
|
|
24
|
+
if (parent === current) break
|
|
25
|
+
current = parent
|
|
26
|
+
}
|
|
27
|
+
return paths
|
|
28
|
+
}
|
|
29
|
+
|
|
8
30
|
function run(target) {
|
|
31
|
+
// Resolve NODE_PATH so the compiled Bun binary can find external packages
|
|
32
|
+
// installed alongside the wrapper (e.g. @altimateai/altimate-core NAPI module).
|
|
33
|
+
// Search from BOTH the binary's location AND the wrapper script's location
|
|
34
|
+
// to cover npm flat installs, pnpm isolated stores, and hoisted monorepos.
|
|
35
|
+
const env = { ...process.env }
|
|
36
|
+
try {
|
|
37
|
+
const resolvedTarget = fs.realpathSync(target)
|
|
38
|
+
const targetDir = path.dirname(path.dirname(resolvedTarget))
|
|
39
|
+
|
|
40
|
+
const targetModules = findAllNodeModules(targetDir)
|
|
41
|
+
const scriptModules = findAllNodeModules(scriptDir)
|
|
42
|
+
const allPaths = [...new Set([...scriptModules, ...targetModules])]
|
|
43
|
+
|
|
44
|
+
if (allPaths.length > 0) {
|
|
45
|
+
const sep = process.platform === "win32" ? ";" : ":"
|
|
46
|
+
const joined = allPaths.join(sep)
|
|
47
|
+
env.NODE_PATH = env.NODE_PATH ? joined + sep + env.NODE_PATH : joined
|
|
48
|
+
}
|
|
49
|
+
} catch {
|
|
50
|
+
// realpathSync failed (e.g. target doesn't exist) — continue without
|
|
51
|
+
// NODE_PATH; spawnSync will report the missing binary via result.error.
|
|
52
|
+
}
|
|
53
|
+
|
|
9
54
|
const result = childProcess.spawnSync(target, process.argv.slice(2), {
|
|
10
55
|
stdio: "inherit",
|
|
56
|
+
env,
|
|
11
57
|
})
|
|
12
58
|
if (result.error) {
|
|
13
59
|
console.error(result.error.message)
|
|
@@ -22,9 +68,6 @@ if (envPath) {
|
|
|
22
68
|
run(envPath)
|
|
23
69
|
}
|
|
24
70
|
|
|
25
|
-
const scriptPath = fs.realpathSync(__filename)
|
|
26
|
-
const scriptDir = path.dirname(scriptPath)
|
|
27
|
-
|
|
28
71
|
//
|
|
29
72
|
const cached = path.join(scriptDir, ".altimate-code")
|
|
30
73
|
if (fs.existsSync(cached)) {
|
package/bin/altimate-code
CHANGED
|
@@ -5,9 +5,55 @@ const fs = require("fs")
|
|
|
5
5
|
const path = require("path")
|
|
6
6
|
const os = require("os")
|
|
7
7
|
|
|
8
|
+
// Resolve script location early — needed by both run() and findBinary().
|
|
9
|
+
const scriptPath = fs.realpathSync(__filename)
|
|
10
|
+
const scriptDir = path.dirname(scriptPath)
|
|
11
|
+
|
|
12
|
+
// Collect ALL node_modules directories walking upward from startDir.
|
|
13
|
+
// Bun's single-file executable uses a virtual filesystem (/$bunfs/root/) without
|
|
14
|
+
// node_modules. External packages are resolved via NODE_PATH instead.
|
|
15
|
+
// We collect every node_modules in the hierarchy (not just the first) to handle
|
|
16
|
+
// pnpm strict layouts, hoisted monorepos, and npm flat installs alike.
|
|
17
|
+
function findAllNodeModules(startDir) {
|
|
18
|
+
const paths = []
|
|
19
|
+
let current = startDir
|
|
20
|
+
for (;;) {
|
|
21
|
+
const modules = path.join(current, "node_modules")
|
|
22
|
+
if (fs.existsSync(modules)) paths.push(modules)
|
|
23
|
+
const parent = path.dirname(current)
|
|
24
|
+
if (parent === current) break
|
|
25
|
+
current = parent
|
|
26
|
+
}
|
|
27
|
+
return paths
|
|
28
|
+
}
|
|
29
|
+
|
|
8
30
|
function run(target) {
|
|
31
|
+
// Resolve NODE_PATH so the compiled Bun binary can find external packages
|
|
32
|
+
// installed alongside the wrapper (e.g. @altimateai/altimate-core NAPI module).
|
|
33
|
+
// Search from BOTH the binary's location AND the wrapper script's location
|
|
34
|
+
// to cover npm flat installs, pnpm isolated stores, and hoisted monorepos.
|
|
35
|
+
const env = { ...process.env }
|
|
36
|
+
try {
|
|
37
|
+
const resolvedTarget = fs.realpathSync(target)
|
|
38
|
+
const targetDir = path.dirname(path.dirname(resolvedTarget))
|
|
39
|
+
|
|
40
|
+
const targetModules = findAllNodeModules(targetDir)
|
|
41
|
+
const scriptModules = findAllNodeModules(scriptDir)
|
|
42
|
+
const allPaths = [...new Set([...scriptModules, ...targetModules])]
|
|
43
|
+
|
|
44
|
+
if (allPaths.length > 0) {
|
|
45
|
+
const sep = process.platform === "win32" ? ";" : ":"
|
|
46
|
+
const joined = allPaths.join(sep)
|
|
47
|
+
env.NODE_PATH = env.NODE_PATH ? joined + sep + env.NODE_PATH : joined
|
|
48
|
+
}
|
|
49
|
+
} catch {
|
|
50
|
+
// realpathSync failed (e.g. target doesn't exist) — continue without
|
|
51
|
+
// NODE_PATH; spawnSync will report the missing binary via result.error.
|
|
52
|
+
}
|
|
53
|
+
|
|
9
54
|
const result = childProcess.spawnSync(target, process.argv.slice(2), {
|
|
10
55
|
stdio: "inherit",
|
|
56
|
+
env,
|
|
11
57
|
})
|
|
12
58
|
if (result.error) {
|
|
13
59
|
console.error(result.error.message)
|
|
@@ -22,9 +68,6 @@ if (envPath) {
|
|
|
22
68
|
run(envPath)
|
|
23
69
|
}
|
|
24
70
|
|
|
25
|
-
const scriptPath = fs.realpathSync(__filename)
|
|
26
|
-
const scriptDir = path.dirname(scriptPath)
|
|
27
|
-
|
|
28
71
|
//
|
|
29
72
|
const cached = path.join(scriptDir, ".altimate-code")
|
|
30
73
|
if (fs.existsSync(cached)) {
|
package/package.json
CHANGED
|
@@ -14,20 +14,23 @@
|
|
|
14
14
|
"scripts": {
|
|
15
15
|
"postinstall": "bun ./postinstall.mjs || node ./postinstall.mjs"
|
|
16
16
|
},
|
|
17
|
-
"version": "v0.4.
|
|
17
|
+
"version": "v0.4.9",
|
|
18
18
|
"license": "MIT",
|
|
19
|
+
"dependencies": {
|
|
20
|
+
"@altimateai/altimate-core": "^0.2.3"
|
|
21
|
+
},
|
|
19
22
|
"optionalDependencies": {
|
|
20
|
-
"@altimateai/altimate-code-linux-x64": "v0.4.
|
|
21
|
-
"@altimateai/altimate-code-windows-arm64": "v0.4.
|
|
22
|
-
"@altimateai/altimate-code-linux-arm64-musl": "v0.4.
|
|
23
|
-
"@altimateai/altimate-code-darwin-x64": "v0.4.
|
|
24
|
-
"@altimateai/altimate-code-windows-x64": "v0.4.
|
|
25
|
-
"@altimateai/altimate-code-linux-x64-musl": "v0.4.
|
|
26
|
-
"@altimateai/altimate-code-darwin-x64-baseline": "v0.4.
|
|
27
|
-
"@altimateai/altimate-code-linux-x64-baseline-musl": "v0.4.
|
|
28
|
-
"@altimateai/altimate-code-linux-x64-baseline": "v0.4.
|
|
29
|
-
"@altimateai/altimate-code-linux-arm64": "v0.4.
|
|
30
|
-
"@altimateai/altimate-code-darwin-arm64": "v0.4.
|
|
31
|
-
"@altimateai/altimate-code-windows-x64-baseline": "v0.4.
|
|
23
|
+
"@altimateai/altimate-code-linux-x64": "v0.4.9",
|
|
24
|
+
"@altimateai/altimate-code-windows-arm64": "v0.4.9",
|
|
25
|
+
"@altimateai/altimate-code-linux-arm64-musl": "v0.4.9",
|
|
26
|
+
"@altimateai/altimate-code-darwin-x64": "v0.4.9",
|
|
27
|
+
"@altimateai/altimate-code-windows-x64": "v0.4.9",
|
|
28
|
+
"@altimateai/altimate-code-linux-x64-musl": "v0.4.9",
|
|
29
|
+
"@altimateai/altimate-code-darwin-x64-baseline": "v0.4.9",
|
|
30
|
+
"@altimateai/altimate-code-linux-x64-baseline-musl": "v0.4.9",
|
|
31
|
+
"@altimateai/altimate-code-linux-x64-baseline": "v0.4.9",
|
|
32
|
+
"@altimateai/altimate-code-linux-arm64": "v0.4.9",
|
|
33
|
+
"@altimateai/altimate-code-darwin-arm64": "v0.4.9",
|
|
34
|
+
"@altimateai/altimate-code-windows-x64-baseline": "v0.4.9"
|
|
32
35
|
}
|
|
33
36
|
}
|