sqlctx 0.1.6__tar.gz → 0.14.0__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.
- sqlctx-0.14.0/.agents/plugins/marketplace.json +20 -0
- sqlctx-0.14.0/.bun-version +1 -0
- sqlctx-0.14.0/.claude-plugin/marketplace.json +14 -0
- sqlctx-0.14.0/.dockerignore +26 -0
- sqlctx-0.14.0/.gitignore +63 -0
- sqlctx-0.14.0/AGENTS.md +133 -0
- sqlctx-0.14.0/CLAUDE.md +1 -0
- sqlctx-0.14.0/CONTRIBUTING.md +27 -0
- sqlctx-0.14.0/Cargo.lock +3511 -0
- sqlctx-0.14.0/Cargo.toml +18 -0
- sqlctx-0.14.0/Dockerfile +67 -0
- {sqlctx-0.1.6 → sqlctx-0.14.0}/LICENSE +67 -80
- sqlctx-0.14.0/PKG-INFO +1249 -0
- sqlctx-0.14.0/README.md +452 -0
- sqlctx-0.14.0/SECURITY.md +3 -0
- sqlctx-0.14.0/crates/dax-parser/Cargo.toml +10 -0
- sqlctx-0.14.0/crates/dax-parser/src/builtin_functions.txt +352 -0
- sqlctx-0.14.0/crates/dax-parser/src/formatter.rs +825 -0
- sqlctx-0.14.0/crates/dax-parser/src/function_catalog.rs +4556 -0
- sqlctx-0.14.0/crates/dax-parser/src/lib.rs +3791 -0
- sqlctx-0.14.0/crates/dax-parser/src/model_validation.rs +1062 -0
- sqlctx-0.14.0/crates/dax-parser/src/recovery.rs +418 -0
- sqlctx-0.14.0/crates/dax-parser/src/validation.rs +1470 -0
- sqlctx-0.14.0/crates/dax-parser/tests/corpus.rs +95 -0
- sqlctx-0.14.0/crates/dax-parser/tests/corpus_errors.rs +40 -0
- sqlctx-0.14.0/crates/dax-parser/tests/corpus_functions.rs +40 -0
- sqlctx-0.14.0/crates/dax-parser/tests/corpus_queries.rs +59 -0
- sqlctx-0.14.0/crates/dax-pyo3/Cargo.toml +18 -0
- sqlctx-0.14.0/crates/dax-pyo3/README.md +34 -0
- sqlctx-0.14.0/crates/dax-pyo3/pyproject.toml +37 -0
- sqlctx-0.14.0/crates/dax-pyo3/python/sqlctx_dax/__init__.py +263 -0
- sqlctx-0.14.0/crates/dax-pyo3/python/sqlctx_dax/ast.py +1364 -0
- sqlctx-0.14.0/crates/dax-pyo3/python/sqlctx_dax/py.typed +0 -0
- sqlctx-0.14.0/crates/dax-pyo3/src/lib.rs +575 -0
- sqlctx-0.14.0/docker-entrypoint.sh +155 -0
- sqlctx-0.14.0/examples/adbc_snowflake/.gitignore +3 -0
- sqlctx-0.14.0/examples/adbc_snowflake/README.md +122 -0
- sqlctx-0.14.0/examples/adbc_snowflake/orders.yaml +41 -0
- sqlctx-0.14.0/examples/adbc_snowflake/setup.sql +45 -0
- sqlctx-0.14.0/examples/adbc_snowflake/sqlctx.yaml.example +11 -0
- sqlctx-0.14.0/examples/advanced/comprehensive_demo.py +326 -0
- sqlctx-0.14.0/examples/advanced/comprehensive_example.py +376 -0
- sqlctx-0.14.0/examples/basic/basic_example.py +123 -0
- sqlctx-0.14.0/examples/basic/simplified_api_example.py +69 -0
- sqlctx-0.14.0/examples/bsl/customers.yml +26 -0
- sqlctx-0.14.0/examples/cloudflare_containers/.gitignore +4 -0
- sqlctx-0.14.0/examples/cloudflare_containers/Dockerfile +10 -0
- sqlctx-0.14.0/examples/cloudflare_containers/README.md +98 -0
- sqlctx-0.14.0/examples/cloudflare_containers/bun.lock +202 -0
- sqlctx-0.14.0/examples/cloudflare_containers/src/index.ts +57 -0
- sqlctx-0.14.0/examples/cloudflare_containers/tsconfig.json +18 -0
- sqlctx-0.14.0/examples/cloudflare_containers/wrangler.jsonc +32 -0
- sqlctx-0.14.0/examples/cube_demo/.gitignore +1 -0
- sqlctx-0.14.0/examples/cube_demo/Dockerfile +7 -0
- sqlctx-0.14.0/examples/cube_demo/run_demo.py +313 -0
- sqlctx-0.14.0/examples/cube_demo/sqlctx.yaml +137 -0
- sqlctx-0.14.0/examples/docker/README.md +173 -0
- sqlctx-0.14.0/examples/docker/docker-compose.yml +71 -0
- sqlctx-0.14.0/examples/ecommerce/README.md +133 -0
- sqlctx-0.14.0/examples/ecommerce/data/create_db.py +222 -0
- sqlctx-0.14.0/examples/ecommerce/data/ecommerce.db +0 -0
- sqlctx-0.14.0/examples/ecommerce/models/customers.yml +70 -0
- sqlctx-0.14.0/examples/ecommerce/models/metrics.yml +38 -0
- sqlctx-0.14.0/examples/ecommerce/models/order_items.sql +95 -0
- sqlctx-0.14.0/examples/ecommerce/models/orders.yml +87 -0
- sqlctx-0.14.0/examples/ecommerce/models/products.sql +79 -0
- sqlctx-0.14.0/examples/features/cross_model_metrics_example.py +144 -0
- sqlctx-0.14.0/examples/features/multi_hop_joins_example.py +128 -0
- sqlctx-0.14.0/examples/features/parameters_example.py +135 -0
- sqlctx-0.14.0/examples/features/symmetric_aggregates_example.py +230 -0
- sqlctx-0.14.0/examples/headless_dashboard/.gitignore +3 -0
- sqlctx-0.14.0/examples/headless_dashboard/README.md +42 -0
- sqlctx-0.14.0/examples/headless_dashboard/dashboard.ts +58 -0
- sqlctx-0.14.0/examples/headless_dashboard/dashboard.yml +46 -0
- sqlctx-0.14.0/examples/headless_dashboard/models.yml +41 -0
- sqlctx-0.14.0/examples/headless_dashboard/queries.ts +46 -0
- sqlctx-0.14.0/examples/headless_dashboard/setup_data.py +83 -0
- sqlctx-0.14.0/examples/headless_dashboard/sqlctx.client.generated.ts +57 -0
- sqlctx-0.14.0/examples/headless_dashboard/sqlctx.generated.ts +246 -0
- sqlctx-0.14.0/examples/headless_dashboard/sqlctx.queries.generated.ts +16 -0
- sqlctx-0.14.0/examples/headless_dashboard/vite.config.example.ts +26 -0
- sqlctx-0.14.0/examples/hive_parquet/.gitignore +1 -0
- sqlctx-0.14.0/examples/hive_parquet/README.md +147 -0
- sqlctx-0.14.0/examples/hive_parquet/hive_parquet_example.py +207 -0
- sqlctx-0.14.0/examples/hive_parquet/hive_parquet_preagg_example.py +272 -0
- sqlctx-0.14.0/examples/integrations/chart_example.py +162 -0
- sqlctx-0.14.0/examples/integrations/export_example.py +35 -0
- sqlctx-0.14.0/examples/integrations/headless_charting.py +622 -0
- sqlctx-0.14.0/examples/integrations/modal_headless_charting.py +113 -0
- sqlctx-0.14.0/examples/integrations/streamlit_dashboard.py +505 -0
- sqlctx-0.14.0/examples/malloy_demo/README.md +57 -0
- sqlctx-0.14.0/examples/malloy_demo/bun.lock +214 -0
- sqlctx-0.14.0/examples/malloy_demo/lookml_input/customers.lkml +35 -0
- sqlctx-0.14.0/examples/malloy_demo/lookml_input/orders.lkml +72 -0
- sqlctx-0.14.0/examples/malloy_demo/lookml_input/products.lkml +41 -0
- sqlctx-0.14.0/examples/malloy_demo/malloy_output/data/customers.parquet +0 -0
- sqlctx-0.14.0/examples/malloy_demo/malloy_output/data/orders.parquet +0 -0
- sqlctx-0.14.0/examples/malloy_demo/malloy_output/data/products.parquet +0 -0
- sqlctx-0.14.0/examples/malloy_demo/malloy_output/thelook.malloy +101 -0
- sqlctx-0.14.0/examples/malloy_demo/run_demo.py +255 -0
- sqlctx-0.14.0/examples/malloy_demo/validate_malloy.test.ts +210 -0
- sqlctx-0.14.0/examples/migrator/README.md +100 -0
- sqlctx-0.14.0/examples/migrator/generate_from_queries.py +602 -0
- sqlctx-0.14.0/examples/migrator/raw_queries/cancelled_orders.sql +10 -0
- sqlctx-0.14.0/examples/migrator/raw_queries/customer_demographics.sql +9 -0
- sqlctx-0.14.0/examples/migrator/raw_queries/customer_orders.sql +12 -0
- sqlctx-0.14.0/examples/migrator/raw_queries/high_value_orders.sql +11 -0
- sqlctx-0.14.0/examples/migrator/raw_queries/inventory_analysis.sql +10 -0
- sqlctx-0.14.0/examples/migrator/raw_queries/monthly_trends.sql +10 -0
- sqlctx-0.14.0/examples/migrator/raw_queries/product_performance.sql +13 -0
- sqlctx-0.14.0/examples/migrator/raw_queries/revenue_by_status.sql +8 -0
- sqlctx-0.14.0/examples/motherduck/README.md +85 -0
- sqlctx-0.14.0/examples/motherduck/query_examples.py +118 -0
- sqlctx-0.14.0/examples/motherduck/refresh_preaggs.py +76 -0
- sqlctx-0.14.0/examples/motherduck/setup_data.py +89 -0
- sqlctx-0.14.0/examples/motherduck/sqlctx.yaml +57 -0
- sqlctx-0.14.0/examples/multi_format_demo/cube/customers.yml +41 -0
- sqlctx-0.14.0/examples/multi_format_demo/demo_data.py +110 -0
- sqlctx-0.14.0/examples/multi_format_demo/hex/products.yml +65 -0
- sqlctx-0.14.0/examples/multi_format_demo/lookml/orders.lkml +72 -0
- sqlctx-0.14.0/examples/notebooks/lookml_multi_entity_duckdb_demo.ipynb +292 -0
- sqlctx-0.14.0/examples/notebooks/sqlctx_sql_duckdb_demo.ipynb +216 -0
- sqlctx-0.14.0/examples/osi_demo/adtech_semantic_model.yaml +562 -0
- sqlctx-0.14.0/examples/osi_demo/osi_widget_notebook.py +438 -0
- sqlctx-0.14.0/examples/osi_demo/run_demo.py +400 -0
- sqlctx-0.14.0/examples/pre_aggregations/.gitignore +2 -0
- sqlctx-0.14.0/examples/pre_aggregations/README.md +293 -0
- sqlctx-0.14.0/examples/pre_aggregations/demo.sh +60 -0
- sqlctx-0.14.0/examples/pre_aggregations/models/orders.yml +36 -0
- sqlctx-0.14.0/examples/pre_aggregations/query_history.sql +64 -0
- sqlctx-0.14.0/examples/pre_aggregations/setup_data.py +87 -0
- sqlctx-0.14.0/examples/pre_aggregations/sqlctx.yaml +11 -0
- sqlctx-0.14.0/examples/rill_demo/.gitignore +2 -0
- sqlctx-0.14.0/examples/rill_demo/Dockerfile +19 -0
- sqlctx-0.14.0/examples/rill_demo/run_demo.py +125 -0
- sqlctx-0.14.0/examples/rill_demo/sqlctx.yaml +83 -0
- sqlctx-0.14.0/examples/snowflake/ecommerce.yaml +199 -0
- sqlctx-0.14.0/examples/snowflake/simple.yaml +45 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/README.md +51 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/index.html +95 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/scripts/build_wasm.sh +13 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/server.ts +45 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/src/app.js +307 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/src/components/sqlctx/sqlctx-ui-static.js +9520 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/src/components/sqlctx/sqlctx-ui.css +1 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/src/demo/ecommerce.js +172 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/src/queries.js +92 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/src/runtime/duckdb-runtime.js +96 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/src/runtime/sqlctx-runtime.js +31 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/src/styles.css +381 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/typed_client_example.js +41 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/vendor/sqlctx/manifest.json +6 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/vendor/sqlctx/sqlctx.d.ts +307 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/vendor/sqlctx/sqlctx.js +2937 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/vendor/sqlctx/sqlctx_bg.wasm +0 -0
- sqlctx-0.14.0/examples/sqlctx_wasm_demo/vendor/sqlctx/sqlctx_bg.wasm.d.ts +120 -0
- sqlctx-0.14.0/examples/superset_demo/.gitignore +3 -0
- sqlctx-0.14.0/examples/superset_demo/Dockerfile +6 -0
- sqlctx-0.14.0/examples/superset_demo/docker-compose.yml +27 -0
- sqlctx-0.14.0/examples/superset_demo/run_demo.py +492 -0
- sqlctx-0.14.0/examples/superset_demo/sqlctx.yaml +83 -0
- sqlctx-0.14.0/examples/superset_demo/superset_config.py +20 -0
- sqlctx-0.14.0/examples/widget_demo/widget_demo.ipynb +712 -0
- sqlctx-0.14.0/examples/widget_demo/widget_demo.marimo.py +479 -0
- sqlctx-0.14.0/examples/widget_demo/widget_demo_simple.ipynb +309 -0
- sqlctx-0.14.0/examples/yaml/yaml_syntax_example.py +154 -0
- sqlctx-0.14.0/examples/yaml/yaml_syntax_example.yml +68 -0
- sqlctx-0.14.0/js/bun.lock +124 -0
- sqlctx-0.14.0/js/package.json +15 -0
- sqlctx-0.14.0/js/widget.css +514 -0
- sqlctx-0.14.0/js/widget.js +532 -0
- sqlctx-0.14.0/preview.png +0 -0
- sqlctx-0.14.0/pyproject.toml +287 -0
- sqlctx-0.14.0/scripts/audit_engine_exceptions.py +745 -0
- sqlctx-0.14.0/scripts/benchmark_semantic_sql_planner.py +910 -0
- sqlctx-0.14.0/scripts/build_demo_duckdb.py +33 -0
- sqlctx-0.14.0/scripts/build_foursquare_preagg_db.py +179 -0
- sqlctx-0.14.0/scripts/build_ui_distribution.py +95 -0
- sqlctx-0.14.0/scripts/build_webapp.py +72 -0
- sqlctx-0.14.0/scripts/build_widget.py +74 -0
- sqlctx-0.14.0/scripts/check_malloy_grammar_drift.py +86 -0
- sqlctx-0.14.0/scripts/commit_chart.py +61 -0
- sqlctx-0.14.0/scripts/docker_smoke_test.py +260 -0
- sqlctx-0.14.0/scripts/fix_test_fixtures.py +89 -0
- sqlctx-0.14.0/scripts/generate_compatibility_docs.py +173 -0
- sqlctx-0.14.0/scripts/generate_man_page.py +20 -0
- sqlctx-0.14.0/scripts/generate_schema.py +122 -0
- sqlctx-0.14.0/scripts/preagg_recommendation_example.py +127 -0
- sqlctx-0.14.0/scripts/setup-dns.sh +50 -0
- sqlctx-0.14.0/sqlctx/__init__.py +82 -0
- sqlctx-0.14.0/sqlctx/adapters/atscale_sml.py +1569 -0
- sqlctx-0.14.0/sqlctx/adapters/base.py +155 -0
- sqlctx-0.14.0/sqlctx/adapters/bsl.py +815 -0
- sqlctx-0.14.0/sqlctx/adapters/bsl_expr.py +923 -0
- sqlctx-0.14.0/sqlctx/adapters/cube.py +2069 -0
- sqlctx-0.14.0/sqlctx/adapters/gooddata.py +1404 -0
- sqlctx-0.14.0/sqlctx/adapters/graphene.py +1506 -0
- sqlctx-0.14.0/sqlctx/adapters/hex.py +831 -0
- sqlctx-0.14.0/sqlctx/adapters/holistics.py +2432 -0
- sqlctx-0.14.0/sqlctx/adapters/holistics_grammar/HolisticsLexer.g4 +70 -0
- sqlctx-0.14.0/sqlctx/adapters/holistics_grammar/HolisticsLexer.interp +179 -0
- sqlctx-0.14.0/sqlctx/adapters/holistics_grammar/HolisticsLexer.py +270 -0
- sqlctx-0.14.0/sqlctx/adapters/holistics_grammar/HolisticsLexer.tokens +99 -0
- sqlctx-0.14.0/sqlctx/adapters/holistics_grammar/HolisticsParser.g4 +248 -0
- sqlctx-0.14.0/sqlctx/adapters/holistics_grammar/HolisticsParser.interp +164 -0
- sqlctx-0.14.0/sqlctx/adapters/holistics_grammar/HolisticsParser.py +3866 -0
- sqlctx-0.14.0/sqlctx/adapters/holistics_grammar/HolisticsParser.tokens +99 -0
- sqlctx-0.14.0/sqlctx/adapters/holistics_grammar/HolisticsParserListener.py +435 -0
- sqlctx-0.14.0/sqlctx/adapters/holistics_grammar/HolisticsParserVisitor.py +248 -0
- sqlctx-0.14.0/sqlctx/adapters/holistics_grammar/__init__.py +5 -0
- sqlctx-0.14.0/sqlctx/adapters/lookml.py +5279 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy.py +4112 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_expressions.py +977 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/MalloyLexer.g4 +301 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/MalloyLexer.interp +615 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/MalloyLexer.py +1335 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/MalloyLexer.tokens +216 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/MalloyParser.g4 +859 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/MalloyParser.interp +560 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/MalloyParser.py +17819 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/MalloyParser.tokens +216 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/MalloyParserListener.py +2379 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/MalloyParserVisitor.py +1328 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/UPSTREAM.json +30 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/UPSTREAM.md +19 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_grammar/__init__.py +17 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_modules.py +739 -0
- sqlctx-0.14.0/sqlctx/adapters/malloy_queries.py +575 -0
- sqlctx-0.14.0/sqlctx/adapters/metricflow.py +1550 -0
- sqlctx-0.14.0/sqlctx/adapters/official.py +633 -0
- sqlctx-0.14.0/sqlctx/adapters/omni.py +1301 -0
- sqlctx-0.14.0/sqlctx/adapters/osi.py +1056 -0
- sqlctx-0.14.0/sqlctx/adapters/ossie.py +355 -0
- sqlctx-0.14.0/sqlctx/adapters/rill.py +1094 -0
- sqlctx-0.14.0/sqlctx/adapters/snowflake.py +1330 -0
- sqlctx-0.14.0/sqlctx/adapters/sqlctx.py +1456 -0
- sqlctx-0.14.0/sqlctx/adapters/superset.py +573 -0
- sqlctx-0.14.0/sqlctx/adapters/tableau.py +2059 -0
- sqlctx-0.14.0/sqlctx/adapters/thoughtspot.py +2078 -0
- sqlctx-0.14.0/sqlctx/adapters/tmdl.py +2545 -0
- sqlctx-0.14.0/sqlctx/adapters/tmdl_parser.py +792 -0
- sqlctx-0.14.0/sqlctx/adapters/yardstick.py +401 -0
- sqlctx-0.14.0/sqlctx/api_server.py +967 -0
- sqlctx-0.14.0/sqlctx/apps/__init__.py +79 -0
- sqlctx-0.14.0/sqlctx/apps/_mcp_ui.py +83 -0
- sqlctx-0.14.0/sqlctx/apps/chart.html +341 -0
- sqlctx-0.14.0/sqlctx/apps/chart_widget.html +73 -0
- sqlctx-0.14.0/sqlctx/apps/web/.gitignore +2 -0
- sqlctx-0.14.0/sqlctx/apps/web/chart-app.ts +155 -0
- sqlctx-0.14.0/sqlctx/apps/web/chart.html +37 -0
- sqlctx-0.14.0/sqlctx/apps/web/package.json +21 -0
- sqlctx-0.14.0/sqlctx/apps/web/vite.config.ts +17 -0
- sqlctx-0.14.0/sqlctx/assets/vendor/README.md +14 -0
- sqlctx-0.14.0/sqlctx/assets/vendor/d3-7.9.0.min.js +2 -0
- sqlctx-0.14.0/sqlctx/assets/vendor/observable-plot-0.6.17.umd.min.js +2 -0
- sqlctx-0.14.0/sqlctx/assets/vendor/plotly-2.35.2.min.js +8 -0
- sqlctx-0.14.0/sqlctx/assets/vendor/vega-5.33.1.min.js +2 -0
- sqlctx-0.14.0/sqlctx/assets/vendor/vega-embed-6.29.0.min.js +7 -0
- sqlctx-0.14.0/sqlctx/assets/vendor/vega-lite-5.23.0.min.js +2 -0
- sqlctx-0.14.0/sqlctx/bootstrap.py +361 -0
- sqlctx-0.14.0/sqlctx/charts.py +433 -0
- sqlctx-0.14.0/sqlctx/cli.py +3710 -0
- sqlctx-0.14.0/sqlctx/cli_contract.py +729 -0
- sqlctx-0.14.0/sqlctx/cli_polish.py +416 -0
- sqlctx-0.14.0/sqlctx/click_compat.py +37 -0
- sqlctx-0.14.0/sqlctx/codegen.py +379 -0
- sqlctx-0.14.0/sqlctx/config.py +516 -0
- sqlctx-0.14.0/sqlctx/core/catalog.py +297 -0
- sqlctx-0.14.0/sqlctx/core/consumption.py +184 -0
- sqlctx-0.14.0/sqlctx/core/dependency_analyzer.py +179 -0
- sqlctx-0.14.0/sqlctx/core/dialect.py +1148 -0
- sqlctx-0.14.0/sqlctx/core/dimension.py +150 -0
- sqlctx-0.14.0/sqlctx/core/freshness.py +36 -0
- sqlctx-0.14.0/sqlctx/core/governance.py +66 -0
- sqlctx-0.14.0/sqlctx/core/inheritance.py +253 -0
- sqlctx-0.14.0/sqlctx/core/introspection.py +334 -0
- sqlctx-0.14.0/sqlctx/core/metric.py +461 -0
- sqlctx-0.14.0/sqlctx/core/migrator.py +2066 -0
- sqlctx-0.14.0/sqlctx/core/model.py +227 -0
- sqlctx-0.14.0/sqlctx/core/parameter.py +194 -0
- sqlctx-0.14.0/sqlctx/core/pre_aggregation.py +1148 -0
- sqlctx-0.14.0/sqlctx/core/preagg_management.py +212 -0
- sqlctx-0.14.0/sqlctx/core/preagg_matcher.py +795 -0
- sqlctx-0.14.0/sqlctx/core/preagg_recommender.py +381 -0
- sqlctx-0.14.0/sqlctx/core/query_plan.py +97 -0
- sqlctx-0.14.0/sqlctx/core/registry.py +62 -0
- sqlctx-0.14.0/sqlctx/core/relationship.py +141 -0
- sqlctx-0.14.0/sqlctx/core/relative_date.py +174 -0
- sqlctx-0.14.0/sqlctx/core/required_filters.py +157 -0
- sqlctx-0.14.0/sqlctx/core/result_cache.py +224 -0
- sqlctx-0.14.0/sqlctx/core/schema_exposure.py +63 -0
- sqlctx-0.14.0/sqlctx/core/security.py +307 -0
- sqlctx-0.14.0/sqlctx/core/segment.py +36 -0
- sqlctx-0.14.0/sqlctx/core/semantic_catalog.py +221 -0
- sqlctx-0.14.0/sqlctx/core/semantic_graph.py +830 -0
- sqlctx-0.14.0/sqlctx/core/semantic_layer.py +2447 -0
- sqlctx-0.14.0/sqlctx/core/sql_definitions.py +1056 -0
- sqlctx-0.14.0/sqlctx/core/symmetric_aggregate.py +188 -0
- sqlctx-0.14.0/sqlctx/core/table_calculation.py +74 -0
- sqlctx-0.14.0/sqlctx/core/template.py +208 -0
- sqlctx-0.14.0/sqlctx/core/time_intelligence.py +133 -0
- sqlctx-0.14.0/sqlctx/core/transport_security.py +251 -0
- sqlctx-0.14.0/sqlctx/dashboard.py +768 -0
- sqlctx-0.14.0/sqlctx/datafiles.py +83 -0
- sqlctx-0.14.0/sqlctx/db/__init__.py +42 -0
- sqlctx-0.14.0/sqlctx/db/_duckdb_compat.py +13 -0
- sqlctx-0.14.0/sqlctx/db/adbc.py +451 -0
- sqlctx-0.14.0/sqlctx/db/base.py +302 -0
- sqlctx-0.14.0/sqlctx/db/bigquery.py +240 -0
- sqlctx-0.14.0/sqlctx/db/clickhouse.py +320 -0
- sqlctx-0.14.0/sqlctx/db/databricks.py +264 -0
- sqlctx-0.14.0/sqlctx/db/duckdb.py +289 -0
- sqlctx-0.14.0/sqlctx/db/motherduck.py +131 -0
- sqlctx-0.14.0/sqlctx/db/postgres.py +204 -0
- sqlctx-0.14.0/sqlctx/db/snowflake.py +309 -0
- sqlctx-0.14.0/sqlctx/db/spark.py +219 -0
- sqlctx-0.14.0/sqlctx/db/unavailable.py +59 -0
- sqlctx-0.14.0/sqlctx/fidelity.py +378 -0
- sqlctx-0.14.0/sqlctx/formats.py +458 -0
- sqlctx-0.14.0/sqlctx/interchange/__init__.py +1 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/__init__.py +124 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/compatibility.py +88 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/diagnostics.py +112 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/documents.py +290 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/expression_validation.py +73 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/identifier.py +50 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/latest_semantics.py +183 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/lowering.py +1022 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/mapping.py +281 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/parser.py +643 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/portable.py +306 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/profiles.py +208 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/runtime_extension.py +253 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/README.md +14 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/logical/0.1.1/schema.json +344 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/logical/0.2.0.dev0/schema.json +366 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/logical/0.2.0.dev0-172a3e5/schema.json +396 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/logical/0.2.0.dev0-b6c702e/schema.json +374 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/manifest.json +226 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/mapping/0.2.0.dev0-172a3e5/schema.json +71 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/mapping/0.2.0.dev0-172a3e5/upstream.json +63 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/ontology/0.2.0.dev0/schema.json +298 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/ontology/0.2.0.dev0/upstream.json +298 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/ontology/0.2.0.dev0-172a3e5/schema.json +399 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/ontology/0.2.0.dev0-172a3e5/upstream.json +339 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/ontology/0.2.0.dev0-b6c702e/schema.json +341 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/schemas/ontology/0.2.0.dev0-b6c702e/upstream.json +314 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/semantic_validation.py +1148 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/serialization.py +271 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/synthesis.py +990 -0
- sqlctx-0.14.0/sqlctx/interchange/ossie/validation.py +695 -0
- sqlctx-0.14.0/sqlctx/loaders.py +1852 -0
- sqlctx-0.14.0/sqlctx/lsp/__init__.py +5 -0
- sqlctx-0.14.0/sqlctx/lsp/server.py +1068 -0
- sqlctx-0.14.0/sqlctx/man/sqlctx.1 +962 -0
- sqlctx-0.14.0/sqlctx/manpage.py +137 -0
- sqlctx-0.14.0/sqlctx/mcp_server.py +1327 -0
- sqlctx-0.14.0/sqlctx/paths.py +22 -0
- sqlctx-0.14.0/sqlctx/project.py +299 -0
- sqlctx-0.14.0/sqlctx/quickstart.py +253 -0
- sqlctx-0.14.0/sqlctx/runtime.py +12 -0
- sqlctx-0.14.0/sqlctx/rust_bridge.py +2011 -0
- sqlctx-0.14.0/sqlctx/rust_parity.py +73 -0
- sqlctx-0.14.0/sqlctx/schema.py +144 -0
- sqlctx-0.14.0/sqlctx/semantic_handoff.py +150 -0
- sqlctx-0.14.0/sqlctx/server/__init__.py +1 -0
- sqlctx-0.14.0/sqlctx/server/common.py +312 -0
- sqlctx-0.14.0/sqlctx/server/connection.py +557 -0
- sqlctx-0.14.0/sqlctx/server/pg_catalog.py +372 -0
- sqlctx-0.14.0/sqlctx/server/server.py +196 -0
- sqlctx-0.14.0/sqlctx/sql/aggregation_detection.py +52 -0
- sqlctx-0.14.0/sqlctx/sql/fragment.py +292 -0
- sqlctx-0.14.0/sqlctx/sql/frozen_time.py +293 -0
- sqlctx-0.14.0/sqlctx/sql/generator.py +8689 -0
- sqlctx-0.14.0/sqlctx/sql/lookml_expression.py +944 -0
- sqlctx-0.14.0/sqlctx/sql/order_by.py +26 -0
- sqlctx-0.14.0/sqlctx/sql/ossie_discovery.py +183 -0
- sqlctx-0.14.0/sqlctx/sql/ossie_query.py +13 -0
- sqlctx-0.14.0/sqlctx/sql/ossie_relational.py +1502 -0
- sqlctx-0.14.0/sqlctx/sql/ossie_views.py +344 -0
- sqlctx-0.14.0/sqlctx/sql/ossie_wide.py +690 -0
- sqlctx-0.14.0/sqlctx/sql/parsing.py +43 -0
- sqlctx-0.14.0/sqlctx/sql/planner.py +85 -0
- sqlctx-0.14.0/sqlctx/sql/query_rewriter.py +7333 -0
- sqlctx-0.14.0/sqlctx/sql/rendering.py +79 -0
- sqlctx-0.14.0/sqlctx/sql/selected_table_calculations.py +192 -0
- sqlctx-0.14.0/sqlctx/sql/table_calc_processor.py +329 -0
- sqlctx-0.14.0/sqlctx/testing.py +313 -0
- sqlctx-0.14.0/sqlctx/ui/static/assets/index-DBXs5BBH.css +1 -0
- sqlctx-0.14.0/sqlctx/ui/static/assets/index-jPypzafc.js +55 -0
- sqlctx-0.14.0/sqlctx/ui/static/index.html +13 -0
- sqlctx-0.14.0/sqlctx/validation.py +963 -0
- sqlctx-0.14.0/sqlctx/validation_runner.py +131 -0
- sqlctx-0.14.0/sqlctx/vendor_assets.py +39 -0
- sqlctx-0.14.0/sqlctx/viz.py +5004 -0
- sqlctx-0.14.0/sqlctx/widget/__init__.py +24 -0
- sqlctx-0.14.0/sqlctx/widget/_auto_model.py +149 -0
- sqlctx-0.14.0/sqlctx/widget/_data_registry.py +85 -0
- sqlctx-0.14.0/sqlctx/widget/_widget.py +1059 -0
- sqlctx-0.14.0/sqlctx/widget/static/widget.css +516 -0
- sqlctx-0.14.0/sqlctx/widget/static/widget.js +40 -0
- sqlctx-0.14.0/sqlctx/workbench/__init__.py +53 -0
- sqlctx-0.14.0/sqlctx/workbench/app.py +905 -0
- sqlctx-0.14.0/sqlctx/workbench/examples.py +34 -0
- sqlctx-0.14.0/sqlctx/workbench/validation_app.py +109 -0
- sqlctx-0.14.0/sqlctx/yaml_compat.py +22 -0
- sqlctx-0.14.0/sqlctx-schema.json +6078 -0
- sqlctx-0.14.0/sqlctx-wasm/.gitignore +7 -0
- sqlctx-0.14.0/sqlctx-wasm/.npmignore +6 -0
- sqlctx-0.14.0/sqlctx-wasm/LICENSE +661 -0
- sqlctx-0.14.0/sqlctx-wasm/README.md +133 -0
- sqlctx-0.14.0/sqlctx-wasm/adapters/params.d.ts +7 -0
- sqlctx-0.14.0/sqlctx-wasm/adapters/params.js +29 -0
- sqlctx-0.14.0/sqlctx-wasm/adapters/serve.d.ts +34 -0
- sqlctx-0.14.0/sqlctx-wasm/adapters/serve.js +78 -0
- sqlctx-0.14.0/sqlctx-wasm/adapters/wasm.d.ts +31 -0
- sqlctx-0.14.0/sqlctx-wasm/adapters/wasm.js +36 -0
- sqlctx-0.14.0/sqlctx-wasm/bin/sqlctx-codegen.js +70 -0
- sqlctx-0.14.0/sqlctx-wasm/client.d.ts +216 -0
- sqlctx-0.14.0/sqlctx-wasm/client.js +99 -0
- sqlctx-0.14.0/sqlctx-wasm/codegen.d.ts +29 -0
- sqlctx-0.14.0/sqlctx-wasm/codegen.js +428 -0
- sqlctx-0.14.0/sqlctx-wasm/index.d.ts +59 -0
- sqlctx-0.14.0/sqlctx-wasm/index.js +69 -0
- sqlctx-0.14.0/sqlctx-wasm/scripts/build.sh +62 -0
- sqlctx-0.14.0/sqlctx-wasm/scripts/package_consumer.mjs +65 -0
- sqlctx-0.14.0/sqlctx-wasm/scripts/smoke.mjs +123 -0
- sqlctx-0.14.0/sqlctx-wasm/scripts/smoke_client.mjs +160 -0
- sqlctx-0.14.0/sqlctx-wasm/scripts/smoke_codegen.mjs +244 -0
- sqlctx-0.14.0/sqlctx-wasm/scripts/smoke_package.mjs +27 -0
- sqlctx-0.14.0/sqlctx-wasm/scripts/smoke_vite.mjs +56 -0
- sqlctx-0.14.0/sqlctx-wasm/vite.d.ts +26 -0
- sqlctx-0.14.0/sqlctx-wasm/vite.js +102 -0
- sqlctx-0.14.0/vscode-sqlctx/package.json +100 -0
- sqlctx-0.14.0/webapp/.gitignore +8 -0
- sqlctx-0.14.0/webapp/README.md +104 -0
- sqlctx-0.14.0/webapp/bun.lock +473 -0
- sqlctx-0.14.0/webapp/dist/assets/index-DBXs5BBH.css +1 -0
- sqlctx-0.14.0/webapp/dist/assets/index-jPypzafc.js +55 -0
- sqlctx-0.14.0/webapp/dist/index.html +13 -0
- sqlctx-0.14.0/webapp/index.html +12 -0
- sqlctx-0.14.0/webapp/package.json +35 -0
- sqlctx-0.14.0/webapp/playwright.config.ts +30 -0
- sqlctx-0.14.0/webapp/playwright.ui.config.ts +16 -0
- sqlctx-0.14.0/webapp/postcss.config.js +6 -0
- sqlctx-0.14.0/webapp/src/App.tsx +326 -0
- sqlctx-0.14.0/webapp/src/components/AddFilter.tsx +85 -0
- sqlctx-0.14.0/webapp/src/components/AppBrand.test.tsx +26 -0
- sqlctx-0.14.0/webapp/src/components/AppBrand.tsx +33 -0
- sqlctx-0.14.0/webapp/src/components/AppShell.tsx +166 -0
- sqlctx-0.14.0/webapp/src/components/BarLineCombo.tsx +152 -0
- sqlctx-0.14.0/webapp/src/components/Button.tsx +29 -0
- sqlctx-0.14.0/webapp/src/components/Catalog.tsx +153 -0
- sqlctx-0.14.0/webapp/src/components/ChartTooltip.tsx +62 -0
- sqlctx-0.14.0/webapp/src/components/ColumnChart.tsx +114 -0
- sqlctx-0.14.0/webapp/src/components/Combobox.test.tsx +37 -0
- sqlctx-0.14.0/webapp/src/components/Combobox.tsx +189 -0
- sqlctx-0.14.0/webapp/src/components/DashboardShell.tsx +25 -0
- sqlctx-0.14.0/webapp/src/components/DataTable.test.tsx +46 -0
- sqlctx-0.14.0/webapp/src/components/DataTable.tsx +218 -0
- sqlctx-0.14.0/webapp/src/components/DatePicker.test.tsx +36 -0
- sqlctx-0.14.0/webapp/src/components/DatePicker.tsx +198 -0
- sqlctx-0.14.0/webapp/src/components/DateRangeControl.tsx +176 -0
- sqlctx-0.14.0/webapp/src/components/DistributionAdapters.tsx +32 -0
- sqlctx-0.14.0/webapp/src/components/DonutChart.test.tsx +44 -0
- sqlctx-0.14.0/webapp/src/components/DonutChart.tsx +129 -0
- sqlctx-0.14.0/webapp/src/components/ErrorBoundary.tsx +42 -0
- sqlctx-0.14.0/webapp/src/components/FilterEditor.tsx +282 -0
- sqlctx-0.14.0/webapp/src/components/FilterPill.tsx +68 -0
- sqlctx-0.14.0/webapp/src/components/GrainSelect.tsx +30 -0
- sqlctx-0.14.0/webapp/src/components/HeatmapChart.tsx +0 -0
- sqlctx-0.14.0/webapp/src/components/HistogramChart.test.ts +24 -0
- sqlctx-0.14.0/webapp/src/components/HistogramChart.tsx +110 -0
- sqlctx-0.14.0/webapp/src/components/Leaderboard.test.tsx +37 -0
- sqlctx-0.14.0/webapp/src/components/Leaderboard.tsx +165 -0
- sqlctx-0.14.0/webapp/src/components/LeaderboardPanel.tsx +198 -0
- sqlctx-0.14.0/webapp/src/components/MetricCard.test.tsx +22 -0
- sqlctx-0.14.0/webapp/src/components/MetricCard.tsx +119 -0
- sqlctx-0.14.0/webapp/src/components/MetricTimeSeries.tsx +81 -0
- sqlctx-0.14.0/webapp/src/components/NetworkChart.test.ts +38 -0
- sqlctx-0.14.0/webapp/src/components/NetworkChart.tsx +0 -0
- sqlctx-0.14.0/webapp/src/components/QueryDebugPanel.test.ts +25 -0
- sqlctx-0.14.0/webapp/src/components/QueryDebugPanel.tsx +113 -0
- sqlctx-0.14.0/webapp/src/components/RowPreviewDrawer.test.ts +13 -0
- sqlctx-0.14.0/webapp/src/components/RowPreviewDrawer.tsx +87 -0
- sqlctx-0.14.0/webapp/src/components/ScatterChart.tsx +138 -0
- sqlctx-0.14.0/webapp/src/components/Select.tsx +40 -0
- sqlctx-0.14.0/webapp/src/components/Sparkline.tsx +153 -0
- sqlctx-0.14.0/webapp/src/components/StackedAreaChart.tsx +153 -0
- sqlctx-0.14.0/webapp/src/components/States.tsx +45 -0
- sqlctx-0.14.0/webapp/src/components/Switch.tsx +37 -0
- sqlctx-0.14.0/webapp/src/components/Tabs.test.tsx +25 -0
- sqlctx-0.14.0/webapp/src/components/Tabs.tsx +31 -0
- sqlctx-0.14.0/webapp/src/components/ThemeToggle.tsx +26 -0
- sqlctx-0.14.0/webapp/src/components/TimeSeriesChart.tsx +295 -0
- sqlctx-0.14.0/webapp/src/components/TimezoneSelect.tsx +102 -0
- sqlctx-0.14.0/webapp/src/components/Tooltip.test.tsx +34 -0
- sqlctx-0.14.0/webapp/src/components/Tooltip.tsx +25 -0
- sqlctx-0.14.0/webapp/src/components/ViewSwitcher.tsx +47 -0
- sqlctx-0.14.0/webapp/src/components/WaterfallChart.test.ts +27 -0
- sqlctx-0.14.0/webapp/src/components/WaterfallChart.tsx +136 -0
- sqlctx-0.14.0/webapp/src/components/useFilterPopover.ts +40 -0
- sqlctx-0.14.0/webapp/src/data/arrow.test.ts +72 -0
- sqlctx-0.14.0/webapp/src/data/arrow.ts +41 -0
- sqlctx-0.14.0/webapp/src/data/backend.ts +19 -0
- sqlctx-0.14.0/webapp/src/data/dashboardTypes.ts +90 -0
- sqlctx-0.14.0/webapp/src/data/httpAdapter.test.ts +98 -0
- sqlctx-0.14.0/webapp/src/data/httpAdapter.ts +239 -0
- sqlctx-0.14.0/webapp/src/data/types.test.ts +14 -0
- sqlctx-0.14.0/webapp/src/data/types.ts +0 -0
- sqlctx-0.14.0/webapp/src/index.css +251 -0
- sqlctx-0.14.0/webapp/src/lib/catalog.test.ts +54 -0
- sqlctx-0.14.0/webapp/src/lib/catalog.ts +231 -0
- sqlctx-0.14.0/webapp/src/lib/dashboard.test.ts +410 -0
- sqlctx-0.14.0/webapp/src/lib/dashboard.ts +134 -0
- sqlctx-0.14.0/webapp/src/lib/format.test.ts +72 -0
- sqlctx-0.14.0/webapp/src/lib/format.ts +94 -0
- sqlctx-0.14.0/webapp/src/lib/queries.test.ts +264 -0
- sqlctx-0.14.0/webapp/src/lib/queries.ts +280 -0
- sqlctx-0.14.0/webapp/src/lib/rows.test.ts +70 -0
- sqlctx-0.14.0/webapp/src/lib/rows.ts +0 -0
- sqlctx-0.14.0/webapp/src/lib/theme.ts +85 -0
- sqlctx-0.14.0/webapp/src/lib/time.test.ts +153 -0
- sqlctx-0.14.0/webapp/src/lib/time.ts +234 -0
- sqlctx-0.14.0/webapp/src/lib/timezones.ts +66 -0
- sqlctx-0.14.0/webapp/src/lib/uiCore.d.ts +23 -0
- sqlctx-0.14.0/webapp/src/lib/uiCore.js +91 -0
- sqlctx-0.14.0/webapp/src/lib/uiCore.test.ts +49 -0
- sqlctx-0.14.0/webapp/src/lib/viewport.test.ts +75 -0
- sqlctx-0.14.0/webapp/src/lib/viewport.ts +50 -0
- sqlctx-0.14.0/webapp/src/lib/viz.ts +27 -0
- sqlctx-0.14.0/webapp/src/main.tsx +24 -0
- sqlctx-0.14.0/webapp/src/state/ExplorerContext.test.tsx +194 -0
- sqlctx-0.14.0/webapp/src/state/ExplorerContext.tsx +122 -0
- sqlctx-0.14.0/webapp/src/state/dashboardState.test.ts +531 -0
- sqlctx-0.14.0/webapp/src/state/dashboardState.ts +587 -0
- sqlctx-0.14.0/webapp/src/state/explorerState.test.ts +269 -0
- sqlctx-0.14.0/webapp/src/state/explorerState.ts +251 -0
- sqlctx-0.14.0/webapp/src/state/queryActivity.ts +29 -0
- sqlctx-0.14.0/webapp/src/state/url.test.ts +189 -0
- sqlctx-0.14.0/webapp/src/state/url.ts +174 -0
- sqlctx-0.14.0/webapp/src/state/useQueryResult.test.tsx +65 -0
- sqlctx-0.14.0/webapp/src/state/useQueryResult.ts +65 -0
- sqlctx-0.14.0/webapp/src/static-api.tsx +238 -0
- sqlctx-0.14.0/webapp/src/ui.ts +78 -0
- sqlctx-0.14.0/webapp/src/views/ComponentGallery.tsx +411 -0
- sqlctx-0.14.0/webapp/src/views/DashboardDocumentView.tsx +625 -0
- sqlctx-0.14.0/webapp/src/views/ExploreIndexView.tsx +57 -0
- sqlctx-0.14.0/webapp/src/views/ExplorerView.integration.test.tsx +52 -0
- sqlctx-0.14.0/webapp/src/views/ExplorerView.test.ts +90 -0
- sqlctx-0.14.0/webapp/src/views/ExplorerView.tsx +388 -0
- sqlctx-0.14.0/webapp/src/views/PivotView.tsx +102 -0
- sqlctx-0.14.0/webapp/src/views/TypographyGallery.tsx +327 -0
- sqlctx-0.14.0/webapp/tailwind.config.ts +49 -0
- sqlctx-0.14.0/webapp/tests/dashboard.spec.ts +107 -0
- sqlctx-0.14.0/webapp/tests/date-default.spec.ts +47 -0
- sqlctx-0.14.0/webapp/tests/explorer.spec.ts +247 -0
- sqlctx-0.14.0/webapp/tests/filter-escaping.spec.ts +40 -0
- sqlctx-0.14.0/webapp/tests/filter-popovers.spec.ts +156 -0
- sqlctx-0.14.0/webapp/tests/fixtures/dashboard.yml +70 -0
- sqlctx-0.14.0/webapp/tests/joined-dimensions.spec.ts +118 -0
- sqlctx-0.14.0/webapp/tests/widget.spec.ts +113 -0
- sqlctx-0.14.0/webapp/tsconfig.json +26 -0
- sqlctx-0.14.0/webapp/vite.config.ts +29 -0
- sqlctx-0.1.6/PKG-INFO +0 -69
- sqlctx-0.1.6/README.md +0 -51
- sqlctx-0.1.6/pyproject.toml +0 -21
- sqlctx-0.1.6/setup.cfg +0 -4
- sqlctx-0.1.6/src/cli_commands.py +0 -31
- sqlctx-0.1.6/src/db_utils.py +0 -394
- sqlctx-0.1.6/src/main.py +0 -17
- sqlctx-0.1.6/src/mcp_server.py +0 -57
- sqlctx-0.1.6/src/sqlctx.egg-info/PKG-INFO +0 -69
- sqlctx-0.1.6/src/sqlctx.egg-info/SOURCES.txt +0 -13
- sqlctx-0.1.6/src/sqlctx.egg-info/entry_points.txt +0 -2
- sqlctx-0.1.6/src/sqlctx.egg-info/requires.txt +0 -10
- sqlctx-0.1.6/src/sqlctx.egg-info/top_level.txt +0 -4
- /sqlctx-0.1.6/src/sqlctx.egg-info/dependency_links.txt → /sqlctx-0.14.0/sqlctx/py.typed +0 -0
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "sidequery",
|
|
3
|
+
"interface": {
|
|
4
|
+
"displayName": "Sidequery"
|
|
5
|
+
},
|
|
6
|
+
"plugins": [
|
|
7
|
+
{
|
|
8
|
+
"name": "sqlctx",
|
|
9
|
+
"source": {
|
|
10
|
+
"source": "local",
|
|
11
|
+
"path": "./plugins/sqlctx"
|
|
12
|
+
},
|
|
13
|
+
"policy": {
|
|
14
|
+
"installation": "AVAILABLE",
|
|
15
|
+
"authentication": "ON_INSTALL"
|
|
16
|
+
},
|
|
17
|
+
"category": "Data & Analytics"
|
|
18
|
+
}
|
|
19
|
+
]
|
|
20
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
1.4.0
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "sidequery",
|
|
3
|
+
"owner": {
|
|
4
|
+
"name": "Sidequery",
|
|
5
|
+
"email": "hello@sidemantic.com"
|
|
6
|
+
},
|
|
7
|
+
"plugins": [
|
|
8
|
+
{
|
|
9
|
+
"name": "sqlctx",
|
|
10
|
+
"source": "./plugins/sqlctx",
|
|
11
|
+
"description": "Build, validate, and query sqlctx semantic models, and generate analytics webapps from them. Ships the modeler and webapp-builder skills."
|
|
12
|
+
}
|
|
13
|
+
]
|
|
14
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
.git
|
|
2
|
+
.github
|
|
3
|
+
.venv
|
|
4
|
+
.mypy_cache
|
|
5
|
+
.pytest_cache
|
|
6
|
+
.ruff_cache
|
|
7
|
+
__pycache__
|
|
8
|
+
*.egg-info
|
|
9
|
+
*.pyc
|
|
10
|
+
|
|
11
|
+
# Rust/DuckDB extension builds (not needed for Python image)
|
|
12
|
+
sqlctx-rs/
|
|
13
|
+
sqlctx-duckdb/
|
|
14
|
+
|
|
15
|
+
# Docs and examples not needed at runtime
|
|
16
|
+
docs/
|
|
17
|
+
examples/superset_demo/
|
|
18
|
+
examples/rill_demo/
|
|
19
|
+
examples/cube_demo/
|
|
20
|
+
|
|
21
|
+
# Dev/test artifacts
|
|
22
|
+
Dockerfile.test
|
|
23
|
+
docker-compose.yml
|
|
24
|
+
*.md
|
|
25
|
+
!README.md
|
|
26
|
+
.context/
|
sqlctx-0.14.0/.gitignore
ADDED
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
docs/_site
|
|
2
|
+
# Local preview/runtime artifacts
|
|
3
|
+
.quarto-preview.log
|
|
4
|
+
.quarto-preview.pid
|
|
5
|
+
.marimo-server.log
|
|
6
|
+
.marimo-server.pid
|
|
7
|
+
.playwright-mcp/
|
|
8
|
+
|
|
9
|
+
# Python caches
|
|
10
|
+
__pycache__/
|
|
11
|
+
*.py[cod]
|
|
12
|
+
|
|
13
|
+
# Coverage reports
|
|
14
|
+
.coverage
|
|
15
|
+
htmlcov/
|
|
16
|
+
|
|
17
|
+
# Virtual envs
|
|
18
|
+
.venv/
|
|
19
|
+
|
|
20
|
+
# OS/editor cruft
|
|
21
|
+
.DS_Store
|
|
22
|
+
.idea/
|
|
23
|
+
.vscode/
|
|
24
|
+
.wrangler/
|
|
25
|
+
|
|
26
|
+
# Local example DBs
|
|
27
|
+
examples/*.db
|
|
28
|
+
examples/.ipynb_checkpoints/
|
|
29
|
+
examples/juv.tmp*.py
|
|
30
|
+
|
|
31
|
+
# Local parquet files (large demo data)
|
|
32
|
+
/le_places.parquet
|
|
33
|
+
/categories.parquet
|
|
34
|
+
|
|
35
|
+
# Package installers
|
|
36
|
+
*.pkg
|
|
37
|
+
.claude/settings.local.json
|
|
38
|
+
crates/dax-pyo3/python/sqlctx_dax/_native*.so
|
|
39
|
+
|
|
40
|
+
# Docker volumes
|
|
41
|
+
docker-compose.override.yml
|
|
42
|
+
Dockerfile.test
|
|
43
|
+
sqlctx_definitions.sql
|
|
44
|
+
|
|
45
|
+
# Node.js (for bun tests)
|
|
46
|
+
node_modules/
|
|
47
|
+
bun.lockb
|
|
48
|
+
package.json
|
|
49
|
+
!js/package.json
|
|
50
|
+
!js/bun.lock
|
|
51
|
+
!webapp/package.json
|
|
52
|
+
!sqlctx/apps/web/package.json
|
|
53
|
+
!vscode-sqlctx/package.json
|
|
54
|
+
|
|
55
|
+
# Rust workspace build artifacts (dax local wheel builds)
|
|
56
|
+
/target/
|
|
57
|
+
|
|
58
|
+
# GitHub Actions compiler cache and Cargo shim
|
|
59
|
+
/.ci-mbx/
|
|
60
|
+
/.ci-cache-bin/
|
|
61
|
+
|
|
62
|
+
# Editor indexes
|
|
63
|
+
**/.cache/clangd/
|
sqlctx-0.14.0/AGENTS.md
ADDED
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
# sqlctx
|
|
2
|
+
|
|
3
|
+
Universal SQL-first semantic layer in Python. Imports from Cube/LookML/dbt/Hex/Rill/Malloy, queries against DuckDB/Postgres/BigQuery/Snowflake/etc.
|
|
4
|
+
|
|
5
|
+
## Usage Preference (Important)
|
|
6
|
+
|
|
7
|
+
- sqlctx usage is overwhelmingly CLI-first in practice (roughly 95% CLI usage).
|
|
8
|
+
- Default to `sqlctx` CLI workflows (`validate`, `info`, `query`, `migrate`, etc.).
|
|
9
|
+
- Treat Python API examples as secondary, advanced automation paths, not the default onboarding path.
|
|
10
|
+
|
|
11
|
+
## Codebase Structure
|
|
12
|
+
|
|
13
|
+
**Main Python package:** `sqlctx/`
|
|
14
|
+
- `core/` - SemanticLayer, Model, Dimension, Metric, SemanticGraph
|
|
15
|
+
- `adapters/` - Format parsers (Cube, LookML, MetricFlow, Hex, Rill, Malloy, etc.)
|
|
16
|
+
- `db/` - Database adapters
|
|
17
|
+
- `sql/` - SQL generation and query rewriting
|
|
18
|
+
- `widget/`, `server/`, `workbench/`, `mcp_server.py` - Optional features with lazy imports
|
|
19
|
+
|
|
20
|
+
**Rust runtime and DuckDB extension (experimental):**
|
|
21
|
+
- `sqlctx-rs/` - Rust native runtime, also built as the `sqlctx-rs` Python extension. Python opts in through `sqlctx/rust_bridge.py`, the optional `rust` extra, and `--engine rust|auto`; Python stays the default engine (see `docs/rust-engine-mode.md`).
|
|
22
|
+
- `sqlctx-duckdb/` - DuckDB extension wrapping sqlctx-rs
|
|
23
|
+
|
|
24
|
+
CI runs the Rust and DuckDB jobs when their dirs change, and the Rust jobs also when the Python code they exercise changes (bridge, core, SQL, CLI; see the paths filter in `.github/workflows/ci.yml`).
|
|
25
|
+
|
|
26
|
+
## Version Management
|
|
27
|
+
|
|
28
|
+
Update BOTH when releasing:
|
|
29
|
+
- `pyproject.toml`: `version = "X.Y.Z"`
|
|
30
|
+
- `sqlctx/__init__.py`: `__version__ = "X.Y.Z"`
|
|
31
|
+
|
|
32
|
+
## Validation Before Commits
|
|
33
|
+
|
|
34
|
+
Match validation scope to the change instead of running the entire suite automatically.
|
|
35
|
+
|
|
36
|
+
- For small, localized changes, run ruff on the changed Python files and the narrowest relevant tests. This is the default.
|
|
37
|
+
- Expand to the affected package or subsystem when shared code, planners, adapters, or fixtures may have broader impact.
|
|
38
|
+
- Run the full CI-equivalent sequence only when explicitly requested, preparing a release, changing dependencies/CI/tooling, making a broad cross-cutting refactor, or when targeted checks cannot bound the blast radius.
|
|
39
|
+
- Do not rerun the full suite for a small follow-up on a branch that already had a green full run when targeted tests cover the follow-up.
|
|
40
|
+
- Before handoff, report exactly what ran and what was left to CI.
|
|
41
|
+
|
|
42
|
+
When full CI parity is warranted, run these commands in order:
|
|
43
|
+
|
|
44
|
+
```bash
|
|
45
|
+
# Run these in order:
|
|
46
|
+
uv sync --extra dev
|
|
47
|
+
uv run python - <<'PY'
|
|
48
|
+
import sys
|
|
49
|
+
|
|
50
|
+
from sqlctx import Dimension, Metric, Model
|
|
51
|
+
|
|
52
|
+
assert Model.__name__ == "Model"
|
|
53
|
+
assert Dimension.__name__ == "Dimension"
|
|
54
|
+
assert Metric.__name__ == "Metric"
|
|
55
|
+
assert "sqlctx_dax" not in sys.modules
|
|
56
|
+
PY
|
|
57
|
+
uv sync --extra dev --extra dax
|
|
58
|
+
uv run ruff check . --exclude docs/_extensions --exclude sqlctx-duckdb/extension-ci-tools --exclude sqlctx-duckdb/scripts --exclude sqlctx-duckdb/duckdb --exclude sqlctx/adapters/malloy_grammar --exclude sqlctx/adapters/holistics_grammar
|
|
59
|
+
uv run ruff format --check . --exclude docs/_extensions --exclude sqlctx-duckdb/extension-ci-tools --exclude sqlctx-duckdb/scripts --exclude sqlctx-duckdb/duckdb --exclude sqlctx/adapters/malloy_grammar --exclude sqlctx/adapters/holistics_grammar
|
|
60
|
+
uv run python -m playwright install --with-deps chromium
|
|
61
|
+
uv run pytest -v
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
If any fail, fix them:
|
|
65
|
+
```bash
|
|
66
|
+
# Fix ruff issues
|
|
67
|
+
uv run ruff check --fix . --exclude docs/_extensions --exclude sqlctx-duckdb/extension-ci-tools --exclude sqlctx-duckdb/scripts --exclude sqlctx-duckdb/duckdb --exclude sqlctx/adapters/malloy_grammar --exclude sqlctx/adapters/holistics_grammar
|
|
68
|
+
uv run ruff format . --exclude docs/_extensions --exclude sqlctx-duckdb/extension-ci-tools --exclude sqlctx-duckdb/scripts --exclude sqlctx-duckdb/duckdb --exclude sqlctx/adapters/malloy_grammar --exclude sqlctx/adapters/holistics_grammar
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
**PRs:** Do not include test commands in PR bodies unless explicitly requested.
|
|
72
|
+
|
|
73
|
+
**Why this matters:**
|
|
74
|
+
- Targeted checks keep small changes fast while still covering the affected behavior
|
|
75
|
+
- CI runs the full matrix and remains the final integration gate
|
|
76
|
+
- CI installs with `uv sync --extra dev`, so ruff and other CI tools must be in `[project.optional-dependencies] dev`
|
|
77
|
+
- `[dependency-groups] dev` alone is not enough (uv-only; CI reads the `dev` extra)
|
|
78
|
+
|
|
79
|
+
## Dependency Management
|
|
80
|
+
|
|
81
|
+
- Use `uv` for all Python package management
|
|
82
|
+
- Dev tools such as ruff go in the `dev` extra (`[project.optional-dependencies] dev`); `[dependency-groups] dev` mirrors them for local uv use
|
|
83
|
+
- DO NOT add dev tools to main dependencies unless explicitly requested
|
|
84
|
+
- Optional features use `[project.optional-dependencies]`:
|
|
85
|
+
- `workbench` - textual, plotext, textual-plotext (for TUI, NOT Pyodide compatible)
|
|
86
|
+
- `serve` - riffq, pyarrow (for the PostgreSQL wire server, `sqlctx server postgres`; NOT Pyodide compatible)
|
|
87
|
+
- `api` / `mcp` - fastapi, uvicorn, pyarrow / mcp[cli] (for `sqlctx serve`, `server api`, `server mcp`)
|
|
88
|
+
- `dev` - pytest, ruff, pandas, numpy (for development)
|
|
89
|
+
|
|
90
|
+
**CRITICAL: Pyodide Compatibility Rules**
|
|
91
|
+
- **Core dependencies** (in main `dependencies` list) MUST work in Pyodide/WASM
|
|
92
|
+
- **Optional dependencies** can use packages incompatible with Pyodide (textual, riffq, pyarrow, mcp)
|
|
93
|
+
- **ALL imports** of optional deps MUST be lazy (inside functions, NOT at module level)
|
|
94
|
+
- **Test**: `from sqlctx import Model, Dimension, Metric` must work without any optional deps
|
|
95
|
+
|
|
96
|
+
## Pyodide Compatibility
|
|
97
|
+
|
|
98
|
+
**Import Structure:**
|
|
99
|
+
- `sqlctx/__init__.py` - Only imports core classes (Model, Dimension, etc.)
|
|
100
|
+
- `sqlctx/cli.py` - Imports typer (core dep) at top, workbench/server imports inside command functions
|
|
101
|
+
- `sqlctx/workbench/__init__.py` - Lazy imports textual inside `run_workbench()` function
|
|
102
|
+
- `sqlctx/server/` - Not imported by `sqlctx/__init__.py`; `server.py`/`connection.py` (riffq) load only for `sqlctx server postgres`, and the dependency-free `common.py` is shared with the API, MCP, and chart modules
|
|
103
|
+
|
|
104
|
+
**Pyodide install path** (`docs/pyodide.md`, `.github/workflows/pyodide-test.yml`):
|
|
105
|
+
- Pyodide's bundled `pydantic`, `pyyaml`, and `jinja2` are loaded first; `sqlglot`, `lkml`, and `inflect` are installed with `deps=False`
|
|
106
|
+
- Bundled Pyodide packages pin their own versions (including typing-extensions), so a core dep that needs newer versions breaks this path
|
|
107
|
+
|
|
108
|
+
**Version constraints with "PYODIDE:" comments are REQUIRED:**
|
|
109
|
+
- Heavy deps (textual, riffq, mcp) are optional to avoid Pyodide conflicts
|
|
110
|
+
- Pyodide CI builds local wheel and installs it with `deps=False`
|
|
111
|
+
- This ensures code changes are tested in Pyodide before publish
|
|
112
|
+
- If adding new core deps, check they work in Pyodide or make them optional
|
|
113
|
+
|
|
114
|
+
**If Pyodide CI fails:**
|
|
115
|
+
- Check if a dep version changed that requires newer typing-extensions
|
|
116
|
+
- Either constrain that dep OR update the install sequence in `docs/pyodide.md` and `pyodide-test.yml` together
|
|
117
|
+
- CI installs local wheel to test current code, not PyPI version
|
|
118
|
+
|
|
119
|
+
## Testing
|
|
120
|
+
|
|
121
|
+
Use the validation scope above. Prefer focused test paths or test names for localized changes; reserve `uv run pytest -v` for cases that warrant full CI parity.
|
|
122
|
+
|
|
123
|
+
## Publishing to PyPI
|
|
124
|
+
|
|
125
|
+
```bash
|
|
126
|
+
gh workflow run publish.yml
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
## Common Mistakes to Avoid
|
|
130
|
+
|
|
131
|
+
1. **Breaking ruff** - Always ensure ruff is installed in dev dependencies
|
|
132
|
+
2. **Pyodide compatibility** - Keep heavy deps (textual, pygments) optional
|
|
133
|
+
3. **Not linting** - Format and lint EVERY TIME before commit
|
sqlctx-0.14.0/CLAUDE.md
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@AGENTS.md
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# Contributing
|
|
2
|
+
|
|
3
|
+
sqlctx is primarily developed by Sidequery Corporation. We're not actively seeking external contributions at this time.
|
|
4
|
+
|
|
5
|
+
If you find bugs, please open an issue with reproduction steps.
|
|
6
|
+
|
|
7
|
+
## Development Setup
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
uv sync --all-extras
|
|
11
|
+
uv run pytest
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Running Tests
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
uv run pytest -v
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## Code Style
|
|
21
|
+
|
|
22
|
+
We use `ruff` for linting and formatting:
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
uv run ruff check .
|
|
26
|
+
uv run ruff format .
|
|
27
|
+
```
|