half-orm 0.18.2__tar.gz → 0.18.3__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 (37) hide show
  1. {half_orm-0.18.2/half_orm.egg-info → half_orm-0.18.3}/PKG-INFO +1 -1
  2. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/model.py +4 -3
  3. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/null.py +1 -1
  4. half_orm-0.18.3/half_orm/version.txt +1 -0
  5. {half_orm-0.18.2 → half_orm-0.18.3/half_orm.egg-info}/PKG-INFO +1 -1
  6. half_orm-0.18.2/half_orm/version.txt +0 -1
  7. {half_orm-0.18.2 → half_orm-0.18.3}/AUTHORS +0 -0
  8. {half_orm-0.18.2 → half_orm-0.18.3}/LICENSE +0 -0
  9. {half_orm-0.18.2 → half_orm-0.18.3}/README.md +0 -0
  10. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/__init__.py +0 -0
  11. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/__main__.py +0 -0
  12. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/cli.py +0 -0
  13. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/cli_utils.py +0 -0
  14. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/field.py +0 -0
  15. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/field_errors.py +0 -0
  16. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/fkey.py +0 -0
  17. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/hotest.py +0 -0
  18. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/model_errors.py +0 -0
  19. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/pg_meta.py +0 -0
  20. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/relation.py +0 -0
  21. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/relation_errors.py +0 -0
  22. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/relation_factory.py +0 -0
  23. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/sql_adapter.py +0 -0
  24. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/sql_ast.py +0 -0
  25. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/transaction.py +0 -0
  26. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm/utils.py +0 -0
  27. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm.egg-info/SOURCES.txt +0 -0
  28. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm.egg-info/dependency_links.txt +0 -0
  29. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm.egg-info/entry_points.txt +0 -0
  30. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm.egg-info/requires.txt +0 -0
  31. {half_orm-0.18.2 → half_orm-0.18.3}/half_orm.egg-info/top_level.txt +0 -0
  32. {half_orm-0.18.2 → half_orm-0.18.3}/pyproject.toml +0 -0
  33. {half_orm-0.18.2 → half_orm-0.18.3}/setup.cfg +0 -0
  34. {half_orm-0.18.2 → half_orm-0.18.3}/setup.py +0 -0
  35. {half_orm-0.18.2 → half_orm-0.18.3}/test/test_cli.py +0 -0
  36. {half_orm-0.18.2 → half_orm-0.18.3}/test/test_main.py +0 -0
  37. {half_orm-0.18.2 → half_orm-0.18.3}/test/test_sql_ast.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: half_orm
3
- Version: 0.18.2
3
+ Version: 0.18.3
4
4
  Summary: A simple PostgreSQL to Python mapper.
5
5
  Home-page: https://github.com/half-orm/half-orm
6
6
  Author: Joël Maïzi
@@ -347,9 +347,10 @@ class Model:
347
347
  v = v.value
348
348
  if isinstance(v, Null):
349
349
  return None
350
- # psycopg 3 needs list (not tuple) for ANY() array params
351
- if isinstance(v, tuple):
352
- return list(v)
350
+ # Recurse into lists/tuples (e.g. Field objects inside ANY() arrays)
351
+ if isinstance(v, (list, tuple)):
352
+ unwrapped = [_unwrap(item) for item in v]
353
+ return list(unwrapped)
353
354
  return v
354
355
  unwrapped = [_unwrap(v) for v in values]
355
356
  return type(values)(unwrapped)
@@ -43,4 +43,4 @@ class FieldDumper(Dumper):
43
43
  return None
44
44
  from psycopg.adapt import Transformer, PyFormat
45
45
  tx = Transformer(self.connection)
46
- return tx.get_dumper(v, PyFormat.AUTO).dump(v)
46
+ return tx.get_dumper(v, PyFormat.TEXT).dump(v)
@@ -0,0 +1 @@
1
+ 0.18.3
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: half_orm
3
- Version: 0.18.2
3
+ Version: 0.18.3
4
4
  Summary: A simple PostgreSQL to Python mapper.
5
5
  Home-page: https://github.com/half-orm/half-orm
6
6
  Author: Joël Maïzi
@@ -1 +0,0 @@
1
- 0.18.2
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes