Skip to content

Commit

Permalink
roll back key_case='AUTO' in docs
Browse files Browse the repository at this point in the history
* Roll back `key_case='AUTO'` in docs, as serialization for `v1` Opt-In might not default to `camelCase` in a future minor release
  • Loading branch information
rnag committed Jan 20, 2025
1 parent a6d7f9a commit 67bb128
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ for complex and *nested dataclass* models!
>>> from dataclass_wizard import JSONWizard
...
>>> @dataclass
... class MyClass(JSONWizard, key_case='AUTO'):
... class MyClass(JSONWizard):
... my_str: str | None
... is_active_tuple: tuple[bool, ...]
... list_of_int: list[int] = field(default_factory=list)
Expand Down
2 changes: 0 additions & 2 deletions dataclass_wizard/v1/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -270,8 +270,6 @@ def load_to_pattern(self, tp: TypeInfo, extras: Extras):
fn_gen = extras['fn_gen']
_locals = extras['locals']

assert 'cls' not in _locals

is_datetime \
= is_date \
= is_time \
Expand Down
4 changes: 2 additions & 2 deletions docs/common_use_cases/v1_alias.rst
Original file line number Diff line number Diff line change
Expand Up @@ -163,8 +163,8 @@ for bulk aliasing:
print(t.to_dict())
# > {'my_str': 'test', 'myDumpedBool': True, 'MyInt': 123, 'DumpedInt': 321}
AliasPath
---------
Alias Paths
-----------

Maps one or more nested JSON paths to a dataclass field. See documentation on :func:`AliasPath` for more details.

Expand Down

0 comments on commit 67bb128

Please sign in to comment.