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(mdk): mdk python #707

Merged
merged 5 commits into from
May 22, 2024
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
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
9 changes: 3 additions & 6 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,12 +76,9 @@ jobs:
run: |
sudo apt update
sudo apt install -y --no-install-recommends libclang-dev clang
cd website
pnpm install --frozen-lockfile
cd ..
cd meta-lsp
pnpm install --frozen-lockfile --recursive
cd ..
pnpm -C website install --frozen-lockfile
pnpm -C meta-lsp install --frozen-lockfile --recursive
pnpm -C typegraph/node install --frozen-lockfile --recursive
deno cache --import-map typegate/import_map.json typegate/src/main.ts typegate/tests/utils/mod.ts
pre-commit run --show-diff-on-failure --color=always --all-files

Expand Down
12 changes: 11 additions & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,17 @@ repos:
- ts
files: ^(typegate|dev)/
- id: es-lint
name: Eslint
name: Eslint typegraph
language: system
entry: bash -c 'cd typegraph/node/sdk && [ -f node_modules/.bin/eslint ] && pnpm eslint'
pass_filenames: false
types_or:
- ts
- tsx
files: ^typegraph/node/sdk
exclude: node_modules
- id: es-lint
name: Eslint website
language: system
entry: bash -c 'cd website && [ -f node_modules/.bin/eslint ] && pnpm lint'
pass_filenames: false
Expand Down
88 changes: 51 additions & 37 deletions Cargo.lock

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

2 changes: 1 addition & 1 deletion examples/deploy/deploy.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ const tg = await typegraph({
},
),
// Wasm
testWasmAdd: wasm.fromWasm(
testWasmAdd: wasm.fromExport(
t.struct({ a: t.float(), b: t.float() }),
t.integer(),
{ wasm: "wasm/rust.wasm", func: "add" },
Expand Down
2 changes: 1 addition & 1 deletion examples/deploy/deploy.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ def deploy_example_python(g: Graph):
name="sayHello",
),
# Wasm
testWasmAdd=wasm.from_wasm(
testWasmAdd=wasm.from_export(
t.struct({"a": t.float(), "b": t.float()}),
t.integer(),
func="add",
Expand Down
4 changes: 0 additions & 4 deletions libs/common/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ anyhow.workspace = true
base64 = "0.21.5"
flate2 = "1.0.28"
indexmap.workspace = true
schemars = { version = "0.8.16", features = ["derive", "preserve_order"], optional = true }
serde.workspace = true
serde_json = { workspace = true, features = ["preserve_order"] }
serde_with = "3.4.0"
Expand All @@ -20,6 +19,3 @@ itertools = "0.11.0"
colored = "2.0.4"
indoc.workspace = true
thiserror.workspace = true

[features]
codegen = ["dep:schemars"]
8 changes: 6 additions & 2 deletions libs/metagen/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ common.workspace = true
log.workspace = true
serde.workspace = true
serde_json.workspace = true
tokio = { workspace = true, features =["rt-multi-thread"]}
tokio = { workspace = true, features =["rt-multi-thread"], optional = true }
indexmap.workspace = true
reqwest = { workspace = true, features = ["json"] }
garde = { version = "0.18", features = ["derive"] }
Expand All @@ -18,7 +18,11 @@ once_cell.workspace = true
pretty_assertions = "1.4.0"
color-eyre.workspace = true
# indoc.workspace = true
tera = { version = "1", default-features = false }
michael-0acf4 marked this conversation as resolved.
Show resolved Hide resolved

[dev-dependencies]
tokio = { workspace = true, features =["full"]}
tokio = { workspace = true, features =["full"] }
tempfile.workspace = true

[features]
multithreaded = ["dep:tokio"]
Loading
Loading