snowflake-code-unit-registry 0.8.41__tar.gz → 0.8.49__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.
Files changed (97) hide show
  1. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/Cargo.lock +19 -187
  2. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/Cargo.toml +2 -2
  3. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/PKG-INFO +1 -1
  4. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/dependency_view.rs +1 -6
  5. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/generated/schema_constraints.rs +12 -13
  6. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/registry/graph.rs +41 -5
  7. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/registry/tests.rs +29 -0
  8. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_refresh.py +17 -0
  9. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/pyproject.toml +1 -1
  10. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/python/snowflake_code_unit_registry/__init__.py +1 -1
  11. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/python/snowflake_code_unit_registry/types.py +9 -1
  12. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/README.md +0 -0
  13. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-error-derive/Cargo.toml +0 -0
  14. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-error-derive/src/lib.rs +0 -0
  15. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-error-derive/tests/derive_integration.rs +0 -0
  16. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-log/Cargo.toml +0 -0
  17. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-log/src/lib.rs +0 -0
  18. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-log/src/tests.rs +0 -0
  19. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/Cargo.toml +0 -0
  20. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/build/file_path_fields.rs +0 -0
  21. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/build/main.rs +0 -0
  22. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/build/output.rs +0 -0
  23. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/build/query_reference.rs +0 -0
  24. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/build/schema.rs +0 -0
  25. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/build/schema_constraints.rs +0 -0
  26. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/build/typify.rs +0 -0
  27. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/build/updated_at_paths.rs +0 -0
  28. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/examples/code-unit.example.json +0 -0
  29. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/examples/etl-code-unit.example.json +0 -0
  30. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/examples/script-code-unit.example.json +0 -0
  31. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/schemas/code-unit.schema.json +0 -0
  32. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/schemas/history/README.md +0 -0
  33. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/schemas/query-reference.rs.tmpl +0 -0
  34. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/schemas/query-reference.tmpl +0 -0
  35. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/bindings.rs +0 -0
  36. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/canonical_name.rs +0 -0
  37. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/checksum.rs +0 -0
  38. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/error.rs +0 -0
  39. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/error_trace.rs +0 -0
  40. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/filter.rs +0 -0
  41. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/generated/file_path_fields.rs +0 -0
  42. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/generated/mod.rs +0 -0
  43. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/generated/query_reference.rs +0 -0
  44. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/generated/updated_at_paths.rs +0 -0
  45. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/identity.rs +0 -0
  46. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/lib.rs +0 -0
  47. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/migration/mod.rs +0 -0
  48. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/migration/versions/mod.rs +0 -0
  49. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/registry/README.md +0 -0
  50. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/registry/in_memory.rs +0 -0
  51. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/registry/loader.rs +0 -0
  52. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/registry/paths.rs +0 -0
  53. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/registry/query.rs +0 -0
  54. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/registry/test_helpers.rs +0 -0
  55. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/registry/test_hooks.rs +0 -0
  56. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/registry.rs +0 -0
  57. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/validation/mod.rs +0 -0
  58. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/src/validation/script_io.rs +0 -0
  59. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/etl_part_cloud_status_data_migration.json +0 -0
  60. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/etl_part_cloud_status_data_validation.json +0 -0
  61. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/etl_part_model_name_on_non_dbt.json +0 -0
  62. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/etl_root_cloud_status.json +0 -0
  63. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/etl_root_dependencies.json +0 -0
  64. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/etl_root_issues.json +0 -0
  65. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/etl_root_source_format.json +0 -0
  66. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/etl_signature.json +0 -0
  67. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/parameterized_reference_clean.json +0 -0
  68. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/parameterized_reference_with_cloud_status.json +0 -0
  69. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/parameterized_reference_with_code_status.json +0 -0
  70. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/parameterized_reference_with_files.json +0 -0
  71. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/parameterized_reference_with_issues.json +0 -0
  72. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/parameterized_reference_with_parts.json +0 -0
  73. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/parameterized_reference_with_planning.json +0 -0
  74. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/parameterized_reference_with_script_bindings.json +0 -0
  75. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/parameterized_reference_with_script_metadata.json +0 -0
  76. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/parameterized_reference_with_signature.json +0 -0
  77. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/parameterized_reference_with_source_format.json +0 -0
  78. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/parameterized_reference_with_target_format.json +0 -0
  79. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/sql_with_parts.json +0 -0
  80. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-core/tests/fixtures/kind-rules/sql_with_stabilization.json +0 -0
  81. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/Cargo.toml +0 -0
  82. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/README.md +0 -0
  83. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/src/lib.rs +0 -0
  84. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/conftest.py +0 -0
  85. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_batch.py +0 -0
  86. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_checksum.py +0 -0
  87. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_cloud_state.py +0 -0
  88. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_crud.py +0 -0
  89. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_errors.py +0 -0
  90. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_logging.py +0 -0
  91. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_migration.py +0 -0
  92. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_query.py +0 -0
  93. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_script_bindings.py +0 -0
  94. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_script_metadata.py +0 -0
  95. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_serialization.py +0 -0
  96. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/crates/scai-state-python/tests/test_validation.py +0 -0
  97. {snowflake_code_unit_registry-0.8.41 → snowflake_code_unit_registry-0.8.49}/python/snowflake_code_unit_registry/cloud_state.py +0 -0
@@ -758,12 +758,6 @@ version = "1.0.7"
758
758
  source = "registry+https://github.com/rust-lang/crates.io-index"
759
759
  checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1"
760
760
 
761
- [[package]]
762
- name = "foldhash"
763
- version = "0.1.5"
764
- source = "registry+https://github.com/rust-lang/crates.io-index"
765
- checksum = "d9c4f5dac5e15c24eb999c26181a6ca40b39fe946cbe4c263c7209467bc83af2"
766
-
767
761
  [[package]]
768
762
  name = "foldhash"
769
763
  version = "0.2.0"
@@ -930,15 +924,13 @@ dependencies = [
930
924
 
931
925
  [[package]]
932
926
  name = "getrandom"
933
- version = "0.4.2"
927
+ version = "0.4.3"
934
928
  source = "registry+https://github.com/rust-lang/crates.io-index"
935
- checksum = "0de51e6874e94e7bf76d726fc5d13ba782deca734ff60d5bb2fb2607c7406555"
929
+ checksum = "300e883d756b2e4ec94e02791f39b04b522276138852cfc41d9fb7e904106099"
936
930
  dependencies = [
937
931
  "cfg-if",
938
932
  "libc",
939
933
  "r-efi 6.0.0",
940
- "wasip2",
941
- "wasip3",
942
934
  ]
943
935
 
944
936
  [[package]]
@@ -1007,15 +999,6 @@ dependencies = [
1007
999
  "zerocopy",
1008
1000
  ]
1009
1001
 
1010
- [[package]]
1011
- name = "hashbrown"
1012
- version = "0.15.5"
1013
- source = "registry+https://github.com/rust-lang/crates.io-index"
1014
- checksum = "9229cfe53dfd69f0609a49f65461bd93001ea1ef889cd5529dd176593f5338a1"
1015
- dependencies = [
1016
- "foldhash 0.1.5",
1017
- ]
1018
-
1019
1002
  [[package]]
1020
1003
  name = "hashbrown"
1021
1004
  version = "0.16.1"
@@ -1024,7 +1007,7 @@ checksum = "841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100"
1024
1007
  dependencies = [
1025
1008
  "allocator-api2",
1026
1009
  "equivalent",
1027
- "foldhash 0.2.0",
1010
+ "foldhash",
1028
1011
  ]
1029
1012
 
1030
1013
  [[package]]
@@ -1258,12 +1241,6 @@ dependencies = [
1258
1241
  "zerovec",
1259
1242
  ]
1260
1243
 
1261
- [[package]]
1262
- name = "id-arena"
1263
- version = "2.3.0"
1264
- source = "registry+https://github.com/rust-lang/crates.io-index"
1265
- checksum = "3d3067d79b975e8844ca9eb072e16b31c3c1c36928edf9c6789548c524d0d954"
1266
-
1267
1244
  [[package]]
1268
1245
  name = "ident_case"
1269
1246
  version = "1.0.1"
@@ -1335,8 +1312,6 @@ checksum = "d466e9454f08e4a911e14806c24e16fba1b4c121d1ea474396f396069cf949d9"
1335
1312
  dependencies = [
1336
1313
  "equivalent",
1337
1314
  "hashbrown 0.17.1",
1338
- "serde",
1339
- "serde_core",
1340
1315
  ]
1341
1316
 
1342
1317
  [[package]]
@@ -1550,12 +1525,6 @@ version = "1.5.0"
1550
1525
  source = "registry+https://github.com/rust-lang/crates.io-index"
1551
1526
  checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe"
1552
1527
 
1553
- [[package]]
1554
- name = "leb128fmt"
1555
- version = "0.1.0"
1556
- source = "registry+https://github.com/rust-lang/crates.io-index"
1557
- checksum = "09edd9e8b54e49e587e4f6295a7d29c3ea94d469cb40ab8ca70b288248a81db2"
1558
-
1559
1528
  [[package]]
1560
1529
  name = "libc"
1561
1530
  version = "0.2.186"
@@ -2622,7 +2591,7 @@ dependencies = [
2622
2591
 
2623
2592
  [[package]]
2624
2593
  name = "scai-error-derive"
2625
- version = "0.8.41"
2594
+ version = "0.8.49"
2626
2595
  dependencies = [
2627
2596
  "err_code",
2628
2597
  "heck",
@@ -2636,7 +2605,7 @@ dependencies = [
2636
2605
 
2637
2606
  [[package]]
2638
2607
  name = "scai-log"
2639
- version = "0.8.41"
2608
+ version = "0.8.49"
2640
2609
  dependencies = [
2641
2610
  "chrono",
2642
2611
  "serde",
@@ -2645,7 +2614,7 @@ dependencies = [
2645
2614
 
2646
2615
  [[package]]
2647
2616
  name = "scai-state-core"
2648
- version = "0.8.41"
2617
+ version = "0.8.49"
2649
2618
  dependencies = [
2650
2619
  "chrono",
2651
2620
  "err_code",
@@ -2671,7 +2640,7 @@ dependencies = [
2671
2640
 
2672
2641
  [[package]]
2673
2642
  name = "scai-state-csharp"
2674
- version = "0.8.41"
2643
+ version = "0.8.49"
2675
2644
  dependencies = [
2676
2645
  "interoptopus",
2677
2646
  "interoptopus_backend_csharp",
@@ -2683,7 +2652,7 @@ dependencies = [
2683
2652
 
2684
2653
  [[package]]
2685
2654
  name = "scai-state-node"
2686
- version = "0.8.41"
2655
+ version = "0.8.49"
2687
2656
  dependencies = [
2688
2657
  "napi",
2689
2658
  "napi-build",
@@ -2696,7 +2665,7 @@ dependencies = [
2696
2665
 
2697
2666
  [[package]]
2698
2667
  name = "scai-state-perf"
2699
- version = "0.8.41"
2668
+ version = "0.8.49"
2700
2669
  dependencies = [
2701
2670
  "chrono",
2702
2671
  "criterion",
@@ -2712,7 +2681,7 @@ dependencies = [
2712
2681
 
2713
2682
  [[package]]
2714
2683
  name = "scai-state-python"
2715
- version = "0.8.41"
2684
+ version = "0.8.49"
2716
2685
  dependencies = [
2717
2686
  "pyo3",
2718
2687
  "pythonize",
@@ -2963,9 +2932,9 @@ dependencies = [
2963
2932
 
2964
2933
  [[package]]
2965
2934
  name = "sqlparser"
2966
- version = "0.61.0"
2935
+ version = "0.62.0"
2967
2936
  source = "registry+https://github.com/rust-lang/crates.io-index"
2968
- checksum = "dbf5ea8d4d7c808e1af1cbabebca9a2abe603bcefc22294c5b95018d53200cb7"
2937
+ checksum = "13c6d1b651dc4edf07eead2a0c6c78016ce971bc2c10da5266861b13f25e7cec"
2969
2938
  dependencies = [
2970
2939
  "log",
2971
2940
  "recursive",
@@ -3033,9 +3002,9 @@ dependencies = [
3033
3002
 
3034
3003
  [[package]]
3035
3004
  name = "syn"
3036
- version = "2.0.117"
3005
+ version = "2.0.118"
3037
3006
  source = "registry+https://github.com/rust-lang/crates.io-index"
3038
- checksum = "e665b8803e7b1d2a727f4023456bbbbe74da67099c585258af0ad9c5013b9b99"
3007
+ checksum = "1b9ae57f904213ebb649ce6895b8a66c66f0203b9319718f69a5612a065b1422"
3039
3008
  dependencies = [
3040
3009
  "proc-macro2",
3041
3010
  "quote",
@@ -3075,7 +3044,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
3075
3044
  checksum = "32497e9a4c7b38532efcdebeef879707aa9f794296a4f0244f6f69e9bc8574bd"
3076
3045
  dependencies = [
3077
3046
  "fastrand",
3078
- "getrandom 0.4.2",
3047
+ "getrandom 0.4.3",
3079
3048
  "once_cell",
3080
3049
  "rustix",
3081
3050
  "windows-sys 0.61.2",
@@ -3360,12 +3329,6 @@ version = "1.13.3"
3360
3329
  source = "registry+https://github.com/rust-lang/crates.io-index"
3361
3330
  checksum = "c6f5d3c3b1bf09027a88a6bc961fc00497d651009560b5463668dc81b0fa87a8"
3362
3331
 
3363
- [[package]]
3364
- name = "unicode-xid"
3365
- version = "0.2.6"
3366
- source = "registry+https://github.com/rust-lang/crates.io-index"
3367
- checksum = "ebc1c04c71510c7f702b52b7c350734c9ff1295c464a03335b00bb84fc54f853"
3368
-
3369
3332
  [[package]]
3370
3333
  name = "untrusted"
3371
3334
  version = "0.9.0"
@@ -3396,7 +3359,7 @@ version = "1.23.3"
3396
3359
  source = "registry+https://github.com/rust-lang/crates.io-index"
3397
3360
  checksum = "144d6b123cef80b301b8f72a9e2ca4370ddec21950d0a103dd22c437006d2db7"
3398
3361
  dependencies = [
3399
- "getrandom 0.4.2",
3362
+ "getrandom 0.4.3",
3400
3363
  "js-sys",
3401
3364
  "wasm-bindgen",
3402
3365
  ]
@@ -3454,16 +3417,7 @@ version = "1.0.4+wasi-0.2.12"
3454
3417
  source = "registry+https://github.com/rust-lang/crates.io-index"
3455
3418
  checksum = "b67efb37e106e55ce722a510d6b5f9c17f083e5fc79afc2badeb12cc313d9487"
3456
3419
  dependencies = [
3457
- "wit-bindgen 0.57.1",
3458
- ]
3459
-
3460
- [[package]]
3461
- name = "wasip3"
3462
- version = "0.4.0+wasi-0.3.0-rc-2026-01-06"
3463
- source = "registry+https://github.com/rust-lang/crates.io-index"
3464
- checksum = "5428f8bf88ea5ddc08faddef2ac4a67e390b88186c703ce6dbd955e1c145aca5"
3465
- dependencies = [
3466
- "wit-bindgen 0.51.0",
3420
+ "wit-bindgen",
3467
3421
  ]
3468
3422
 
3469
3423
  [[package]]
@@ -3521,40 +3475,6 @@ dependencies = [
3521
3475
  "unicode-ident",
3522
3476
  ]
3523
3477
 
3524
- [[package]]
3525
- name = "wasm-encoder"
3526
- version = "0.244.0"
3527
- source = "registry+https://github.com/rust-lang/crates.io-index"
3528
- checksum = "990065f2fe63003fe337b932cfb5e3b80e0b4d0f5ff650e6985b1048f62c8319"
3529
- dependencies = [
3530
- "leb128fmt",
3531
- "wasmparser",
3532
- ]
3533
-
3534
- [[package]]
3535
- name = "wasm-metadata"
3536
- version = "0.244.0"
3537
- source = "registry+https://github.com/rust-lang/crates.io-index"
3538
- checksum = "bb0e353e6a2fbdc176932bbaab493762eb1255a7900fe0fea1a2f96c296cc909"
3539
- dependencies = [
3540
- "anyhow",
3541
- "indexmap",
3542
- "wasm-encoder",
3543
- "wasmparser",
3544
- ]
3545
-
3546
- [[package]]
3547
- name = "wasmparser"
3548
- version = "0.244.0"
3549
- source = "registry+https://github.com/rust-lang/crates.io-index"
3550
- checksum = "47b807c72e1bac69382b3a6fb3dbe8ea4c0ed87ff5629b8685ae6b9a611028fe"
3551
- dependencies = [
3552
- "bitflags 2.13.0",
3553
- "hashbrown 0.15.5",
3554
- "indexmap",
3555
- "semver",
3556
- ]
3557
-
3558
3478
  [[package]]
3559
3479
  name = "web-sys"
3560
3480
  version = "0.3.102"
@@ -3567,9 +3487,9 @@ dependencies = [
3567
3487
 
3568
3488
  [[package]]
3569
3489
  name = "webpki-root-certs"
3570
- version = "1.0.7"
3490
+ version = "1.0.8"
3571
3491
  source = "registry+https://github.com/rust-lang/crates.io-index"
3572
- checksum = "f31141ce3fc3e300ae89b78c0dd67f9708061d1d2eda54b8209346fd6be9a92c"
3492
+ checksum = "0d46a5a140e6f7afeccd8eae97eff335163939eac8b929834875168b29b3d267"
3573
3493
  dependencies = [
3574
3494
  "rustls-pki-types",
3575
3495
  ]
@@ -3746,100 +3666,12 @@ version = "0.52.6"
3746
3666
  source = "registry+https://github.com/rust-lang/crates.io-index"
3747
3667
  checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec"
3748
3668
 
3749
- [[package]]
3750
- name = "wit-bindgen"
3751
- version = "0.51.0"
3752
- source = "registry+https://github.com/rust-lang/crates.io-index"
3753
- checksum = "d7249219f66ced02969388cf2bb044a09756a083d0fab1e566056b04d9fbcaa5"
3754
- dependencies = [
3755
- "wit-bindgen-rust-macro",
3756
- ]
3757
-
3758
3669
  [[package]]
3759
3670
  name = "wit-bindgen"
3760
3671
  version = "0.57.1"
3761
3672
  source = "registry+https://github.com/rust-lang/crates.io-index"
3762
3673
  checksum = "1ebf944e87a7c253233ad6766e082e3cd714b5d03812acc24c318f549614536e"
3763
3674
 
3764
- [[package]]
3765
- name = "wit-bindgen-core"
3766
- version = "0.51.0"
3767
- source = "registry+https://github.com/rust-lang/crates.io-index"
3768
- checksum = "ea61de684c3ea68cb082b7a88508a8b27fcc8b797d738bfc99a82facf1d752dc"
3769
- dependencies = [
3770
- "anyhow",
3771
- "heck",
3772
- "wit-parser",
3773
- ]
3774
-
3775
- [[package]]
3776
- name = "wit-bindgen-rust"
3777
- version = "0.51.0"
3778
- source = "registry+https://github.com/rust-lang/crates.io-index"
3779
- checksum = "b7c566e0f4b284dd6561c786d9cb0142da491f46a9fbed79ea69cdad5db17f21"
3780
- dependencies = [
3781
- "anyhow",
3782
- "heck",
3783
- "indexmap",
3784
- "prettyplease",
3785
- "syn",
3786
- "wasm-metadata",
3787
- "wit-bindgen-core",
3788
- "wit-component",
3789
- ]
3790
-
3791
- [[package]]
3792
- name = "wit-bindgen-rust-macro"
3793
- version = "0.51.0"
3794
- source = "registry+https://github.com/rust-lang/crates.io-index"
3795
- checksum = "0c0f9bfd77e6a48eccf51359e3ae77140a7f50b1e2ebfe62422d8afdaffab17a"
3796
- dependencies = [
3797
- "anyhow",
3798
- "prettyplease",
3799
- "proc-macro2",
3800
- "quote",
3801
- "syn",
3802
- "wit-bindgen-core",
3803
- "wit-bindgen-rust",
3804
- ]
3805
-
3806
- [[package]]
3807
- name = "wit-component"
3808
- version = "0.244.0"
3809
- source = "registry+https://github.com/rust-lang/crates.io-index"
3810
- checksum = "9d66ea20e9553b30172b5e831994e35fbde2d165325bec84fc43dbf6f4eb9cb2"
3811
- dependencies = [
3812
- "anyhow",
3813
- "bitflags 2.13.0",
3814
- "indexmap",
3815
- "log",
3816
- "serde",
3817
- "serde_derive",
3818
- "serde_json",
3819
- "wasm-encoder",
3820
- "wasm-metadata",
3821
- "wasmparser",
3822
- "wit-parser",
3823
- ]
3824
-
3825
- [[package]]
3826
- name = "wit-parser"
3827
- version = "0.244.0"
3828
- source = "registry+https://github.com/rust-lang/crates.io-index"
3829
- checksum = "ecc8ac4bc1dc3381b7f59c34f00b67e18f910c2c0f50015669dde7def656a736"
3830
- dependencies = [
3831
- "anyhow",
3832
- "id-arena",
3833
- "indexmap",
3834
- "log",
3835
- "semver",
3836
- "serde",
3837
- "serde_derive",
3838
- "serde_json",
3839
- "unicode-xid",
3840
- "wasmparser",
3841
- ]
3842
-
3843
3675
  [[package]]
3844
3676
  name = "writeable"
3845
3677
  version = "0.6.3"
@@ -3,7 +3,7 @@ resolver = "2"
3
3
  members = ["crates/scai-error-derive", "crates/scai-log", "crates/scai-state-core", "crates/scai-state-python"]
4
4
 
5
5
  [workspace.package]
6
- version = "0.8.41"
6
+ version = "0.8.49"
7
7
  edition = "2021"
8
8
  license = "SEE LICENSE IN LICENSE"
9
9
  repository = "https://github.com/snowflake-eng/scai-state"
@@ -15,7 +15,7 @@ snafu = "0.9"
15
15
  err_code = "0.1"
16
16
  uuid = { version = "1.0", features = ["v4"] }
17
17
  fs2 = "0.4"
18
- sqlparser = "0.61"
18
+ sqlparser = "0.62"
19
19
  criterion = { version = "0.5", features = ["html_reports"] }
20
20
 
21
21
  [profile.profiling]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: snowflake-code-unit-registry
3
- Version: 0.8.41
3
+ Version: 0.8.49
4
4
  Classifier: Development Status :: 3 - Alpha
5
5
  Classifier: Intended Audience :: Developers
6
6
  Classifier: License :: OSI Approved :: Apache Software License
@@ -51,13 +51,8 @@ pub(crate) fn depends_on_with_origin(
51
51
  root.chain(parts)
52
52
  }
53
53
 
54
- /// Convenience: every `dependsOn` edge, origin discarded.
55
- pub(crate) fn depends_on(unit: &CodeUnit) -> impl Iterator<Item = &Dependency> {
56
- depends_on_with_origin(unit).map(|(_, dep)| dep)
57
- }
58
-
59
54
  /// Mutable iterator over every `dependsOn` edge. Mirrors the order of
60
- /// [`depends_on`] exactly.
55
+ /// [`depends_on_with_origin`] exactly (with origin discarded).
61
56
  pub(crate) fn depends_on_mut(unit: &mut CodeUnit) -> impl Iterator<Item = &mut Dependency> {
62
57
  dep_blocks_mut(unit).flat_map(|d| d.depends_on.iter_mut())
63
58
  }
@@ -103,13 +103,14 @@ pub struct RequiredWhen {
103
103
  pub when: &'static [(&'static str, &'static [&'static str])],
104
104
  }
105
105
 
106
- pub const REQUIRED_WHEN_CONSTRAINTS: &[RequiredWhen] = &[
107
- RequiredWhen {
108
- parent_pointer: "/properties/target",
109
- leaf_name: "format",
110
- when: &[("codeStatus.conversion.status", &["completed"]), ("kind", &["script"])],
111
- },
112
- ];
106
+ pub const REQUIRED_WHEN_CONSTRAINTS: &[RequiredWhen] = &[RequiredWhen {
107
+ parent_pointer: "/properties/target",
108
+ leaf_name: "format",
109
+ when: &[
110
+ ("codeStatus.conversion.status", &["completed"]),
111
+ ("kind", &["script"]),
112
+ ],
113
+ }];
113
114
 
114
115
  /// One `x-allowed-fields` constraint at a `$ref`'d use site.
115
116
  ///
@@ -122,9 +123,7 @@ pub struct AllowedFieldConstraint {
122
123
  pub allowed_fields: &'static [&'static str],
123
124
  }
124
125
 
125
- pub const ALLOWED_FIELD_CONSTRAINTS: &[AllowedFieldConstraint] = &[
126
- AllowedFieldConstraint {
127
- pointer: "/properties/parts/items/properties/cloudStatus",
128
- allowed_fields: &["testing", "deployment"],
129
- },
130
- ];
126
+ pub const ALLOWED_FIELD_CONSTRAINTS: &[AllowedFieldConstraint] = &[AllowedFieldConstraint {
127
+ pointer: "/properties/parts/items/properties/cloudStatus",
128
+ allowed_fields: &["testing", "deployment"],
129
+ }];
@@ -11,6 +11,8 @@
11
11
  //!
12
12
  //! `predecessors(A)` yields B — follows `dependsOn` (what must come before A)
13
13
  //! `successors(B)` yields A — follows `requiredBy` (what comes after B)
14
+ //! Root-level `dependsOn` self-references are ignored for deployment ordering
15
+ //! (topological rank and cycle detection) but remain in stored `dependsOn`.
14
16
 
15
17
  use std::collections::{HashMap, HashSet, VecDeque};
16
18
 
@@ -98,15 +100,29 @@ impl<'a> RegistryGraph<'a> {
98
100
 
99
101
  // ── Traversal utilities ─────────────────────────────────────────────────
100
102
 
103
+ /// Indices of this unit's predecessors (units it depends on).
104
+ /// A depends on B means B is A's predecessor.
105
+ fn is_root_self_dep(
106
+ origin: dependency_view::Origin<'_>,
107
+ unit_id: Option<&str>,
108
+ dep_id: Option<&str>,
109
+ ) -> bool {
110
+ matches!(origin, dependency_view::Origin::Root) && unit_id.is_some() && dep_id == unit_id
111
+ }
112
+
101
113
  /// Indices of this unit's predecessors (units it depends on).
102
114
  /// A depends on B means B is A's predecessor.
103
115
  fn predecessors<'a>(
104
116
  unit: &'a CodeUnit,
105
117
  id_to_index: &'a HashMap<String, usize>,
106
118
  ) -> impl Iterator<Item = usize> + 'a {
107
- dependency_view::depends_on(unit)
108
- .filter_map(|dep| dep.id.as_deref())
109
- .filter_map(|id| id_to_index.get(id).copied())
119
+ dependency_view::depends_on_with_origin(unit).filter_map(move |(origin, dep)| {
120
+ let id = dep.id.as_deref()?;
121
+ if is_root_self_dep(origin, unit.id.as_deref(), Some(id)) {
122
+ return None;
123
+ }
124
+ id_to_index.get(id).copied()
125
+ })
110
126
  }
111
127
 
112
128
  /// Indices of this unit's successors (units that depend on it),
@@ -263,14 +279,16 @@ impl RefreshState {
263
279
  let mut resolved_predecessors = Vec::new();
264
280
  let mut saw_any = false;
265
281
 
266
- for dep in dependency_view::depends_on(unit) {
282
+ for (origin, dep) in dependency_view::depends_on_with_origin(unit) {
267
283
  saw_any = true;
268
284
  let missing = match dep.id.as_deref() {
269
285
  None => true,
270
286
  Some(id) => match id_to_index.get(id) {
271
287
  None => true,
272
288
  Some(&dep_idx) => {
273
- resolved_predecessors.push(dep_idx);
289
+ if !is_root_self_dep(origin, unit.id.as_deref(), dep.id.as_deref()) {
290
+ resolved_predecessors.push(dep_idx);
291
+ }
274
292
  units[dep_idx].is_missing
275
293
  }
276
294
  },
@@ -595,6 +613,22 @@ mod tests {
595
613
  let mut units = vec![unit_with_dependencies("a", &[Some("a")])];
596
614
  let idx = id_index(&units);
597
615
 
616
+ RegistryGraph::new(&mut units, &idx).refresh(true).unwrap();
617
+
618
+ assert_eq!(rank_of(&units[0]), Some(0));
619
+ assert_eq!(required_by_of(&units[0]), Vec::<String>::new());
620
+ assert_eq!(predecessor_is_missing_of(&units[0]), vec![Some(false)]);
621
+ assert!(!transitive_missing_of(&units[0]));
622
+ }
623
+
624
+ #[test]
625
+ fn refresh_self_loop_does_not_mask_real_cycle() {
626
+ let mut units = vec![
627
+ unit_with_dependencies("a", &[Some("a"), Some("b")]),
628
+ unit_with_dependencies("b", &[Some("a")]),
629
+ ];
630
+ let idx = id_index(&units);
631
+
598
632
  let err = RegistryGraph::new(&mut units, &idx)
599
633
  .refresh(true)
600
634
  .unwrap_err();
@@ -603,7 +637,9 @@ mod tests {
603
637
  let mut g = RegistryGraph::new(&mut units, &idx);
604
638
  g.refresh(false).unwrap();
605
639
  assert_eq!(rank_of(&units[0]), Some(-1));
640
+ assert_eq!(rank_of(&units[1]), Some(-1));
606
641
  assert!(transitive_missing_of(&units[0]));
642
+ assert!(transitive_missing_of(&units[1]));
607
643
  }
608
644
 
609
645
  #[test]
@@ -1445,6 +1445,35 @@ fn create_auto_refresh_best_effort_on_cycle() {
1445
1445
  );
1446
1446
  }
1447
1447
 
1448
+ #[test]
1449
+ fn create_auto_refresh_self_reference() {
1450
+ let dir = temp_dir();
1451
+ let registry = CodeUnitRegistry::init(dir.path()).unwrap();
1452
+
1453
+ let id = registry
1454
+ .create(&mut make_unit_with_deps("a", &["a"]), None)
1455
+ .unwrap();
1456
+ assert_eq!(id, "a");
1457
+
1458
+ let a = read_unit(&registry, "a");
1459
+ assert_eq!(a.planning.unwrap().topological_rank, Some(0));
1460
+ assert_eq!(
1461
+ a.dependencies.as_ref().unwrap().depends_on[0].is_missing,
1462
+ Some(false)
1463
+ );
1464
+ assert!(
1465
+ !a.dependencies
1466
+ .as_ref()
1467
+ .unwrap()
1468
+ .has_transitive_missing_dependencies
1469
+ );
1470
+
1471
+ registry.refresh_dependencies().unwrap();
1472
+
1473
+ let a_after = read_unit(&registry, "a");
1474
+ assert_eq!(a_after.planning.unwrap().topological_rank, Some(0));
1475
+ }
1476
+
1448
1477
  #[test]
1449
1478
  fn create_with_corrupt_sibling_succeeds_without_hooks() {
1450
1479
  let dir = temp_dir();
@@ -81,6 +81,23 @@ def test_create_best_effort_on_cycle(registry_dir: str):
81
81
  assert y.dependencies.hasTransitiveMissingDependencies is True
82
82
 
83
83
 
84
+ def test_create_self_reference_is_not_cycle(registry_dir: str):
85
+ registry = CodeUnitRegistry.init(registry_dir)
86
+
87
+ unit_id = registry.create(_unit("a", ["a"]))
88
+ assert unit_id == "a"
89
+
90
+ a = registry.get_by_id("a")
91
+ assert a.planning.topologicalRank == 0
92
+ assert a.dependencies.dependsOn[0].isMissing is False
93
+ assert a.dependencies.hasTransitiveMissingDependencies is False
94
+
95
+ registry.refresh_dependencies()
96
+
97
+ a_after = registry.get_by_id("a")
98
+ assert a_after.planning.topologicalRank == 0
99
+
100
+
84
101
  def test_delete_auto_refreshes_missing_flags(registry_dir: str):
85
102
  registry = CodeUnitRegistry.init(registry_dir)
86
103
 
@@ -4,7 +4,7 @@ build-backend = "maturin"
4
4
 
5
5
  [project]
6
6
  name = "snowflake-code-unit-registry"
7
- version = "0.8.41"
7
+ version = "0.8.49"
8
8
  description = "SCAI state management library for database migrations"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.9"
@@ -46,7 +46,7 @@ from snowflake_code_unit_registry.types import CodeUnit
46
46
  if TYPE_CHECKING:
47
47
  from collections.abc import Sequence
48
48
 
49
- __version__ = "0.8.41"
49
+ __version__ = "0.8.49"
50
50
  __all__ = [
51
51
  "CodeUnitRegistry",
52
52
  "ScaiLogger",
@@ -4,7 +4,7 @@
4
4
  from __future__ import annotations
5
5
 
6
6
  from enum import Enum
7
- from typing import Any, Literal
7
+ from typing import Any, Dict, Literal
8
8
 
9
9
  from pydantic import AwareDatetime, BaseModel, ConfigDict, Field, RootModel, constr
10
10
 
@@ -406,6 +406,10 @@ class CloudStatus(BaseModel):
406
406
  )
407
407
 
408
408
 
409
+ CloudStatus.__annotations__['__pydantic_extra__'] = Dict[str, Any]
410
+ CloudStatus.model_rebuild(force=True)
411
+
412
+
409
413
  class PartTarget(BaseModel):
410
414
  """
411
415
  Target object metadata for a single ETL part
@@ -744,6 +748,10 @@ class CodeStatus(BaseModel):
744
748
  )
745
749
 
746
750
 
751
+ CodeStatus.__annotations__['__pydantic_extra__'] = Dict[str, Any]
752
+ CodeStatus.model_rebuild(force=True)
753
+
754
+
747
755
  class Issues(RootModel[list[Issue]]):
748
756
  root: list[Issue] = Field(
749
757
  ..., description='Derived issues from converted code scanning', title='Issues'