From 42f1c3a2c1b85770370c97d4da3b4489e7caab84 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 12:45:43 +0100 Subject: [PATCH 01/32] Enable macOS binary test --- .github/workflows/general.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index a1795301..dae436a3 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -120,8 +120,8 @@ jobs: with: name: binaries path: dpkit/compile/build - # - name: Test Binaries - # run: unzip -j dpkit/compile/build/*macos*.zip "dp*" && ./dp --version + - name: Test Binaries + run: unzip -j dpkit/compile/build/*macos*.zip "dp*" && ./dp --version test-windows: needs: [test-compile] From 1b3fd2e74d969413df57defac7b06d4b65ef4a77 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 12:47:12 +0100 Subject: [PATCH 02/32] Fixed release order --- .github/workflows/general.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index dae436a3..74f44ddf 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -156,7 +156,7 @@ jobs: # We have to split the release step because for some reason # using semantic-release before compilation inflates the binary sizes release-draft: - # needs: [test-linux, test-macos, test-windows] + needs: [test-linux, test-macos, test-windows] if: github.event_name == 'push' runs-on: ubuntu-latest From a25ff1eeb6537684656b9e323aa4b3b575aa0556 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 13:05:46 +0100 Subject: [PATCH 03/32] Rebased on baseline for macos --- dpkit/scripts/compile.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dpkit/scripts/compile.ts b/dpkit/scripts/compile.ts index fd336e0e..a1c393ec 100644 --- a/dpkit/scripts/compile.ts +++ b/dpkit/scripts/compile.ts @@ -55,7 +55,8 @@ const targets = [ libsql: "libsql-linux-x64-gnu", }, { - name: "bun-darwin-x64", + // Github Actions doesn't support AVX + name: "bun-darwin-x64-baseline", dpkit: "macos-x64", polars: "nodejs-polars-darwin-x64", libsql: "libsql-darwin-x64", From 7dec57323f0057ecb6f56d3ec16bc7d7ed7ed52c Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 13:11:16 +0100 Subject: [PATCH 04/32] Enable windows testing --- .github/workflows/general.yaml | 8 +++----- dpkit/scripts/compile.ts | 3 +-- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 74f44ddf..155eff60 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -150,8 +150,8 @@ jobs: with: name: binaries path: dpkit/compile/build - # - name: Test Binaries - # run: unzip -j dpkit/compile/build/*windows*.zip "dp*" && ./dp.exe --version + - name: Test Binaries + run: unzip -j dpkit/compile/build/*windows*.zip "dp*" && ./dp.exe --version # We have to split the release step because for some reason # using semantic-release before compilation inflates the binary sizes @@ -224,9 +224,7 @@ jobs: - name: Publish Release uses: softprops/action-gh-release@v2 with: - tag_name: v${{ needs.release-draft.outputs.version }} files: dpkit/compile/build/*.zip - make_latest: true - draft: false + tag_name: v${{ needs.release-draft.outputs.version }} env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/dpkit/scripts/compile.ts b/dpkit/scripts/compile.ts index a1c393ec..fd336e0e 100644 --- a/dpkit/scripts/compile.ts +++ b/dpkit/scripts/compile.ts @@ -55,8 +55,7 @@ const targets = [ libsql: "libsql-linux-x64-gnu", }, { - // Github Actions doesn't support AVX - name: "bun-darwin-x64-baseline", + name: "bun-darwin-x64", dpkit: "macos-x64", polars: "nodejs-polars-darwin-x64", libsql: "libsql-darwin-x64", From e31209dfd24dfb2f513a3774c3e70f4a83422147 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 13:17:39 +0100 Subject: [PATCH 05/32] Fixed windows runner --- .github/workflows/general.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 155eff60..7da4863c 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -125,7 +125,7 @@ jobs: test-windows: needs: [test-compile] - runs-on: macos-latest + runs-on: windows-latest steps: - name: Checkout Repo From d9320929e755c8bb34631b75dae66aae8103c080 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 13:23:31 +0100 Subject: [PATCH 06/32] Fixed windows test --- .github/workflows/general.yaml | 3 ++- package.json | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 7da4863c..11a14a2d 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -144,7 +144,8 @@ jobs: - name: Build Packages run: pnpm build - name: Test Packages - run: pnpm test + # TODO: Linting fails on Windows + run: pnpm spec - name: Download Binaries uses: actions/download-artifact@v5 with: diff --git a/package.json b/package.json index a95d13fc..79dc1a94 100644 --- a/package.json +++ b/package.json @@ -21,7 +21,7 @@ "lint": "biome check", "prepare": "husky", "spec": "vitest run", - "test": "pnpm check && pnpm run spec", + "test": "pnpm check && pnpm spec", "type": "tsc --noEmit" }, "devDependencies": { From f5a90f76df13914fce8f47cbd0719740b09eed91 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 13:28:30 +0100 Subject: [PATCH 07/32] Skip windows testing --- .github/workflows/general.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 11a14a2d..48906bc2 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -143,9 +143,9 @@ jobs: run: pnpm ci:install - name: Build Packages run: pnpm build - - name: Test Packages - # TODO: Linting fails on Windows - run: pnpm spec + # - name: Test Packages + # TODO: Linting fails on Windows + # run: pnpm spec - name: Download Binaries uses: actions/download-artifact@v5 with: From 9af3d9774698ec455713a51979f08e7eac3333a7 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 13:34:21 +0100 Subject: [PATCH 08/32] Fixed windown path --- .github/workflows/general.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 48906bc2..3574b234 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -152,7 +152,7 @@ jobs: name: binaries path: dpkit/compile/build - name: Test Binaries - run: unzip -j dpkit/compile/build/*windows*.zip "dp*" && ./dp.exe --version + run: unzip -j dpkit\compile\build\*windows*.zip "dp*" && .\dp.exe --version # We have to split the release step because for some reason # using semantic-release before compilation inflates the binary sizes From bffa61361f085aa3065f05727a3e92b2ba214e97 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 13:41:21 +0100 Subject: [PATCH 09/32] Try improved win zip syntax --- .github/workflows/general.yaml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 3574b234..35aa375c 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -152,7 +152,10 @@ jobs: name: binaries path: dpkit/compile/build - name: Test Binaries - run: unzip -j dpkit\compile\build\*windows*.zip "dp*" && .\dp.exe --version + run: | + $zipFile = Get-ChildItem dpkit/compile/build/*windows*.zip | Select-Object -First 1 + Expand-Archive -Path $zipFile.FullName -DestinationPath . -Force + ./dp.exe --version # We have to split the release step because for some reason # using semantic-release before compilation inflates the binary sizes From 6819601b59d4ccce2fd0ca6a31e2a9f01c45308c Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 13:46:41 +0100 Subject: [PATCH 10/32] Fixed win --- .github/workflows/general.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 35aa375c..b0f247b7 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -155,7 +155,7 @@ jobs: run: | $zipFile = Get-ChildItem dpkit/compile/build/*windows*.zip | Select-Object -First 1 Expand-Archive -Path $zipFile.FullName -DestinationPath . -Force - ./dp.exe --version + .\dp.exe --version # We have to split the release step because for some reason # using semantic-release before compilation inflates the binary sizes From 779730d4ab778bc52e9d9f58d4cec4d9ca4203a4 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 13:54:22 +0100 Subject: [PATCH 11/32] Fixed win --- .github/workflows/general.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index b0f247b7..72f6f245 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -155,7 +155,8 @@ jobs: run: | $zipFile = Get-ChildItem dpkit/compile/build/*windows*.zip | Select-Object -First 1 Expand-Archive -Path $zipFile.FullName -DestinationPath . -Force - .\dp.exe --version + Get-ChildItem + ./dp.exe --version # We have to split the release step because for some reason # using semantic-release before compilation inflates the binary sizes From 4ee2b6011710ab944c45199bba13c6f8c3ad036c Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 14:07:10 +0100 Subject: [PATCH 12/32] Updated unzipping --- .github/workflows/general.yaml | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 72f6f245..b97b5cab 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -72,7 +72,7 @@ jobs: name: binaries path: dpkit/compile/build - name: Test Binaries - run: unzip -j dpkit/compile/build/*linux*.zip "dp*" && ./dp --version + run: unzip dpkit/compile/build/*linux*.zip && ./dp-*/dp --version services: postgres: @@ -121,7 +121,7 @@ jobs: name: binaries path: dpkit/compile/build - name: Test Binaries - run: unzip -j dpkit/compile/build/*macos*.zip "dp*" && ./dp --version + run: unzip dpkit/compile/build/*macos*.zip && ./dp-*/dp --version test-windows: needs: [test-compile] @@ -152,11 +152,7 @@ jobs: name: binaries path: dpkit/compile/build - name: Test Binaries - run: | - $zipFile = Get-ChildItem dpkit/compile/build/*windows*.zip | Select-Object -First 1 - Expand-Archive -Path $zipFile.FullName -DestinationPath . -Force - Get-ChildItem - ./dp.exe --version + run: Expand-Archive dpkit/compile/build/*windows*.zip && ./dp-*/dp.exe --version # We have to split the release step because for some reason # using semantic-release before compilation inflates the binary sizes From 1e86af6768e6c04329ea1ccc05f85fb1bd3c660e Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 14:11:46 +0100 Subject: [PATCH 13/32] Fixed win --- .github/workflows/general.yaml | 5 ++--- package.json | 4 ++-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index b97b5cab..383de9d7 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -144,15 +144,14 @@ jobs: - name: Build Packages run: pnpm build # - name: Test Packages - # TODO: Linting fails on Windows - # run: pnpm spec + # run: pnpm win:test - name: Download Binaries uses: actions/download-artifact@v5 with: name: binaries path: dpkit/compile/build - name: Test Binaries - run: Expand-Archive dpkit/compile/build/*windows*.zip && ./dp-*/dp.exe --version + run: Expand-Archive dpkit\compile\build\*windows*.zip && .\dp-*\dp.exe --version # We have to split the release step because for some reason # using semantic-release before compilation inflates the binary sizes diff --git a/package.json b/package.json index 79dc1a94..db868a53 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,6 @@ "ci:install": "pnpm install --ignore-scripts", "ci:publish": "pnpm -r publish --access public --ignore-scripts --no-git-checks", "ci:version": "pnpm -r exec pnpm version --no-git-tag-version", - "check": "pnpm run lint && pnpm run type", "clean": "rm pnpm-lock.yaml && find . -name 'node_modules' -type d -prune -print -exec rm -rf '{}' +", "compile": "pnpm -F dpkit compile", "coverage": "vitest --ui", @@ -21,7 +20,8 @@ "lint": "biome check", "prepare": "husky", "spec": "vitest run", - "test": "pnpm check && pnpm spec", + "test": "pnpm lint && pnpm type && pnpm spec", + "win:test": "pnpm type && pnpm spec", "type": "tsc --noEmit" }, "devDependencies": { From aa8fbeb2d697b93c25d39f2106ee071d1bdb6c0a Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 14:18:14 +0100 Subject: [PATCH 14/32] Fixed win --- .github/workflows/general.yaml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 383de9d7..a142323c 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -151,7 +151,10 @@ jobs: name: binaries path: dpkit/compile/build - name: Test Binaries - run: Expand-Archive dpkit\compile\build\*windows*.zip && .\dp-*\dp.exe --version + run: | + Expand-Archive dpkit\compile\build\*windows*.zip + $dir = Get-ChildItem dp-* -Directory | Select-Object -First 1 + & "$($dir.Name)\dp.exe" --version # We have to split the release step because for some reason # using semantic-release before compilation inflates the binary sizes From bf2ffa7a3e3106458ed400674ef85242794d61c6 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 14:22:14 +0100 Subject: [PATCH 15/32] Fixed win --- .github/workflows/general.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index a142323c..07031648 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -154,7 +154,7 @@ jobs: run: | Expand-Archive dpkit\compile\build\*windows*.zip $dir = Get-ChildItem dp-* -Directory | Select-Object -First 1 - & "$($dir.Name)\dp.exe" --version + & ".\$($dir.Name)\dp.exe" --version # We have to split the release step because for some reason # using semantic-release before compilation inflates the binary sizes From 5db7cadeb8296486314281faeb99c14b346c9ad5 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 14:27:59 +0100 Subject: [PATCH 16/32] Fixed win --- .github/workflows/general.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 07031648..5153ff90 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -153,8 +153,9 @@ jobs: - name: Test Binaries run: | Expand-Archive dpkit\compile\build\*windows*.zip - $dir = Get-ChildItem dp-* -Directory | Select-Object -First 1 - & ".\$($dir.Name)\dp.exe" --version + $exe = Get-ChildItem -Recurse -Name "dp.exe" | Select-Object -First 1 + icacls ".\$exe" /grant Everyone:F + & ".\$exe" --version # We have to split the release step because for some reason # using semantic-release before compilation inflates the binary sizes From 8a1d2e79a71408e8692e8960c07794031f033a9a Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 14:47:33 +0100 Subject: [PATCH 17/32] Enable win tests --- .github/workflows/general.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 5153ff90..89f874c1 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -143,8 +143,8 @@ jobs: run: pnpm ci:install - name: Build Packages run: pnpm build - # - name: Test Packages - # run: pnpm win:test + - name: Test Packages + run: pnpm win:test - name: Download Binaries uses: actions/download-artifact@v5 with: From 02a9528532c2d13b318fee648d4f1361d8eebd2d Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 14:54:28 +0100 Subject: [PATCH 18/32] Skipped macos binary test --- .github/workflows/general.yaml | 11 ++++++++--- package.json | 2 +- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 89f874c1..a1edef1a 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -72,7 +72,9 @@ jobs: name: binaries path: dpkit/compile/build - name: Test Binaries - run: unzip dpkit/compile/build/*linux*.zip && ./dp-*/dp --version + run: | + unzip -j dpkit/compile/build/*linux*.zip "dp*" + ./dp --version services: postgres: @@ -120,8 +122,11 @@ jobs: with: name: binaries path: dpkit/compile/build - - name: Test Binaries - run: unzip dpkit/compile/build/*macos*.zip && ./dp-*/dp --version + # Github Actions does not support AVX2 + # - name: Test Binaries + # run: | + # unzip -j dpkit/compile/build/*linux*.zip "dp*" + # ./dp --version test-windows: needs: [test-compile] diff --git a/package.json b/package.json index db868a53..abbb90a3 100644 --- a/package.json +++ b/package.json @@ -21,7 +21,7 @@ "prepare": "husky", "spec": "vitest run", "test": "pnpm lint && pnpm type && pnpm spec", - "win:test": "pnpm type && pnpm spec", + "win:test": "pnpm spec", "type": "tsc --noEmit" }, "devDependencies": { From 6250ea22579a9830af778215a2dbfbf8c8c53d5a Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 14:58:43 +0100 Subject: [PATCH 19/32] Rebaed on macos-latest-large --- .github/workflows/general.yaml | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index a1edef1a..3883e21d 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -97,7 +97,7 @@ jobs: test-macos: needs: [test-compile] - runs-on: macos-latest + runs-on: macos-latest-large steps: - name: Checkout Repo @@ -122,11 +122,10 @@ jobs: with: name: binaries path: dpkit/compile/build - # Github Actions does not support AVX2 - # - name: Test Binaries - # run: | - # unzip -j dpkit/compile/build/*linux*.zip "dp*" - # ./dp --version + - name: Test Binaries + run: | + unzip -j dpkit/compile/build/*linux*.zip "dp*" + ./dp --version test-windows: needs: [test-compile] From c75120bf4e4355d27cf3dcb8fe0ed005c003ca26 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 15:03:32 +0100 Subject: [PATCH 20/32] Fixed some win tests --- core/general/descriptor/load.ts | 2 +- core/general/path.spec.ts | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/core/general/descriptor/load.ts b/core/general/descriptor/load.ts index 4898a382..8fbfd972 100644 --- a/core/general/descriptor/load.ts +++ b/core/general/descriptor/load.ts @@ -29,7 +29,7 @@ async function loadRemoteDescriptor(path: string) { const url = new URL(path) const protocol = url.protocol.toLowerCase() - if (!ALLOWED_REMOTE_PROTOCOLS.includes(protocol)) { + if (protocol.length > 1 && !ALLOWED_REMOTE_PROTOCOLS.includes(protocol)) { throw new Error(`Unsupported remote protocol: ${protocol}`) } diff --git a/core/general/path.spec.ts b/core/general/path.spec.ts index a9fe96ad..63e76051 100644 --- a/core/general/path.spec.ts +++ b/core/general/path.spec.ts @@ -1,4 +1,4 @@ -import { relative } from "node:path" +import { join, relative } from "node:path" import { describe, expect, it } from "vitest" import { denormalizePath, @@ -153,12 +153,12 @@ describe("getBasepath", () => { { description: "local file path", path: "some/path/to/file.txt", - basepath: "some/path/to", + basepath: join("some", "path", "to"), }, { description: "local path with no file", path: "some/path/to/", - basepath: "some/path", + basepath: join("some", "path"), }, { description: "root level file", @@ -176,13 +176,13 @@ describe("normalizePath", () => { description: "local path without basepath", path: "path/to/file.txt", basepath: undefined, - normalizedPath: "path/to/file.txt", + normalizedPath: join("path", "to", "file.txt"), }, { description: "local path with local basepath", path: "file.txt", basepath: "path/to", - normalizedPath: "path/to/file.txt", + normalizedPath: join("path", "to", "file.txt"), }, { description: "remote path", @@ -212,7 +212,7 @@ describe("normalizePath", () => { description: "path with empty basepath", path: "path/to/file.txt", basepath: "", - normalizedPath: "path/to/file.txt", + normalizedPath: join("path", "to", "file.txt"), }, ])("$description", ({ path, basepath, normalizedPath }) => { expect(normalizePath(path, { basepath })).toEqual(normalizedPath) From bb7d3a783808b8f1e05e17c6593965f7b45e5727 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 15:20:02 +0100 Subject: [PATCH 21/32] Fixed remote protocol --- .github/workflows/general.yaml | 2 +- core/general/descriptor/load.spec.ts | 2 +- core/general/descriptor/load.ts | 5 +++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 3883e21d..9e408539 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -97,7 +97,7 @@ jobs: test-macos: needs: [test-compile] - runs-on: macos-latest-large + runs-on: macos-latest steps: - name: Checkout Repo diff --git a/core/general/descriptor/load.spec.ts b/core/general/descriptor/load.spec.ts index bfc9b75b..28bd3f5f 100644 --- a/core/general/descriptor/load.spec.ts +++ b/core/general/descriptor/load.spec.ts @@ -55,7 +55,7 @@ describe("loadDescriptor", () => { const testUrl = "file:///path/to/schema.json" await expect(loadDescriptor(testUrl)).rejects.toThrow( - "Unsupported remote protocol: file:", + "Unsupported remote protocol: file", ) }) diff --git a/core/general/descriptor/load.ts b/core/general/descriptor/load.ts index 8fbfd972..34bfff69 100644 --- a/core/general/descriptor/load.ts +++ b/core/general/descriptor/load.ts @@ -1,4 +1,5 @@ import { node } from "../node.ts" +import { getProtocol } from "../path.ts" import { getBasepath, isRemotePath } from "../path.ts" import { parseDescriptor } from "./process/parse.ts" @@ -23,12 +24,12 @@ export async function loadDescriptor( : await loadLocalDescriptor(path) } -const ALLOWED_REMOTE_PROTOCOLS = ["http:", "https:", "ftp:", "ftps:"] +const ALLOWED_REMOTE_PROTOCOLS = ["http", "https", "ftp", "ftps"] async function loadRemoteDescriptor(path: string) { const url = new URL(path) - const protocol = url.protocol.toLowerCase() + const protocol = getProtocol(path) if (protocol.length > 1 && !ALLOWED_REMOTE_PROTOCOLS.includes(protocol)) { throw new Error(`Unsupported remote protocol: ${protocol}`) } From 11359ac21f5b171265497eef9b4ab8b8b02488a5 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 15:31:29 +0100 Subject: [PATCH 22/32] Added arm64 support --- .github/workflows/general.yaml | 17 +++++++++-------- dpkit/scripts/compile.ts | 14 +++++++++++++- 2 files changed, 22 insertions(+), 9 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 9e408539..bf3c34b3 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -73,7 +73,7 @@ jobs: path: dpkit/compile/build - name: Test Binaries run: | - unzip -j dpkit/compile/build/*linux*.zip "dp*" + unzip -j dpkit/compile/build/*linux-x64.zip "dp*" ./dp --version services: @@ -124,7 +124,7 @@ jobs: path: dpkit/compile/build - name: Test Binaries run: | - unzip -j dpkit/compile/build/*linux*.zip "dp*" + unzip -j dpkit/compile/build/*darwin-arm64.zip "dp*" ./dp --version test-windows: @@ -154,12 +154,13 @@ jobs: with: name: binaries path: dpkit/compile/build - - name: Test Binaries - run: | - Expand-Archive dpkit\compile\build\*windows*.zip - $exe = Get-ChildItem -Recurse -Name "dp.exe" | Select-Object -First 1 - icacls ".\$exe" /grant Everyone:F - & ".\$exe" --version + # TODO: Enable Windows tests + # - name: Test Binaries + # run: | + # Expand-Archive dpkit\compile\build\*windows*.zip + # $exe = Get-ChildItem -Recurse -Name "dp.exe" | Select-Object -First 1 + # icacls ".\$exe" /grant Everyone:F + # & ".\$exe" --version # We have to split the release step because for some reason # using semantic-release before compilation inflates the binary sizes diff --git a/dpkit/scripts/compile.ts b/dpkit/scripts/compile.ts index fd336e0e..d57970a2 100644 --- a/dpkit/scripts/compile.ts +++ b/dpkit/scripts/compile.ts @@ -54,12 +54,24 @@ const targets = [ polars: "nodejs-polars-linux-x64-gnu", libsql: "libsql-linux-x64-gnu", }, + { + name: "bun-linux-arm64", + dpkit: "linux-arm64", + polars: "nodejs-polars-linux-arm64-gnu", + libsql: "libsql-linux-arm64-gnu", + }, { name: "bun-darwin-x64", dpkit: "macos-x64", polars: "nodejs-polars-darwin-x64", libsql: "libsql-darwin-x64", }, + { + name: "bun-darwin-arm64", + dpkit: "macos-arm64", + polars: "nodejs-polars-darwin-arm64", + libsql: "libsql-darwin-arm64", + }, { name: "bun-windows-x64", dpkit: "windows-x64", @@ -87,7 +99,7 @@ for (const target of targets) { ` // For some reason bun creates it with no permissions - if (target.name === "bun-windows-x64") { + if (target.name.startsWith("bun-windows")) { await $build`chmod +r ${folder}/dp.exe` } From e4e689e014e6deac1e03d13eaff7c21c002d2939 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 15:49:30 +0100 Subject: [PATCH 23/32] Fixed remote path check --- .github/workflows/general.yaml | 2 +- core/general/descriptor/load.spec.ts | 4 ++-- core/general/descriptor/load.ts | 2 +- core/general/path.spec.ts | 2 +- core/general/path.ts | 17 ++++++++++------- 5 files changed, 15 insertions(+), 12 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index bf3c34b3..dc909e8f 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -124,7 +124,7 @@ jobs: path: dpkit/compile/build - name: Test Binaries run: | - unzip -j dpkit/compile/build/*darwin-arm64.zip "dp*" + unzip -j dpkit/compile/build/*macos-arm64.zip "dp*" ./dp --version test-windows: diff --git a/core/general/descriptor/load.spec.ts b/core/general/descriptor/load.spec.ts index 28bd3f5f..b6e428f1 100644 --- a/core/general/descriptor/load.spec.ts +++ b/core/general/descriptor/load.spec.ts @@ -52,10 +52,10 @@ describe("loadDescriptor", () => { }) it("throws error for unsupported URL protocol", async () => { - const testUrl = "file:///path/to/schema.json" + const testUrl = "bad:///path/to/schema.json" await expect(loadDescriptor(testUrl)).rejects.toThrow( - "Unsupported remote protocol: file", + "Unsupported remote protocol: bad", ) }) diff --git a/core/general/descriptor/load.ts b/core/general/descriptor/load.ts index 34bfff69..b9771743 100644 --- a/core/general/descriptor/load.ts +++ b/core/general/descriptor/load.ts @@ -30,7 +30,7 @@ async function loadRemoteDescriptor(path: string) { const url = new URL(path) const protocol = getProtocol(path) - if (protocol.length > 1 && !ALLOWED_REMOTE_PROTOCOLS.includes(protocol)) { + if (!ALLOWED_REMOTE_PROTOCOLS.includes(protocol)) { throw new Error(`Unsupported remote protocol: ${protocol}`) } diff --git a/core/general/path.spec.ts b/core/general/path.spec.ts index 63e76051..7ac14e75 100644 --- a/core/general/path.spec.ts +++ b/core/general/path.spec.ts @@ -28,7 +28,7 @@ describe("isRemotePath", () => { { description: "file URL", path: "file:///path/to/file.txt", - isRemote: true, + isRemote: false, }, { description: "absolute path", diff --git a/core/general/path.ts b/core/general/path.ts index 4394153a..d8c2d97a 100644 --- a/core/general/path.ts +++ b/core/general/path.ts @@ -2,12 +2,8 @@ import slugify from "@sindresorhus/slugify" import { node } from "./node.ts" export function isRemotePath(path: string) { - try { - new URL(path) - return true - } catch { - return false - } + const protocol = getProtocol(path) + return protocol !== "file" } export function getName(filename?: string) { @@ -26,7 +22,14 @@ export function getName(filename?: string) { export function getProtocol(path: string) { try { const url = new URL(path) - return url.protocol.replace(":", "") + const protocol = url.protocol.replace(":", "") + + // Handle Windows drive letters + if (protocol.length < 2) { + return "file" + } + + return protocol } catch { return "file" } From d1e0bdcfa40528a4d9271ceab732cfa00897736e Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 17:05:43 +0100 Subject: [PATCH 24/32] Disable zip in dpkit for now --- all/plugin.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/all/plugin.ts b/all/plugin.ts index eb5acebe..da47af67 100644 --- a/all/plugin.ts +++ b/all/plugin.ts @@ -12,7 +12,9 @@ import { ParquetPlugin } from "@dpkit/parquet" import type { TablePlugin } from "@dpkit/table" import { XlsxPlugin } from "@dpkit/xlsx" import { ZenodoPlugin } from "@dpkit/zenodo" -import { ZipPlugin } from "@dpkit/zip" + +// TODO: Enable after migrated away from yauzl-promise (uses native crc32) +//import { ZipPlugin } from "@dpkit/zip" export class Dpkit { plugins: TablePlugin[] = [] @@ -30,7 +32,7 @@ dpkit.register(DatahubPlugin) dpkit.register(GithubPlugin) dpkit.register(ZenodoPlugin) dpkit.register(FolderPlugin) -dpkit.register(ZipPlugin) +//dpkit.register(ZipPlugin) // Table functions dpkit.register(ArrowPlugin) From 1b79380dea1f12e9e1c10f4c915dab8fb5524553 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 17:12:36 +0100 Subject: [PATCH 25/32] Fixed disabling zip --- all/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/all/index.ts b/all/index.ts index 90ad4b3a..b0f611ab 100644 --- a/all/index.ts +++ b/all/index.ts @@ -9,7 +9,7 @@ export * from "@dpkit/github" export * from "@dpkit/inline" export * from "@dpkit/table" export * from "@dpkit/zenodo" -export * from "@dpkit/zip" +//export * from "@dpkit/zip" export * from "./dialect/index.ts" export * from "./package/index.ts" From 556b7bc92e182726e8b6acee5726c942b3965fdb Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 17:17:35 +0100 Subject: [PATCH 26/32] Added TODO --- all/index.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/all/index.ts b/all/index.ts index b0f611ab..965d9d51 100644 --- a/all/index.ts +++ b/all/index.ts @@ -9,6 +9,8 @@ export * from "@dpkit/github" export * from "@dpkit/inline" export * from "@dpkit/table" export * from "@dpkit/zenodo" + +// TODO: Enable after migrated away from yauzl-promise (uses native crc32) //export * from "@dpkit/zip" export * from "./dialect/index.ts" From 26795fce9b64775d5fd2c05435553affd645de76 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 17:20:34 +0100 Subject: [PATCH 27/32] Upgraded vitest --- .github/workflows/general.yaml | 8 +- package.json | 6 +- pnpm-lock.yaml | 171 +++++++++++++++++++-------------- 3 files changed, 111 insertions(+), 74 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index dc909e8f..3a01729c 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -12,6 +12,8 @@ jobs: test-compile: runs-on: ubuntu-latest + if: false + steps: - name: Checkout Repo uses: actions/checkout@v5 @@ -40,6 +42,8 @@ jobs: needs: [test-compile] runs-on: ubuntu-latest + if: false + steps: - name: Checkout Repo uses: actions/checkout@v5 @@ -99,6 +103,8 @@ jobs: needs: [test-compile] runs-on: macos-latest + if: false + steps: - name: Checkout Repo uses: actions/checkout@v5 @@ -128,7 +134,7 @@ jobs: ./dp --version test-windows: - needs: [test-compile] + # needs: [test-compile] runs-on: windows-latest steps: diff --git a/package.json b/package.json index abbb90a3..6dab4597 100644 --- a/package.json +++ b/package.json @@ -28,8 +28,8 @@ "@biomejs/biome": "1.9.4", "@semantic-release/exec": "7.1.0", "@types/node": "24.2.0", - "@vitest/coverage-v8": "3.1.4", - "@vitest/ui": "3.1.4", + "@vitest/coverage-v8": "3.2.4", + "@vitest/ui": "3.2.4", "execa": "9.6.0", "husky": "9.1.7", "npm-check-updates": "18.0.1", @@ -37,7 +37,7 @@ "tempy": "3.1.0", "type-fest": "^4.41.0", "typescript": "5.9.2", - "vitest": "3.1.4" + "vitest": "3.2.4" }, "packageManager": "pnpm@10.11.0+sha512.6540583f41cc5f628eb3d9773ecee802f4f9ef9923cc45b69890fb47991d4b092964694ec3a4f738a420c918a333062c8b925d312f42e4f0c263eb603551f977" } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index ec81db01..a8e01275 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -18,11 +18,11 @@ importers: specifier: 24.2.0 version: 24.2.0 '@vitest/coverage-v8': - specifier: 3.1.4 - version: 3.1.4(vitest@3.1.4) + specifier: 3.2.4 + version: 3.2.4(vitest@3.2.4) '@vitest/ui': - specifier: 3.1.4 - version: 3.1.4(vitest@3.1.4) + specifier: 3.2.4 + version: 3.2.4(vitest@3.2.4) execa: specifier: 9.6.0 version: 9.6.0 @@ -45,8 +45,8 @@ importers: specifier: 5.9.2 version: 5.9.2 vitest: - specifier: 3.1.4 - version: 3.1.4(@types/debug@4.1.12)(@types/node@24.2.0)(@vitest/ui@3.1.4)(tsx@4.20.3)(yaml@2.8.1) + specifier: 3.2.4 + version: 3.2.4(@types/debug@4.1.12)(@types/node@24.2.0)(@vitest/ui@3.2.4)(tsx@4.20.3)(yaml@2.8.1) all: dependencies: @@ -1548,9 +1548,15 @@ packages: '@tybys/wasm-util@0.10.1': resolution: {integrity: sha512-9tTaPJLSiejZKx+Bmog4uSubteqTvFrVrURwkmHixBo0G4seD0zUxp98E1DzUBJxLQ3NPwXrGKDiVjwx/DpPsg==} + '@types/chai@5.2.2': + resolution: {integrity: sha512-8kB30R7Hwqf40JPiKhVzodJs2Qc1ZJ5zuT3uzw5Hq/dhNCl3G3l83jfpdI1e20BP348+fV7VIL/+FxaXkqBmWg==} + '@types/debug@4.1.12': resolution: {integrity: sha512-vIChWdVG3LG1SMxEvI/AK+FWJthlrqlTu7fbrlywTkkaONwk/UAGaULXRlf8vkzFBLVm0zkMdCquhL5aOjhXPQ==} + '@types/deep-eql@4.0.2': + resolution: {integrity: sha512-c9h9dVVMigMPc4bwTvC5dxqtqJZwQPePsWjPlpSOnojbor6pGqdk541lfA7AqFQr5pB1BRdq0juY9db81BwyFw==} + '@types/estree-jsx@1.0.5': resolution: {integrity: sha512-52CcUVNFyfb1A2ALocQw/Dd1BQFNmSdkuC3BkZ6iqhdMfQz7JWOFRuJFloOzjk+6WijU56m9oKXFAXc7o3Towg==} @@ -1614,51 +1620,48 @@ packages: '@ungap/structured-clone@1.3.0': resolution: {integrity: sha512-WmoN8qaIAo7WTYWbAZuG8PYEhn5fkz7dZrqTBZ7dtt//lL2Gwms1IcnQ5yHqjDfX8Ft5j4YzDM23f87zBfDe9g==} - '@vitest/coverage-v8@3.1.4': - resolution: {integrity: sha512-G4p6OtioySL+hPV7Y6JHlhpsODbJzt1ndwHAFkyk6vVjpK03PFsKnauZIzcd0PrK4zAbc5lc+jeZ+eNGiMA+iw==} + '@vitest/coverage-v8@3.2.4': + resolution: {integrity: sha512-EyF9SXU6kS5Ku/U82E259WSnvg6c8KTjppUncuNdm5QHpe17mwREHnjDzozC8x9MZ0xfBUFSaLkRv4TMA75ALQ==} peerDependencies: - '@vitest/browser': 3.1.4 - vitest: 3.1.4 + '@vitest/browser': 3.2.4 + vitest: 3.2.4 peerDependenciesMeta: '@vitest/browser': optional: true - '@vitest/expect@3.1.4': - resolution: {integrity: sha512-xkD/ljeliyaClDYqHPNCiJ0plY5YIcM0OlRiZizLhlPmpXWpxnGMyTZXOHFhFeG7w9P5PBeL4IdtJ/HeQwTbQA==} + '@vitest/expect@3.2.4': + resolution: {integrity: sha512-Io0yyORnB6sikFlt8QW5K7slY4OjqNX9jmJQ02QDda8lyM6B5oNgVWoSoKPac8/kgnCUzuHQKrSLtu/uOqqrig==} - '@vitest/mocker@3.1.4': - resolution: {integrity: sha512-8IJ3CvwtSw/EFXqWFL8aCMu+YyYXG2WUSrQbViOZkWTKTVicVwZ/YiEZDSqD00kX+v/+W+OnxhNWoeVKorHygA==} + '@vitest/mocker@3.2.4': + resolution: {integrity: sha512-46ryTE9RZO/rfDd7pEqFl7etuyzekzEhUbTW3BvmeO/BcCMEgq59BKhek3dXDWgAj4oMK6OZi+vRr1wPW6qjEQ==} peerDependencies: msw: ^2.4.9 - vite: ^5.0.0 || ^6.0.0 + vite: ^5.0.0 || ^6.0.0 || ^7.0.0-0 peerDependenciesMeta: msw: optional: true vite: optional: true - '@vitest/pretty-format@3.1.4': - resolution: {integrity: sha512-cqv9H9GvAEoTaoq+cYqUTCGscUjKqlJZC7PRwY5FMySVj5J+xOm1KQcCiYHJOEzOKRUhLH4R2pTwvFlWCEScsg==} - '@vitest/pretty-format@3.2.4': resolution: {integrity: sha512-IVNZik8IVRJRTr9fxlitMKeJeXFFFN0JaB9PHPGQ8NKQbGpfjlTx9zO4RefN8gp7eqjNy8nyK3NZmBzOPeIxtA==} - '@vitest/runner@3.1.4': - resolution: {integrity: sha512-djTeF1/vt985I/wpKVFBMWUlk/I7mb5hmD5oP8K9ACRmVXgKTae3TUOtXAEBfslNKPzUQvnKhNd34nnRSYgLNQ==} + '@vitest/runner@3.2.4': + resolution: {integrity: sha512-oukfKT9Mk41LreEW09vt45f8wx7DordoWUZMYdY/cyAk7w5TWkTRCNZYF7sX7n2wB7jyGAl74OxgwhPgKaqDMQ==} - '@vitest/snapshot@3.1.4': - resolution: {integrity: sha512-JPHf68DvuO7vilmvwdPr9TS0SuuIzHvxeaCkxYcCD4jTk67XwL45ZhEHFKIuCm8CYstgI6LZ4XbwD6ANrwMpFg==} + '@vitest/snapshot@3.2.4': + resolution: {integrity: sha512-dEYtS7qQP2CjU27QBC5oUOxLE/v5eLkGqPE0ZKEIDGMs4vKWe7IjgLOeauHsR0D5YuuycGRO5oSRXnwnmA78fQ==} - '@vitest/spy@3.1.4': - resolution: {integrity: sha512-Xg1bXhu+vtPXIodYN369M86K8shGLouNjoVI78g8iAq2rFoHFdajNvJJ5A/9bPMFcfQqdaCpOgWKEoMQg/s0Yg==} + '@vitest/spy@3.2.4': + resolution: {integrity: sha512-vAfasCOe6AIK70iP5UD11Ac4siNUNJ9i/9PZ3NKx07sG6sUxeag1LWdNrMWeKKYBLlzuK+Gn65Yd5nyL6ds+nw==} - '@vitest/ui@3.1.4': - resolution: {integrity: sha512-CFc2Bpb3sz4Sdt53kdNGq+qZKLftBwX4qZLC03CBUc0N1LJrOoL0ZeK0oq/708mtnpwccL0BZCY9d1WuiBSr7Q==} + '@vitest/ui@3.2.4': + resolution: {integrity: sha512-hGISOaP18plkzbWEcP/QvtRW1xDXF2+96HbEX6byqQhAUbiS5oH6/9JwW+QsQCIYON2bI6QZBF+2PvOmrRZ9wA==} peerDependencies: - vitest: 3.1.4 + vitest: 3.2.4 - '@vitest/utils@3.1.4': - resolution: {integrity: sha512-yriMuO1cfFhmiGc8ataN51+9ooHRuURdfAZfwFd3usWynjzpLslZdYnRegTv32qdgtJTsj15FoeZe2g15fY1gg==} + '@vitest/utils@3.2.4': + resolution: {integrity: sha512-fB2V0JFrQSMsCo9HiSq3Ezpdv4iYaXRG1Sx8edX3MwxfyNn83mKiGzOcH+Fkxt4MHxr3y42fQi1oeAInqgX2QA==} accepts@1.3.8: resolution: {integrity: sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==} @@ -1749,6 +1752,9 @@ packages: resolution: {integrity: sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA==} engines: {node: '>=12'} + ast-v8-to-istanbul@0.3.5: + resolution: {integrity: sha512-9SdXjNheSiE8bALAQCQQuT6fgQaoxJh7IRYrRGZ8/9nv8WhJeC1aXAwN8TbaOssGOukUvyvnkgD9+Yuykvl1aA==} + astring@1.9.0: resolution: {integrity: sha512-LElXdjswlqjWrPpJFg1Fx4wpkOCxj1TDHlSV4PlaRxHGWko024xICaa97ZkMfs6DRKlCguiAI+rbXv5GWwXIkg==} hasBin: true @@ -2856,6 +2862,9 @@ packages: js-tokens@4.0.0: resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==} + js-tokens@9.0.1: + resolution: {integrity: sha512-mxa9E9ITFOt0ban3j6L5MpjwegGz6lBQmM1IJkWeBZGcMxto50+eWdjC/52xDbS2vy0k7vIMK0Fe2wfL9OQSpQ==} + js-yaml@4.1.0: resolution: {integrity: sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==} hasBin: true @@ -4212,6 +4221,9 @@ packages: resolution: {integrity: sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==} engines: {node: '>=0.10.0'} + strip-literal@3.0.0: + resolution: {integrity: sha512-TcccoMhJOM3OebGhSBEmp3UZ2SfDMZUEBdRA/9ynfLi8yYajyWX3JiXArcJt4Umh4vISpspkQIY8ZZoCqjbviA==} + style-to-js@1.1.17: resolution: {integrity: sha512-xQcBGDxJb6jjFCTzvQtfiPn6YvvP2O8U1MDIPNfJQlWMYfktPy+iGsHE7cssjs7y84d9fQaK4UF3RIJaAHSoYA==} @@ -4284,8 +4296,8 @@ packages: resolution: {integrity: sha512-op4nsTR47R6p0vMUUoYl/a+ljLFVtlfaXkLQmqfLR1qHma1h/ysYk4hEXZ880bf2CYgTskvTa/e196Vd5dDQXw==} engines: {node: '>=14.0.0'} - tinyspy@3.0.2: - resolution: {integrity: sha512-n1cw8k1k0x4pgA2+9XrOkFydTerNcJ1zWCO5Nn9scWHTD+5tp8dghT2x1uduQePZTZgd3Tupf+x9BxJjeJi77Q==} + tinyspy@4.0.4: + resolution: {integrity: sha512-azl+t0z7pw/z958Gy9svOTuzqIk6xq+NSheJzn5MMWtWTFywIacg2wUlzKFGtt3cthx0r2SxMK0yzJOR0IES7Q==} engines: {node: '>=14.0.0'} to-arraybuffer@1.0.1: @@ -4556,8 +4568,8 @@ packages: vfile@6.0.3: resolution: {integrity: sha512-KzIbH/9tXat2u30jf+smMwFCsno4wHVdNmzFyL+T/L3UGqqk6JKfVqOFOZEpZSHADH1k40ab6NUIXZq422ov3Q==} - vite-node@3.1.4: - resolution: {integrity: sha512-6enNwYnpyDo4hEgytbmc6mYWHXDHYEn0D1/rw4Q+tnHUGtKTJsn8T1YkX6Q18wI5LCrS8CTYlBaiCqxOy2kvUA==} + vite-node@3.2.4: + resolution: {integrity: sha512-EbKSKh+bh1E1IFxeO0pg1n4dvoOTt0UDiXMd/qn++r98+jPO1xtJilvXldeuQ8giIB5IkpjCgMleHMNEsGH6pg==} engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0} hasBin: true @@ -4609,16 +4621,16 @@ packages: vite: optional: true - vitest@3.1.4: - resolution: {integrity: sha512-Ta56rT7uWxCSJXlBtKgIlApJnT6e6IGmTYxYcmxjJ4ujuZDI59GUQgVDObXXJujOmPDBYXHK1qmaGtneu6TNIQ==} + vitest@3.2.4: + resolution: {integrity: sha512-LUCP5ev3GURDysTWiP47wRRUpLKMOfPh+yKTx3kVIEiu5KOMeqzpnYNsKyOoVrULivR8tLcks4+lga33Whn90A==} engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0} hasBin: true peerDependencies: '@edge-runtime/vm': '*' '@types/debug': ^4.1.12 '@types/node': ^18.0.0 || ^20.0.0 || >=22.0.0 - '@vitest/browser': 3.1.4 - '@vitest/ui': 3.1.4 + '@vitest/browser': 3.2.4 + '@vitest/ui': 3.2.4 happy-dom: '*' jsdom: '*' peerDependenciesMeta: @@ -5790,10 +5802,16 @@ snapshots: tslib: 2.8.1 optional: true + '@types/chai@5.2.2': + dependencies: + '@types/deep-eql': 4.0.2 + '@types/debug@4.1.12': dependencies: '@types/ms': 2.1.0 + '@types/deep-eql@4.0.2': {} + '@types/estree-jsx@1.0.5': dependencies: '@types/estree': 1.0.8 @@ -5862,10 +5880,11 @@ snapshots: '@ungap/structured-clone@1.3.0': {} - '@vitest/coverage-v8@3.1.4(vitest@3.1.4)': + '@vitest/coverage-v8@3.2.4(vitest@3.2.4)': dependencies: '@ampproject/remapping': 2.3.0 '@bcoe/v8-coverage': 1.0.2 + ast-v8-to-istanbul: 0.3.5 debug: 4.4.3 istanbul-lib-coverage: 3.2.2 istanbul-lib-report: 3.0.1 @@ -5876,62 +5895,60 @@ snapshots: std-env: 3.9.0 test-exclude: 7.0.1 tinyrainbow: 2.0.0 - vitest: 3.1.4(@types/debug@4.1.12)(@types/node@24.2.0)(@vitest/ui@3.1.4)(tsx@4.20.3)(yaml@2.8.1) + vitest: 3.2.4(@types/debug@4.1.12)(@types/node@24.2.0)(@vitest/ui@3.2.4)(tsx@4.20.3)(yaml@2.8.1) transitivePeerDependencies: - supports-color - '@vitest/expect@3.1.4': + '@vitest/expect@3.2.4': dependencies: - '@vitest/spy': 3.1.4 - '@vitest/utils': 3.1.4 + '@types/chai': 5.2.2 + '@vitest/spy': 3.2.4 + '@vitest/utils': 3.2.4 chai: 5.3.3 tinyrainbow: 2.0.0 - '@vitest/mocker@3.1.4(vite@6.3.6(@types/node@24.2.0)(tsx@4.20.3)(yaml@2.8.1))': + '@vitest/mocker@3.2.4(vite@6.3.6(@types/node@24.2.0)(tsx@4.20.3)(yaml@2.8.1))': dependencies: - '@vitest/spy': 3.1.4 + '@vitest/spy': 3.2.4 estree-walker: 3.0.3 magic-string: 0.30.19 optionalDependencies: vite: 6.3.6(@types/node@24.2.0)(tsx@4.20.3)(yaml@2.8.1) - '@vitest/pretty-format@3.1.4': - dependencies: - tinyrainbow: 2.0.0 - '@vitest/pretty-format@3.2.4': dependencies: tinyrainbow: 2.0.0 - '@vitest/runner@3.1.4': + '@vitest/runner@3.2.4': dependencies: - '@vitest/utils': 3.1.4 + '@vitest/utils': 3.2.4 pathe: 2.0.3 + strip-literal: 3.0.0 - '@vitest/snapshot@3.1.4': + '@vitest/snapshot@3.2.4': dependencies: - '@vitest/pretty-format': 3.1.4 + '@vitest/pretty-format': 3.2.4 magic-string: 0.30.19 pathe: 2.0.3 - '@vitest/spy@3.1.4': + '@vitest/spy@3.2.4': dependencies: - tinyspy: 3.0.2 + tinyspy: 4.0.4 - '@vitest/ui@3.1.4(vitest@3.1.4)': + '@vitest/ui@3.2.4(vitest@3.2.4)': dependencies: - '@vitest/utils': 3.1.4 + '@vitest/utils': 3.2.4 fflate: 0.8.2 flatted: 3.3.3 pathe: 2.0.3 sirv: 3.0.2 tinyglobby: 0.2.15 tinyrainbow: 2.0.0 - vitest: 3.1.4(@types/debug@4.1.12)(@types/node@24.2.0)(@vitest/ui@3.1.4)(tsx@4.20.3)(yaml@2.8.1) + vitest: 3.2.4(@types/debug@4.1.12)(@types/node@24.2.0)(@vitest/ui@3.2.4)(tsx@4.20.3)(yaml@2.8.1) - '@vitest/utils@3.1.4': + '@vitest/utils@3.2.4': dependencies: - '@vitest/pretty-format': 3.1.4 + '@vitest/pretty-format': 3.2.4 loupe: 3.2.1 tinyrainbow: 2.0.0 @@ -6010,6 +6027,12 @@ snapshots: assertion-error@2.0.1: {} + ast-v8-to-istanbul@0.3.5: + dependencies: + '@jridgewell/trace-mapping': 0.3.31 + estree-walker: 3.0.3 + js-tokens: 9.0.1 + astring@1.9.0: {} astro-expressive-code@0.41.3(astro@5.12.9(@types/node@24.2.0)(rollup@4.50.1)(tsx@4.20.3)(typescript@5.9.2)(yaml@2.8.1)): @@ -7369,6 +7392,8 @@ snapshots: js-tokens@4.0.0: {} + js-tokens@9.0.1: {} + js-yaml@4.1.0: dependencies: argparse: 2.0.1 @@ -9044,6 +9069,10 @@ snapshots: strip-json-comments@2.0.1: {} + strip-literal@3.0.0: + dependencies: + js-tokens: 9.0.1 + style-to-js@1.1.17: dependencies: style-to-object: 1.0.9 @@ -9119,7 +9148,7 @@ snapshots: tinyrainbow@2.0.0: {} - tinyspy@3.0.2: {} + tinyspy@4.0.4: {} to-arraybuffer@1.0.1: {} @@ -9329,7 +9358,7 @@ snapshots: '@types/unist': 3.0.3 vfile-message: 4.0.3 - vite-node@3.1.4(@types/node@24.2.0)(tsx@4.20.3)(yaml@2.8.1): + vite-node@3.2.4(@types/node@24.2.0)(tsx@4.20.3)(yaml@2.8.1): dependencies: cac: 6.7.14 debug: 4.4.3 @@ -9368,20 +9397,22 @@ snapshots: optionalDependencies: vite: 6.3.6(@types/node@24.2.0)(tsx@4.20.3)(yaml@2.8.1) - vitest@3.1.4(@types/debug@4.1.12)(@types/node@24.2.0)(@vitest/ui@3.1.4)(tsx@4.20.3)(yaml@2.8.1): + vitest@3.2.4(@types/debug@4.1.12)(@types/node@24.2.0)(@vitest/ui@3.2.4)(tsx@4.20.3)(yaml@2.8.1): dependencies: - '@vitest/expect': 3.1.4 - '@vitest/mocker': 3.1.4(vite@6.3.6(@types/node@24.2.0)(tsx@4.20.3)(yaml@2.8.1)) + '@types/chai': 5.2.2 + '@vitest/expect': 3.2.4 + '@vitest/mocker': 3.2.4(vite@6.3.6(@types/node@24.2.0)(tsx@4.20.3)(yaml@2.8.1)) '@vitest/pretty-format': 3.2.4 - '@vitest/runner': 3.1.4 - '@vitest/snapshot': 3.1.4 - '@vitest/spy': 3.1.4 - '@vitest/utils': 3.1.4 + '@vitest/runner': 3.2.4 + '@vitest/snapshot': 3.2.4 + '@vitest/spy': 3.2.4 + '@vitest/utils': 3.2.4 chai: 5.3.3 debug: 4.4.3 expect-type: 1.2.2 magic-string: 0.30.19 pathe: 2.0.3 + picomatch: 4.0.3 std-env: 3.9.0 tinybench: 2.9.0 tinyexec: 0.3.2 @@ -9389,12 +9420,12 @@ snapshots: tinypool: 1.1.1 tinyrainbow: 2.0.0 vite: 6.3.6(@types/node@24.2.0)(tsx@4.20.3)(yaml@2.8.1) - vite-node: 3.1.4(@types/node@24.2.0)(tsx@4.20.3)(yaml@2.8.1) + vite-node: 3.2.4(@types/node@24.2.0)(tsx@4.20.3)(yaml@2.8.1) why-is-node-running: 2.3.0 optionalDependencies: '@types/debug': 4.1.12 '@types/node': 24.2.0 - '@vitest/ui': 3.1.4(vitest@3.1.4) + '@vitest/ui': 3.2.4(vitest@3.2.4) transitivePeerDependencies: - jiti - less From 55c29f904c874f7252067f851aa2d3e999634c75 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 17:30:40 +0100 Subject: [PATCH 28/32] Fixed exports for win --- file/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/file/package.json b/file/package.json index b7cdcfa8..9e3dff19 100644 --- a/file/package.json +++ b/file/package.json @@ -2,7 +2,7 @@ "name": "@dpkit/file", "type": "module", "version": "0.0.0-development", - "exports": "./build/index.js", + "exports": { ".": "./build/index.js" }, "license": "MIT", "author": "Evgeny Karev", "repository": "https://github.com/datisthq/dpkit", From 9c0a61cfe9a4c1641bf62bc8f1a80d54a0117635 Mon Sep 17 00:00:00 2001 From: roll Date: Tue, 23 Sep 2025 17:34:07 +0100 Subject: [PATCH 29/32] Reverted exports --- file/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/file/package.json b/file/package.json index 9e3dff19..b7cdcfa8 100644 --- a/file/package.json +++ b/file/package.json @@ -2,7 +2,7 @@ "name": "@dpkit/file", "type": "module", "version": "0.0.0-development", - "exports": { ".": "./build/index.js" }, + "exports": "./build/index.js", "license": "MIT", "author": "Evgeny Karev", "repository": "https://github.com/datisthq/dpkit", From 7f7fece2c147b99150a74a2434110487574a0a7a Mon Sep 17 00:00:00 2001 From: roll Date: Wed, 24 Sep 2025 10:26:33 +0100 Subject: [PATCH 30/32] Added install script --- site/public/install.sh | 97 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100755 site/public/install.sh diff --git a/site/public/install.sh b/site/public/install.sh new file mode 100755 index 00000000..fa0c3800 --- /dev/null +++ b/site/public/install.sh @@ -0,0 +1,97 @@ +#!/bin/sh + +# This script installs dpkit. +# +# Quick install: `curl https://dpkit.dev/install.sh | sh` +# +# Acknowledgments: +# - eget (https://github.com/zyedidia/eget + +set -e -u + +# Program + +echo "Program: dp" + +# Version + +githubLatestTag() { + finalUrl=$(curl "https://github.com/$1/releases/latest" -s -L -I -o /dev/null -w '%{url_effective}') + printf "%s\n" "${finalUrl##*v}" +} + +version=$(githubLatestTag datisthq/dpkit) +echo "Version: $version" + +# Platform + +platform='' +machine=$(uname -m) + +if [ "${GETEGET_PLATFORM:-x}" != "x" ]; then + platform="$GETEGET_PLATFORM" +else + case "$(uname -s | tr '[:upper:]' '[:lower:]')" in + "linux") + case "$machine" in + "arm64"* | "aarch64"* ) platform='linux-arm64' ;; + *"64") platform='linux-x64' ;; + esac + ;; + "darwin") + case "$machine" in + "arm64"* | "aarch64"* ) platform='macos-arm64' ;; + *"64") platform='macos-x64' ;; + esac + ;; + "msys"*|"cygwin"*|"mingw"*|*"_nt"*|"win"*) + case "$machine" in + *"64") platform='windows-x64' ;; + esac + ;; + esac +fi + +if [ "x$platform" = "x" ]; then + cat << 'EOM' +/=====================================\\ +| COULD NOT DETECT PLATFORM | +\\=====================================/ +Uh oh! We couldn't automatically detect your operating system. +To continue with installation, please choose from one of the following values: +- linux-x64 +- linux-arm64 +- macos-x64 +- macos-arm64 +- windows-x64 +Export your selection as the DPKIT_PLATFORM environment variable, and then +re-run this script. +For example: + $ export DPKIT_PLATFORM=linux-x64 + $ curl https://dpkit.dev/install.sh | sh +EOM + exit 1 +else + echo "Platform: $platform" +fi + +# Download + +archive="dp-$version-$platform.zip" +source="https://github.com/datisthq/dpkit/releases/download/v$version/$archive" +echo "Downloading: $source" +wget -qL --show-progress "https://github.com/datisthq/dpkit/releases/download/v$version/$archive" -O $archive + +# Extract + +echo "Extracting: $archive" +unzip -nqj $archive + +# Remove + +echo "Removing: $archive" +unlink $archive + +# Done + +echo 'Done: run it with "./dp"' From 2dc65731c2f7972631288b3056a7f1bf46e8e636 Mon Sep 17 00:00:00 2001 From: roll Date: Wed, 24 Sep 2025 11:37:25 +0100 Subject: [PATCH 31/32] Skip win testing for now --- .github/workflows/general.yaml | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) diff --git a/.github/workflows/general.yaml b/.github/workflows/general.yaml index 3a01729c..366040f5 100644 --- a/.github/workflows/general.yaml +++ b/.github/workflows/general.yaml @@ -12,8 +12,6 @@ jobs: test-compile: runs-on: ubuntu-latest - if: false - steps: - name: Checkout Repo uses: actions/checkout@v5 @@ -42,8 +40,6 @@ jobs: needs: [test-compile] runs-on: ubuntu-latest - if: false - steps: - name: Checkout Repo uses: actions/checkout@v5 @@ -103,8 +99,6 @@ jobs: needs: [test-compile] runs-on: macos-latest - if: false - steps: - name: Checkout Repo uses: actions/checkout@v5 @@ -134,7 +128,7 @@ jobs: ./dp --version test-windows: - # needs: [test-compile] + needs: [test-compile] runs-on: windows-latest steps: @@ -153,13 +147,13 @@ jobs: run: pnpm ci:install - name: Build Packages run: pnpm build - - name: Test Packages - run: pnpm win:test - - name: Download Binaries - uses: actions/download-artifact@v5 - with: - name: binaries - path: dpkit/compile/build + # - name: Test Packages + # run: pnpm win:test + # - name: Download Binaries + # uses: actions/download-artifact@v5 + # with: + # name: binaries + # path: dpkit/compile/build # TODO: Enable Windows tests # - name: Test Binaries # run: | From ae5cc05ce99fe503566f59ae86462cb6c2b6b217 Mon Sep 17 00:00:00 2001 From: roll Date: Wed, 24 Sep 2025 11:40:36 +0100 Subject: [PATCH 32/32] Fixed install.sh comments --- site/public/install.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/site/public/install.sh b/site/public/install.sh index fa0c3800..85dacde9 100755 --- a/site/public/install.sh +++ b/site/public/install.sh @@ -1,11 +1,11 @@ #!/bin/sh -# This script installs dpkit. +# This script installs dpkit # # Quick install: `curl https://dpkit.dev/install.sh | sh` # # Acknowledgments: -# - eget (https://github.com/zyedidia/eget +# - eget (https://github.com/zyedidia/eget) set -e -u