inputlayer-client-dev 0.1.0.dev919__py3-none-any.whl → 0.1.0.dev921__py3-none-any.whl
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.
- inputlayer/compiler.py +11 -6
- {inputlayer_client_dev-0.1.0.dev919.dist-info → inputlayer_client_dev-0.1.0.dev921.dist-info}/METADATA +1 -1
- {inputlayer_client_dev-0.1.0.dev919.dist-info → inputlayer_client_dev-0.1.0.dev921.dist-info}/RECORD +6 -6
- {inputlayer_client_dev-0.1.0.dev919.dist-info → inputlayer_client_dev-0.1.0.dev921.dist-info}/WHEEL +0 -0
- {inputlayer_client_dev-0.1.0.dev919.dist-info → inputlayer_client_dev-0.1.0.dev921.dist-info}/entry_points.txt +0 -0
- {inputlayer_client_dev-0.1.0.dev919.dist-info → inputlayer_client_dev-0.1.0.dev921.dist-info}/licenses/LICENSE +0 -0
inputlayer/compiler.py
CHANGED
|
@@ -666,6 +666,17 @@ def compile_rule(
|
|
|
666
666
|
else:
|
|
667
667
|
head_parts.append(column_to_variable(col))
|
|
668
668
|
|
|
669
|
+
# Compile filter conditions BEFORE building body atoms, so every column
|
|
670
|
+
# the condition references is registered in the env and gets bound to a
|
|
671
|
+
# variable in its atom. Compiling them after produced atoms with `_` for
|
|
672
|
+
# condition-only columns while the condition referenced an unbound
|
|
673
|
+
# variable - which the engine accepts and silently satisfies, deriving
|
|
674
|
+
# wrong results (e.g. a tier == "gold" filter matching every row).
|
|
675
|
+
cond_parts: list[str] = []
|
|
676
|
+
if condition:
|
|
677
|
+
cond_parts = compile_bool_expr(condition, env)
|
|
678
|
+
cond_parts = [p for p in cond_parts if p]
|
|
679
|
+
|
|
669
680
|
# Build body atoms
|
|
670
681
|
body_atoms: list[str] = []
|
|
671
682
|
for rn, cls, alias in body_relations:
|
|
@@ -680,12 +691,6 @@ def compile_rule(
|
|
|
680
691
|
atom_parts.append("_")
|
|
681
692
|
body_atoms.append(f"{rn}({', '.join(atom_parts)})")
|
|
682
693
|
|
|
683
|
-
# Compile filter conditions
|
|
684
|
-
cond_parts: list[str] = []
|
|
685
|
-
if condition:
|
|
686
|
-
cond_parts = compile_bool_expr(condition, env)
|
|
687
|
-
cond_parts = [p for p in cond_parts if p]
|
|
688
|
-
|
|
689
694
|
all_body = body_atoms + cond_parts
|
|
690
695
|
prefix = "+" if persistent else ""
|
|
691
696
|
head_str = f"{prefix}{head_name}({', '.join(head_parts)})"
|
{inputlayer_client_dev-0.1.0.dev919.dist-info → inputlayer_client_dev-0.1.0.dev921.dist-info}/RECORD
RENAMED
|
@@ -8,7 +8,7 @@ inputlayer/aggregations.py,sha256=qQm9PUxTZGCIfCThexrD3wa71327pshI9wJCLkFJI74,29
|
|
|
8
8
|
inputlayer/auth.py,sha256=Vp3Jkx9cQUTjPX31cpMIIkPDoBWmjalg1kcyxeYl8pA,3249
|
|
9
9
|
inputlayer/client.py,sha256=U8zBp0srmTFmzFY626IbrXtlaXbxlWj5Cj_R1vtD17I,7584
|
|
10
10
|
inputlayer/client_sync.py,sha256=Dz38mRQT3Mc7wwmOYgVQP9dBCVgMFIESATmy7fBYAjc,8346
|
|
11
|
-
inputlayer/compiler.py,sha256=
|
|
11
|
+
inputlayer/compiler.py,sha256=5YMFZO6sl6lZ63fUH2bCb-PEl1QK_sbB1ntdHRjmi-k,24792
|
|
12
12
|
inputlayer/connection.py,sha256=tYbRH5Q1OzR1KfguSEhfZ1LXTeX708OIdp-yatbMeoA,13772
|
|
13
13
|
inputlayer/derived.py,sha256=ngjuYmKY88ZSnmb4RiTB2bDEr9buzoM15J6NdKqhSNo,4793
|
|
14
14
|
inputlayer/exceptions.py,sha256=6b2WEkpfLnf02MLyXzXA8ohUqIwXFdo4RDWw46FINH8,2712
|
|
@@ -48,8 +48,8 @@ inputlayer/migrations/operations.py,sha256=_qiguq0GFcXVZgIJa4vHu7eeKSa5BUh2maDce
|
|
|
48
48
|
inputlayer/migrations/recorder.py,sha256=qARvQKL_s84vWTEEuHFAmVPvAZiTYCW4X-HtLIdpnbA,3282
|
|
49
49
|
inputlayer/migrations/state.py,sha256=BH5_ly9I9bVPn1lvhqS_UWS7NvYg2iCLJrbG50-mwlQ,3695
|
|
50
50
|
inputlayer/migrations/writer.py,sha256=4EZjKTu10pry-3vVchg36I9aNHs-zavLzJeDbZd2rko,1497
|
|
51
|
-
inputlayer_client_dev-0.1.0.
|
|
52
|
-
inputlayer_client_dev-0.1.0.
|
|
53
|
-
inputlayer_client_dev-0.1.0.
|
|
54
|
-
inputlayer_client_dev-0.1.0.
|
|
55
|
-
inputlayer_client_dev-0.1.0.
|
|
51
|
+
inputlayer_client_dev-0.1.0.dev921.dist-info/METADATA,sha256=j6xsBI7GizHy4JBZes1QFLTzWnwz6VYlAcuuR_mhfDc,19942
|
|
52
|
+
inputlayer_client_dev-0.1.0.dev921.dist-info/WHEEL,sha256=zOwg4jB6zX2kU910N-cMawjivD6tO8NEWvE12je1bVk,87
|
|
53
|
+
inputlayer_client_dev-0.1.0.dev921.dist-info/entry_points.txt,sha256=xEo6y283VSdmZ4G_KSh1-Cpl3ZPmgM6x9OLT8VJcrqs,70
|
|
54
|
+
inputlayer_client_dev-0.1.0.dev921.dist-info/licenses/LICENSE,sha256=zed5l9sdToIBMxqe_4I7nX1NTIlqxzT_PBO3rj7-ax4,11281
|
|
55
|
+
inputlayer_client_dev-0.1.0.dev921.dist-info/RECORD,,
|
{inputlayer_client_dev-0.1.0.dev919.dist-info → inputlayer_client_dev-0.1.0.dev921.dist-info}/WHEEL
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|