Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat!: JSON RPC based typegraph #877

Open
wants to merge 45 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
eb2db29
update: replace wit with codegen interface
luckasRanarison Oct 25, 2024
c3e62f9
wip: dummy server & client sdk rewrite
luckasRanarison Oct 28, 2024
a3077a7
fixup: cleanup
luckasRanarison Oct 28, 2024
fe4b9f1
wip: fix python & try testing
luckasRanarison Oct 29, 2024
93c8226
fix: dev mode & test typegraph parsing
luckasRanarison Nov 4, 2024
752bafe
Merge branch 'main' into feat/typegraph-ng
luckasRanarison Nov 4, 2024
cc03068
fix: several fixes
luckasRanarison Nov 4, 2024
332cd39
wip: fix tests
luckasRanarison Nov 4, 2024
30fc9b9
fix: ghjk tg-build & codegen deno
luckasRanarison Nov 5, 2024
a2c02cb
fix: remove wasm related ops
luckasRanarison Nov 5, 2024
70375bb
fix: TS client
luckasRanarison Nov 5, 2024
76a2064
fix: bad mappings
luckasRanarison Nov 5, 2024
4de7198
fix: wasm tests
luckasRanarison Nov 5, 2024
dc7c676
fix: tg-build
luckasRanarison Nov 6, 2024
e3bc708
fix: node support
luckasRanarison Nov 6, 2024
5129994
fix: cli stuff
luckasRanarison Nov 6, 2024
530446d
fix: fs operations & python lockfile
luckasRanarison Nov 6, 2024
122ca73
fix: python sync test
luckasRanarison Nov 6, 2024
fd3942f
wip: temporary fixes
luckasRanarison Nov 11, 2024
ad4070b
fix prisma_test.ts, fix pre-commit
Natoandro Nov 12, 2024
0a1626f
fix other tests
Natoandro Nov 12, 2024
89a91f9
wip: more fixes
luckasRanarison Nov 12, 2024
f9d32d0
fix: snapshot test
luckasRanarison Nov 12, 2024
96d3080
Merge branch 'main' into feat/typegraph-ng
luckasRanarison Nov 13, 2024
d9cacb2
fix: build & merge conflicts
luckasRanarison Nov 13, 2024
0a709c2
fixup: missing import
luckasRanarison Nov 13, 2024
87b6774
fix: jsonrpc prefix
luckasRanarison Nov 13, 2024
c72ddaa
lint (pre-commit)
Natoandro Nov 14, 2024
1f9f159
remove conflicting migrations
Natoandro Nov 14, 2024
cfb0745
fix: merge conflicts
luckasRanarison Nov 14, 2024
b54bdf1
fix: build & some tests
luckasRanarison Nov 14, 2024
39f7b3a
fix: validation test
luckasRanarison Nov 15, 2024
b6f7c39
fix: deno.lock
luckasRanarison Nov 15, 2024
90e42de
Merge branch 'main' into feat/typegraph-ng
luckasRanarison Nov 16, 2024
323571a
fix: some fixes & cleanup
luckasRanarison Nov 16, 2024
045f4a1
fix: additional fixes
luckasRanarison Nov 16, 2024
958a483
fix: metagen & workflow
luckasRanarison Nov 17, 2024
af25ea4
fix: pre-commit
luckasRanarison Nov 17, 2024
63afdea
fix: docker build
luckasRanarison Nov 18, 2024
055bbcd
fix: some parts
luckasRanarison Nov 20, 2024
af5a9b2
fix: dockerfile
luckasRanarison Nov 20, 2024
95e5d45
Merge branch 'main' into feat/typegraph-ng
luckasRanarison Nov 25, 2024
aea1bca
fix: remove logger
luckasRanarison Nov 25, 2024
3ac927e
Merge branch 'main' into feat/typegraph-ng
luckasRanarison Dec 3, 2024
fbb7287
fix: metagen test
luckasRanarison Dec 3, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
127 changes: 81 additions & 46 deletions .ghjk/lock.json
Original file line number Diff line number Diff line change
Expand Up @@ -902,30 +902,22 @@
],
"allowedBuildDeps": "bciqek3tmrhm4iohl6tvdzlhxwhv7b52makvvgehltxv52d3l7rbki3y"
},
"ghjkEnvProvInstSet_______task_env_build-tgraph-core": {
"ghjkEnvProvInstSet_______task_env_build-tgraph-py": {
"installs": [
"bciqfjvqemdy7d6axvwkywcm6v66wogddvk7k6e6rps4e6zidkjvm4fy",
"bciqlubbahrp4pxohyffmn5yj52atjgmn5nxepmkdev6wtmvpbx7kr7y",
"bciqminqcmgw3fbbhibwc7tf6mrupttheic7kpiykadbowqmnzhmzo5a",
"bciqojan3zglnfctnmqyxvnxaha46yrnlhj77j3kw4mxadvauqepqdba",
"bciqcnbruy2q6trpvia52n2yis4t27taoz4mxkeguqz5aif7ex6rp26y",
"bciqpu7gxs3zm7i4gwp3m3cfdxwz27ixvsykdnbxrl5m5mt3xbb3b4la",
"bciqjme7csfq43oenkrsakdhaha34hgy6vdwkfffki2ank3kf6mjcguq"
"bciqfpjzi6gguk7dafyicfjpzpwtybgyc2dsnxg2zxkcmyinzy7abpla",
"bciqkgncxbauys2qfguplxcz2auxrcyamj4b6htqk2fqvohfm3afd7sa",
"bciqihcmo6l5uwzih3e3ujc55curep4arfomo6rzkdsfim74unxexiqy"
],
"allowedBuildDeps": "bciqek3tmrhm4iohl6tvdzlhxwhv7b52makvvgehltxv52d3l7rbki3y"
},
"ghjkEnvProvInstSet_______task_env_build-tgraph-py": {
"ghjkEnvProvInstSet_______task_env_build-tgraph-rpc": {
"installs": [
"bciqfjvqemdy7d6axvwkywcm6v66wogddvk7k6e6rps4e6zidkjvm4fy",
"bciqlubbahrp4pxohyffmn5yj52atjgmn5nxepmkdev6wtmvpbx7kr7y",
"bciqminqcmgw3fbbhibwc7tf6mrupttheic7kpiykadbowqmnzhmzo5a",
"bciqojan3zglnfctnmqyxvnxaha46yrnlhj77j3kw4mxadvauqepqdba",
"bciqcnbruy2q6trpvia52n2yis4t27taoz4mxkeguqz5aif7ex6rp26y",
"bciqpu7gxs3zm7i4gwp3m3cfdxwz27ixvsykdnbxrl5m5mt3xbb3b4la",
"bciqjme7csfq43oenkrsakdhaha34hgy6vdwkfffki2ank3kf6mjcguq",
"bciqfpjzi6gguk7dafyicfjpzpwtybgyc2dsnxg2zxkcmyinzy7abpla",
"bciqkgncxbauys2qfguplxcz2auxrcyamj4b6htqk2fqvohfm3afd7sa",
"bciqihcmo6l5uwzih3e3ujc55curep4arfomo6rzkdsfim74unxexiqy"
"bciqminqcmgw3fbbhibwc7tf6mrupttheic7kpiykadbowqmnzhmzo5a"
],
"allowedBuildDeps": "bciqek3tmrhm4iohl6tvdzlhxwhv7b52makvvgehltxv52d3l7rbki3y"
},
Expand All @@ -934,10 +926,6 @@
"bciqfjvqemdy7d6axvwkywcm6v66wogddvk7k6e6rps4e6zidkjvm4fy",
"bciqlubbahrp4pxohyffmn5yj52atjgmn5nxepmkdev6wtmvpbx7kr7y",
"bciqminqcmgw3fbbhibwc7tf6mrupttheic7kpiykadbowqmnzhmzo5a",
"bciqojan3zglnfctnmqyxvnxaha46yrnlhj77j3kw4mxadvauqepqdba",
"bciqcnbruy2q6trpvia52n2yis4t27taoz4mxkeguqz5aif7ex6rp26y",
"bciqpu7gxs3zm7i4gwp3m3cfdxwz27ixvsykdnbxrl5m5mt3xbb3b4la",
"bciqjme7csfq43oenkrsakdhaha34hgy6vdwkfffki2ank3kf6mjcguq",
"bciqezep4ufkgwesldlm5etyfkgdsiickfudx7cosydcz6xtgeorn2hy",
"bciqaixkkacuuligsvtjcfdfgjgl65owtyspiiljb3vmutlgymecsiwq",
"bciqlt27ioikxnpkqq37hma7ibn5e5wpzfarbvoh77zwdkarwghtvzxa"
Expand Down Expand Up @@ -985,6 +973,12 @@
"desc": "Print $METATYPE_VERSION",
"envKey": "bciqkxvhlk6wifuxken6emvhj2cki7tw5ygccar6qq4vbartg776akqa"
},
"test-codegen": {
"ty": "denoFile@v1",
"key": "test-codegen",
"workingDir": "./src/typegraph/specs/codegen",
"envKey": "bciqbjavwy7rbire3zwlpgo2ifwzgnm6ywxqswnh6qxezwuvc4bqhrca"
},
"test-rust": {
"ty": "denoFile@v1",
"key": "test-rust",
Expand Down Expand Up @@ -1132,44 +1126,45 @@
"desc": "Execute tools/*.ts scripts.",
"envKey": "bciqkxvhlk6wifuxken6emvhj2cki7tw5ygccar6qq4vbartg776akqa"
},
"build-tgraph-py": {
"ty": "denoFile@v1",
"key": "build-tgraph-py",
"envKey": "bciqbk2kwzvfc2c5ti6x7z2pju22i3qkhn76hei4patfnwqv6xr4umlq"
},
"build-tgraph-ts-jsr": {
"ty": "denoFile@v1",
"key": "build-tgraph-ts-jsr",
"envKey": "bciqkxvhlk6wifuxken6emvhj2cki7tw5ygccar6qq4vbartg776akqa"
},
"build-tgraph-core": {
"ty": "denoFile@v1",
"key": "build-tgraph-core",
"envKey": "bciqkazb54zk6wdbxpizobukdsz5ruxrtlkf6bfwvctdiwzq6lz7unsq"
},
"build-tgraph-py": {
"build-tgraph-rpc": {
"ty": "denoFile@v1",
"key": "build-tgraph-py",
"dependsOn": [
"build-tgraph-core"
],
"envKey": "bciqly23hzeass3kah6rgds4wyqenzsrcmtru7nsvht7t23dsjvgynyi"
"key": "build-tgraph-rpc",
"envKey": "bciqeeh6cx5grefrnieyki54emcwuxb57ahioapdi6opi47dyg6hxgki"
},
"build-tgraph-ts": {
"ty": "denoFile@v1",
"key": "build-tgraph-ts",
"dependsOn": [
"build-tgraph-core"
],
"envKey": "bciqasv6wmp2sicgg5dbbjxiv5ojm3t3ga3e75y5igacjq4zureobu6q"
"envKey": "bciqpj74st4da74tgeqyzsppxpvncbekb65n2ow6tbcsfdcrdyq6smxy"
},
"build-tgraph-ts-node": {
"ty": "denoFile@v1",
"key": "build-tgraph-ts-node",
"dependsOn": [
"build-tgraph-ts"
],
"envKey": "bciqasv6wmp2sicgg5dbbjxiv5ojm3t3ga3e75y5igacjq4zureobu6q"
"envKey": "bciqpj74st4da74tgeqyzsppxpvncbekb65n2ow6tbcsfdcrdyq6smxy"
},
"build-tgraph-core": {
"ty": "denoFile@v1",
"key": "build-tgraph-core",
"envKey": "bciqlndcuvoua6nwkocqwfmugmbzrpk5yfr5wfv7mzazugh3ofyptv2a"
},
"build-tgraph": {
"ty": "denoFile@v1",
"key": "build-tgraph",
"dependsOn": [
"build-tgraph-core",
"build-tgraph-rpc",
"build-tgraph-py",
"build-tgraph-ts-node"
],
Expand All @@ -1186,6 +1181,7 @@
"clean-rust",
"version-bump",
"version-print",
"test-codegen",
"test-rust",
"test-website",
"test-e2e",
Expand All @@ -1211,11 +1207,12 @@
"dev-eg-tgraphs",
"dev-compose",
"dev",
"build-tgraph-ts-jsr",
"build-tgraph-core",
"build-tgraph-py",
"build-tgraph-ts-jsr",
"build-tgraph-rpc",
"build-tgraph-ts",
"build-tgraph-ts-node",
"build-tgraph-core",
"build-tgraph",
"build-sys-tgraphs"
]
Expand Down Expand Up @@ -1765,7 +1762,7 @@
}
]
},
"bciqkazb54zk6wdbxpizobukdsz5ruxrtlkf6bfwvctdiwzq6lz7unsq": {
"bciqlndcuvoua6nwkocqwfmugmbzrpk5yfr5wfv7mzazugh3ofyptv2a": {
"provides": [
{
"ty": "posix.envVar",
Expand Down Expand Up @@ -1794,16 +1791,16 @@
},
{
"ty": "posix.envVar",
"key": "WASM_FILE",
"val": "target/wasm/release/typegraph_core.wasm"
"key": "TG_CODEGEN",
"val": "src/typegraph/specs/codegen/tg-codegen"
},
{
"ty": "ghjk.ports.InstallSetRef",
"setId": "ghjkEnvProvInstSet_______task_env_build-tgraph-core"
"setId": "ghjkEnvProvInstSet____rust"
}
]
},
"bciqly23hzeass3kah6rgds4wyqenzsrcmtru7nsvht7t23dsjvgynyi": {
"bciqbk2kwzvfc2c5ti6x7z2pju22i3qkhn76hei4patfnwqv6xr4umlq": {
"provides": [
{
"ty": "posix.envVar",
Expand Down Expand Up @@ -1832,16 +1829,54 @@
},
{
"ty": "posix.envVar",
"key": "WASM_FILE",
"val": "target/wasm/release/typegraph_core.wasm"
"key": "TG_CODEGEN",
"val": "src/typegraph/specs/codegen/tg-codegen"
},
{
"ty": "ghjk.ports.InstallSetRef",
"setId": "ghjkEnvProvInstSet_______task_env_build-tgraph-py"
}
]
},
"bciqasv6wmp2sicgg5dbbjxiv5ojm3t3ga3e75y5igacjq4zureobu6q": {
"bciqeeh6cx5grefrnieyki54emcwuxb57ahioapdi6opi47dyg6hxgki": {
"provides": [
{
"ty": "posix.envVar",
"key": "RUST_LOG",
"val": "info,typegate=debug,deno=warn,swc_ecma_codegen=off,tracing::span=off,quaint=off"
},
{
"ty": "posix.envVar",
"key": "TYPEGRAPH_VERSION",
"val": "0.0.3"
},
{
"ty": "posix.envVar",
"key": "CLICOLOR_FORCE",
"val": "1"
},
{
"ty": "posix.envVar",
"key": "CROSS_CONFIG",
"val": "tools/Cross.toml"
},
{
"ty": "posix.envVar",
"key": "GIT_CLIFF_CONFIG",
"val": "tools/cliff.toml"
},
{
"ty": "posix.envVar",
"key": "TG_CODEGEN",
"val": "src/typegraph/specs/codegen/tg-codegen"
},
{
"ty": "ghjk.ports.InstallSetRef",
"setId": "ghjkEnvProvInstSet_______task_env_build-tgraph-rpc"
}
]
},
"bciqpj74st4da74tgeqyzsppxpvncbekb65n2ow6tbcsfdcrdyq6smxy": {
"provides": [
{
"ty": "posix.envVar",
Expand Down Expand Up @@ -1870,8 +1905,8 @@
},
{
"ty": "posix.envVar",
"key": "WASM_FILE",
"val": "target/wasm/release/typegraph_core.wasm"
"key": "TG_CODEGEN",
"val": "src/typegraph/specs/codegen/tg-codegen"
},
{
"ty": "ghjk.ports.InstallSetRef",
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -280,19 +280,20 @@ jobs:
source .venv/bin/activate

# this doesn't publish it but only builds it
WASM_OPT=1 ghjk x build-tgraph-ts
ghjk x build-tgraph-ts

# start the docker containers
ghjk x dev-compose base prisma grpc subredis

WASM_OPT=1 ghjk x build-tgraph
ghjk x build-tgraph

ghjk x install-ts

ghjk x fetch-deno
ghjk x dev update --cache-only

ghjk x test-rust
ghjk x test-codegen

ghjk x test-e2e -- --coverage=coverage

Expand Down
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ src/meta-lsp/*.vsix
src/typegate/workers
src/typegate/codegen

tests/prisma-migrations
tests/e2e/cli/prisma-migrations
tests/importers/copy/
tests/**/*.wasm
Expand Down
2 changes: 1 addition & 1 deletion Cargo.lock

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

5 changes: 1 addition & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ substantial = { path = "src/substantial/" }
metagen = { path = "src/metagen/" }
metagen-client = { path = "src/metagen-client-rs" }
typegate_engine = { path = "src/typegate/engine" }
typegraph_core = { path = "src/typegraph/core" }

# cli
clap = "=4.5.13"
Expand Down Expand Up @@ -74,7 +75,6 @@ seahash = "4.1.0"
# patterns
anyhow = "1.0.89" # FIXME: replace anyhow with eyre
color-eyre = "0.6.3"
eyre = "0.6.12" # NOTE: keep in sync with verison used by color-eyre
thiserror = "1.0.64"
indoc = "2.0.5"
unindent = "0.2.3"
Expand Down Expand Up @@ -128,7 +128,6 @@ uuid = "1.10.0"
# wasm
wasmtime = "25.0.2"
wasmtime-wasi = "25.0.2"
wit-bindgen = "0.34.0"

# deno
# deno = { path = "../deno/cli" }
Expand All @@ -149,8 +148,6 @@ tracing-subscriber = { version = "0.3.18", features = [
tracing-error = "0.2"
# `unwrap` that also logs
tracing-unwrap = { version = "1.0.1", features = ["log-location"] }
# collect traces to file
tracing-appender = "0.2.3"

# async
futures = "=0.3.30" # pinned due to bug with .31 with zeromq (deno)
Expand Down
1 change: 1 addition & 0 deletions deno.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
"./src/typegate/", // need special lint rules
"./tests", // needs special lint rules
"./src/typegraph/deno", // needed for publishing
"./src/typegraph/specs/codegen", // needed for running scripts
"./examples/" // needed for published_test
]
},
Expand Down
Loading
Loading