Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix a case when builtin subclass is not converted back to the hinted type #494

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

george-zubrienko
Copy link
Collaborator

@george-zubrienko george-zubrienko commented Oct 12, 2023

Fixes #485

Simple change to use the constructor when type is one of the builtins

@github-actions
Copy link

github-actions bot commented Oct 12, 2023

Coverage

Coverage Report
FileStmtsMissCoverMissing
dataclasses_json
   cfg.py51492%80, 84–86
   core.py2621893%39–42, 52, 65, 67, 82, 84, 170, 198, 380–387, 391, 397
   mm.py2053085%33–36, 42–45, 53–56, 62–65, 88, 170–171, 176, 180, 184, 189, 193, 197, 205, 211, 216, 225, 230, 235, 244, 253–260
   stringcase.py25388%59, 76, 97
   undefined.py146299%25, 39
   utils.py1313673%12–25, 45–50, 61–65, 75, 100–101, 109–110, 125–133, 163, 182, 207
tests
   entities.py239399%22, 234, 240
   test_annotations.py814248%50–67, 78–102, 106–122
   test_api.py142497%88, 99, 139–140
   test_str_subclass.py22195%9
   test_union.py1311092%97–104, 118–125
TOTAL267215394% 

Tests Skipped Failures Errors Time
308 3 💤 0 ❌ 0 🔥 4.883s ⏱️

@george-zubrienko
Copy link
Collaborator Author

@matt035343 review? :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] from_json of class with attribute of list of types which inherit basic types results in wrong result
1 participant