Skip to content

Commit

Permalink
chore: upgrade to Effect v3 (#163)
Browse files Browse the repository at this point in the history
* chore: bump to v3 effect

* chore(remote-tarball-fetcher): bump to v3 effect

* benchmark: publish benchmark results from node_20.x

* benchmark: publish benchmark results from node_18.x

---------

Co-authored-by: skott_bot <skott.devtool@gmail.com>
  • Loading branch information
antoine-coulon and skott_bot committed Jun 15, 2024
1 parent b13d3c9 commit efb106a
Show file tree
Hide file tree
Showing 8 changed files with 78 additions and 73 deletions.
6 changes: 6 additions & 0 deletions .changeset/small-moose-fry.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"remote-tarball-fetcher": patch
"skott": patch
---

Upgrade to Effect v3
8 changes: 4 additions & 4 deletions packages/remote-tarball-fetcher/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
"lint": "eslint ."
},
"dependencies": {
"@effect/schema": "0.63.2",
"effect": "2.4.1",
"@effect/schema": "^0.67.23",
"effect": "3.3.2",
"semver": "^7.5.3",
"tar": "^6.1.15",
"unzipper": "^0.10.14"
Expand All @@ -41,11 +41,11 @@
"eslint-import-resolver-typescript": "^3.6.1",
"eslint-plugin-import": "^2.27.5",
"eslint-plugin-prettier": "^5.0.0",
"vitest": "1.6.0",
"prettier": "^3.0.3",
"rimraf": "^3.0.2",
"ts-node": "^10.9.1",
"typescript": "^5.4.0"
"typescript": "^5.4.0",
"vitest": "1.6.0"
},
"files": [
"dist",
Expand Down
6 changes: 3 additions & 3 deletions packages/remote-tarball-fetcher/src/fetcher/github.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ interface GitHubRepositoryInformation {
defaultBranch: string;
}

const GitHubSchema = S.struct({
default_branch: S.string,
id: S.number
const GitHubSchema = S.Struct({
default_branch: S.String,
id: S.Number
});

function makeTarballUrl(branch: string, repositoryFullName: string) {
Expand Down
16 changes: 8 additions & 8 deletions packages/remote-tarball-fetcher/src/fetcher/npm.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,18 +33,18 @@ function dissociatePackageNameFromItsSemver(packageName: string): {
};
}

const NpmRepositorySchema = S.struct({
"dist-tags": S.struct({
latest: S.string
const NpmRepositorySchema = S.Struct({
"dist-tags": S.Struct({
latest: S.String
}),
versions: S.record(
S.string,
S.struct({ dist: S.struct({ tarball: S.string }) })
versions: S.Record(
S.String,
S.Struct({ dist: S.Struct({ tarball: S.String }) })
)
});

const NpmRepositoryByVersionSchema = S.struct({
dist: S.struct({ tarball: S.string })
const NpmRepositoryByVersionSchema = S.Struct({
dist: S.Struct({ tarball: S.String })
});

function fetchFromNpm(url: string) {
Expand Down
2 changes: 1 addition & 1 deletion packages/skott/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
"compression": "^1.7.4",
"depcheck": "^1.4.3",
"digraph-js": "^2.2.3",
"effect": "2.4.1",
"effect": "3.3.2",
"estree-walker": "^3.0.3",
"fp-ts": "2.5.0",
"fs-tree-structure": "workspace:*",
Expand Down
38 changes: 19 additions & 19 deletions packages/skott/test/benchmark/result-node-18.x.json
Original file line number Diff line number Diff line change
@@ -1,40 +1,40 @@
{
"name": "skott_benchmark",
"done_at": "2024-06-15T16:09:05.376Z",
"git_commit_hash": "dd7e66babc49b71afc70142074f0fc1d09ce5db4",
"git_branch_reference": "feat-isolated-nodes",
"done_at": "2024-06-15T16:31:05.237Z",
"git_commit_hash": "0fb9e60974925ced210791e9708441fe7431d361",
"git_branch_reference": "latest-effect",
"results": [
{
"name": "knex/knex",
"rank": 1,
"totalTime": 7615.61580499995,
"min": 1499.4296109999996,
"mean": 1523.12316099999,
"max": 1545.6813479999837
"totalTime": 7566.931263000006,
"min": 1453.1940299999842,
"mean": 1513.3862526000012,
"max": 1648.731307000009
},
{
"name": "parcel-bundler/parcel",
"rank": 3,
"totalTime": 28911.505858999968,
"min": 5636.564931000001,
"mean": 5782.301171799993,
"max": 5929.7201230000355
"totalTime": 27217.388696999988,
"min": 5396.874100999994,
"mean": 5443.4777393999975,
"max": 5515.991994999989
},
{
"name": "Effect-TS/effect",
"rank": 4,
"totalTime": 64159.772661999974,
"min": 12708.475534000027,
"mean": 12831.954532399996,
"max": 12930.35306699999
"totalTime": 63231.34803600004,
"min": 12520.631244999997,
"mean": 12646.269607200007,
"max": 12765.331609999994
},
{
"name": "gcanti/fp-ts",
"rank": 2,
"totalTime": 21564.079151000013,
"min": 4288.3607329999795,
"mean": 4312.815830200003,
"max": 4341.06635800004
"totalTime": 20746.82731000008,
"min": 4136.819593000051,
"mean": 4149.365462000016,
"max": 4174.350321999984
}
]
}
38 changes: 19 additions & 19 deletions packages/skott/test/benchmark/result-node-20.x.json
Original file line number Diff line number Diff line change
@@ -1,40 +1,40 @@
{
"name": "skott_benchmark",
"done_at": "2024-06-15T16:09:04.355Z",
"git_commit_hash": "dd7e66babc49b71afc70142074f0fc1d09ce5db4",
"git_branch_reference": "feat-isolated-nodes",
"done_at": "2024-06-15T16:30:58.089Z",
"git_commit_hash": "0fb9e60974925ced210791e9708441fe7431d361",
"git_branch_reference": "latest-effect",
"results": [
{
"name": "knex/knex",
"rank": 1,
"totalTime": 7505.696782000003,
"min": 1466.6123599999992,
"mean": 1501.1393564000005,
"max": 1548.2739910000018
"totalTime": 7184.411860999997,
"min": 1424.0065349999986,
"mean": 1436.8823721999993,
"max": 1451.913821
},
{
"name": "parcel-bundler/parcel",
"rank": 3,
"totalTime": 28102.342516000004,
"min": 5546.889507,
"mean": 5620.468503200001,
"max": 5686.298540000003
"totalTime": 26903.81973399999,
"min": 5329.4630620000025,
"mean": 5380.763946799998,
"max": 5463.410732999997
},
{
"name": "Effect-TS/effect",
"rank": 4,
"totalTime": 63869.92417999997,
"min": 12599.422429999977,
"mean": 12773.984835999994,
"max": 12931.928272999998
"totalTime": 62518.74113500002,
"min": 12446.516215999989,
"mean": 12503.748227000004,
"max": 12576.58404300001
},
{
"name": "gcanti/fp-ts",
"rank": 2,
"totalTime": 21470.55115699998,
"min": 4259.032535999984,
"mean": 4294.110231399996,
"max": 4345.170425999997
"totalTime": 21098.286584000016,
"min": 4182.197864999995,
"mean": 4219.657316800003,
"max": 4261.650327999989
}
]
}
37 changes: 18 additions & 19 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit efb106a

Please sign in to comment.