Skip to content

Commit 70c35b2

Browse files
committed
Remove @ operator immediately instead of deprecation
Since @ was not widely used, raise an error immediately directing users to .join(semantic_check=False) rather than going through a gradual deprecation period.
1 parent 9c018a8 commit 70c35b2

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

docs/SPEC-semantic-matching.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ Note: `A - B` is the negated form of restriction (equivalent to `A & ~B`), not a
106106

107107
**Resolution**: Use `.proj()` to rename one of the colliding attributes.
108108

109-
**Deprecated**: The `@` operator is deprecated. Use `.join(semantic_check=False)` instead.
109+
**Removed**: The `@` operator is removed. Use `.join(semantic_check=False)` instead.
110110

111111
**Note**: A warning may be raised for joins on unindexed attributes (performance consideration).
112112

@@ -588,9 +588,9 @@ if not has_index(table1, attr) or not has_index(table2, attr):
588588
)
589589
```
590590

591-
### D6: Deprecate the `@` Operator
591+
### D6: Remove the `@` Operator
592592

593-
**Decision**: Deprecate the `@` (permissive join) operator.
593+
**Decision**: Remove the `@` (permissive join) operator.
594594

595595
**Rationale**:
596596
- Having two join operators (`*` and `@`) with subtle differences adds confusion
@@ -600,14 +600,14 @@ if not has_index(table1, attr) or not has_index(table2, attr):
600600

601601
**Migration**:
602602
```python
603-
# Old (deprecated)
604-
A @ B
603+
# Old (removed)
604+
A @ B # raises error
605605

606606
# New
607607
A.join(B, semantic_check=False)
608608
```
609609

610-
The `@` operator will emit a deprecation warning and eventually be removed.
610+
The `@` operator raises an error immediately, directing users to the new syntax. Since `@` was not widely used, a gradual deprecation period is unnecessary.
611611

612612
### D7: Migration via Utility Function
613613

@@ -752,7 +752,7 @@ Semantic matching is a significant change to DataJoint's join semantics that imp
752752
| **D3**: Computed attributes | Lineage = `None` (breaks matching) |
753753
| **D4**: `dj.U` interaction | Does not affect lineage |
754754
| **D5**: Secondary attr restriction | Replaced by lineage rule - FK-inherited attrs have lineage, native secondary don't |
755-
| **D6**: `@` operator | Deprecated - use `.join(semantic_check=False)` |
755+
| **D6**: `@` operator | Removed - raises error directing to `.join(semantic_check=False)` |
756756
| **D7**: Migration | Utility function + automatic fallback computation |
757757
| **D8**: PK formation | Functional dependency analysis; left operand wins ties; non-commutative |
758758
| **D9**: Aggregation | B must contain A's entire PK; result PK = PK(A); applies to `keep_all_rows=True` too |

0 commit comments

Comments
 (0)