Skip to content

Commit

Permalink
Manager lookup for core IDs (#66)
Browse files Browse the repository at this point in the history
* Manager lookup for core IDs
* Bump version
* Update release-notes.md
  • Loading branch information
tarsil authored Jan 7, 2025
1 parent 95246f8 commit 511bc66
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
6 changes: 6 additions & 0 deletions docs/en/docs/release-notes.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Release Notes

## 0.11.1

### Fix

- Running the `.filter(...)` lookups using the ID by parsing to the proper format.

## 0.11.0

### Added
Expand Down
2 changes: 1 addition & 1 deletion mongoz/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
__version__ = "0.11.0"
__version__ = "0.11.1"

from .conf import settings
from .conf.global_settings import MongozSettings
Expand Down
2 changes: 1 addition & 1 deletion mongoz/core/db/querysets/core/manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ def filter_query(self, exclude: bool = False, **kwargs: Any) -> "Manager":
if "__" in key:
parts = key.split("__")
lookup_operator = parts[-1]
field_name = parts[-2]
field_name = self._find_and_replace_id(parts[-2])

assert (
lookup_operator in settings.filter_operators
Expand Down

0 comments on commit 511bc66

Please sign in to comment.