dirsql 0.3.22__tar.gz → 0.3.23__tar.gz
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.
- {dirsql-0.3.22 → dirsql-0.3.23}/Cargo.lock +1 -1
- {dirsql-0.3.22 → dirsql-0.3.23}/PKG-INFO +1 -1
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/_async_test.py +19 -19
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/binary_path_test.py +1 -1
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/main_test.py +13 -16
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/Cargo.toml +1 -1
- {dirsql-0.3.22 → dirsql-0.3.23}/Cargo.toml +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/README.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/__init__.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/_async.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/_dirsql.pyi +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/__init__.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/binary_path.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/interpret/__init__.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/interpret/dispatch_extract.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/interpret/dispatch_extract_test.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/interpret/load_app.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/interpret/load_app_test.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/interpret/run.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/interpret/run_test.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/interpret/write_message.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/interpret/write_message_test.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/is_windows.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/is_windows_test.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/cli/main.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/py.typed +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/resolve_config.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/dirsql/resolve_config_test.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/.claude/CLAUDE.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/.vitepress/config.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/.vitepress/theme/index.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/.vitepress/theme/lang.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/AGENTS.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/api/index.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/cli/config.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/cli/http-api.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/cli/index.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/cli/init.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/cli/server.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/getting-started.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/guide/async.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/guide/crdt.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/guide/persistence.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/guide/querying.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/guide/tables.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/guide/watching.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/index.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/migrations.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/package.json +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/playwright.config.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/pnpm-lock.yaml +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/pnpm-workspace.yaml +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/tests/integration/home.spec.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/tests/integration/language-flag.spec.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/tests/unit/config.test.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/tests/unit/lang.test.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/docs/vitest.config.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/README.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/conftest.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/.claude/CLAUDE.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/.vitepress/config.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/.vitepress/theme/index.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/.vitepress/theme/lang.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/AGENTS.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/api/index.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/cli/config.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/cli/http-api.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/cli/index.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/cli/init.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/cli/server.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/getting-started.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/guide/async.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/guide/crdt.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/guide/persistence.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/guide/querying.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/guide/tables.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/guide/watching.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/index.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/migrations.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/package.json +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/playwright.config.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/pnpm-lock.yaml +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/pnpm-workspace.yaml +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/tests/integration/home.spec.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/tests/integration/language-flag.spec.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/tests/unit/config.test.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/tests/unit/lang.test.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/vitest.config.ts +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/src/lib.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/__init__.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/conftest.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/e2e/__init__.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/__fixtures__/data/a/meta.json +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/__fixtures__/data/b/meta.json +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/__fixtures__/dirsql.config.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/__fixtures__/interpret/data/a/meta.json +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/__fixtures__/interpret/data/b/meta.json +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/__fixtures__/interpret/dirsql.config.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/__fixtures__/interpret/dirsql.config_no_app.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/__fixtures__/interpret/dirsql.config_raises.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/__init__.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/interpret_subprocess.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/test_async_dirsql.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/test_binding.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/test_dirsql.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/test_docs_examples.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/test_docs_gaps.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/test_from_config.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/test_interpret.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/test_native_config.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/test_persist.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/test_serialization.py +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/Cargo.toml +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/README.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/benches/db_bench.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/benches/differ_bench.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/benches/matcher_bench.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/benches/scanner_bench.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/api/index.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/cli/config.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/cli/http-api.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/cli/index.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/cli/init.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/cli/server.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/getting-started.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/guide/async.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/guide/crdt.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/guide/persistence.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/guide/querying.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/guide/tables.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/guide/watching.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/index.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/docs/migrations.md +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/bin/dirsql.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/cli/init.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/cli/mod.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/cli/native_config.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/cli/router.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/cli/serialize.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/cli/server.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/config.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/db.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/differ.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/lib.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/matcher.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/persist.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/scanner.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/src/watcher.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/async_sdk.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/cli_e2e.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/cli_integration.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/code_review_findings.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/docs_examples.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/docs_gaps.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/extensions.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/from_config.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/init_e2e.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/init_integration.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/persist.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/readonly_query.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/sdk.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/packages/rust/tests/serialization.rs +0 -0
- {dirsql-0.3.22 → dirsql-0.3.23}/pyproject.toml +0 -0
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"""Unit tests for the DirSQL async wrapper."""
|
|
2
2
|
|
|
3
|
-
from
|
|
3
|
+
from unittest.mock import patch
|
|
4
4
|
|
|
5
5
|
import pytest
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
import dirsql._async as async_mod
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
class _FakeRustDirSQL:
|
|
@@ -50,32 +50,32 @@ class _FakeWatcherDb:
|
|
|
50
50
|
def describe_DirSQL_async():
|
|
51
51
|
def describe_ready_and_query():
|
|
52
52
|
@pytest.mark.asyncio
|
|
53
|
-
async def it_uses_the_background_db(
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
53
|
+
async def it_uses_the_background_db():
|
|
54
|
+
with patch.object(async_mod, "_RustDirSQL", _FakeRustDirSQL):
|
|
55
|
+
db = async_mod.DirSQL(
|
|
56
|
+
"/tmp/root", tables=["table-a"], ignore=["**/*.tmp"]
|
|
57
|
+
)
|
|
58
|
+
await db.ready()
|
|
58
59
|
|
|
59
|
-
|
|
60
|
+
results = await db.query("SELECT 1")
|
|
60
61
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
62
|
+
assert db._db.root == "/tmp/root"
|
|
63
|
+
assert db._db.tables == ["table-a"]
|
|
64
|
+
assert db._db.ignore == ["**/*.tmp"]
|
|
65
|
+
assert db._db.query_calls == ["SELECT 1"]
|
|
66
|
+
assert results == [{"sql": "SELECT 1"}]
|
|
66
67
|
|
|
67
68
|
@pytest.mark.asyncio
|
|
68
|
-
async def it_propagates_initialization_errors(
|
|
69
|
+
async def it_propagates_initialization_errors():
|
|
69
70
|
class _BoomDirSQL:
|
|
70
71
|
def __init__(self, *args, **kwargs):
|
|
71
72
|
raise RuntimeError("boom")
|
|
72
73
|
|
|
73
|
-
|
|
74
|
+
with patch.object(async_mod, "_RustDirSQL", _BoomDirSQL):
|
|
75
|
+
db = async_mod.DirSQL("/tmp/root", tables=["table-a"])
|
|
74
76
|
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
with pytest.raises(RuntimeError, match="boom"):
|
|
78
|
-
await db.ready()
|
|
77
|
+
with pytest.raises(RuntimeError, match="boom"):
|
|
78
|
+
await db.ready()
|
|
79
79
|
|
|
80
80
|
def describe_watch_stream():
|
|
81
81
|
@pytest.mark.asyncio
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
import io
|
|
4
4
|
import os
|
|
5
|
-
import subprocess
|
|
6
5
|
import sys
|
|
7
6
|
from unittest.mock import patch
|
|
8
7
|
|
|
@@ -35,7 +34,9 @@ def describe_main():
|
|
|
35
34
|
with (
|
|
36
35
|
patch.object(main_module, "binary_path", return_value="C:/dirsql.exe"),
|
|
37
36
|
patch.object(main_module, "is_windows", return_value=True),
|
|
38
|
-
patch
|
|
37
|
+
patch(
|
|
38
|
+
"dirsql.cli.main.subprocess.run", return_value=_Completed(7)
|
|
39
|
+
) as run,
|
|
39
40
|
):
|
|
40
41
|
assert main(["--version"]) == 7
|
|
41
42
|
run.assert_called_once_with(["C:/dirsql.exe", "--version"])
|
|
@@ -44,7 +45,7 @@ def describe_main():
|
|
|
44
45
|
with (
|
|
45
46
|
patch.object(main_module, "binary_path", return_value="C:/dirsql.exe"),
|
|
46
47
|
patch.object(main_module, "is_windows", return_value=True),
|
|
47
|
-
patch.
|
|
48
|
+
patch("dirsql.cli.main.subprocess.run", return_value=_Completed(0)),
|
|
48
49
|
patch.object(os, "execv") as execv,
|
|
49
50
|
):
|
|
50
51
|
main([])
|
|
@@ -81,7 +82,9 @@ def describe_main():
|
|
|
81
82
|
patch.object(sys, "argv", ["dirsql", "--help"]),
|
|
82
83
|
patch.object(main_module, "binary_path", return_value="C:/dirsql.exe"),
|
|
83
84
|
patch.object(main_module, "is_windows", return_value=True),
|
|
84
|
-
patch
|
|
85
|
+
patch(
|
|
86
|
+
"dirsql.cli.main.subprocess.run", return_value=_Completed(0)
|
|
87
|
+
) as run,
|
|
85
88
|
):
|
|
86
89
|
main(argv=None)
|
|
87
90
|
run.assert_called_once_with(["C:/dirsql.exe", "--help"])
|
|
@@ -93,12 +96,10 @@ def describe_main():
|
|
|
93
96
|
|
|
94
97
|
def it_dispatches_to_interpret_run_and_returns_its_exit_code():
|
|
95
98
|
# main.py does `from .interpret.run import run` lazily, so
|
|
96
|
-
# patching the `run` function on
|
|
97
|
-
# -- each call resolves the name freshly
|
|
98
|
-
from .interpret import run as run_submod
|
|
99
|
-
|
|
99
|
+
# patching the `run` function on its module by its dotted path
|
|
100
|
+
# is sufficient -- each call resolves the name freshly.
|
|
100
101
|
with (
|
|
101
|
-
patch
|
|
102
|
+
patch("dirsql.cli.interpret.run.run", return_value=0) as interpret_run,
|
|
102
103
|
patch.object(main_module, "binary_path") as binary_path,
|
|
103
104
|
):
|
|
104
105
|
assert main(["interpret", "config.py"]) == 0
|
|
@@ -106,15 +107,11 @@ def describe_main():
|
|
|
106
107
|
binary_path.assert_not_called()
|
|
107
108
|
|
|
108
109
|
def it_propagates_a_nonzero_interpret_exit():
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
with patch.object(run_submod, "run", return_value=2):
|
|
110
|
+
with patch("dirsql.cli.interpret.run.run", return_value=2):
|
|
112
111
|
assert main(["interpret", "bad.py"]) == 2
|
|
113
112
|
|
|
114
113
|
def it_returns_130_on_keyboard_interrupt():
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
with patch.object(run_submod, "run", side_effect=KeyboardInterrupt()):
|
|
114
|
+
with patch("dirsql.cli.interpret.run.run", side_effect=KeyboardInterrupt()):
|
|
118
115
|
assert main(["interpret", "config.py"]) == 130
|
|
119
116
|
|
|
120
117
|
def it_does_not_intercept_when_interpret_is_not_argv_0():
|
|
@@ -123,7 +120,7 @@ def describe_main():
|
|
|
123
120
|
with (
|
|
124
121
|
patch.object(main_module, "binary_path", return_value="/bin/dirsql"),
|
|
125
122
|
patch.object(main_module, "is_windows", return_value=True),
|
|
126
|
-
patch.
|
|
123
|
+
patch("dirsql.cli.main.subprocess.run", return_value=_Completed(0)),
|
|
127
124
|
):
|
|
128
125
|
main(["--verbose", "interpret", "config.py"])
|
|
129
126
|
# binary_path was reached, meaning we did NOT take the
|
|
@@ -4,7 +4,7 @@ name = "dirsql-py-ext"
|
|
|
4
4
|
# pypi/maturin handler can rewrite it via `write-version` before
|
|
5
5
|
# `maturin build`. `pyproject.toml` declares `dynamic = ["version"]`
|
|
6
6
|
# and maturin reads this field. Mirrors `packages/rust/Cargo.toml`.
|
|
7
|
-
version = "0.3.
|
|
7
|
+
version = "0.3.23"
|
|
8
8
|
edition.workspace = true
|
|
9
9
|
publish = false
|
|
10
10
|
readme = "README.md"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{dirsql-0.3.22 → dirsql-0.3.23}/packages/python/docs/tests/integration/language-flag.spec.ts
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/__fixtures__/data/a/meta.json
RENAMED
|
File without changes
|
{dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/__fixtures__/data/b/meta.json
RENAMED
|
File without changes
|
{dirsql-0.3.22 → dirsql-0.3.23}/packages/python/tests/integration/__fixtures__/dirsql.config.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|