Skip to content

Commit

Permalink
Don't adapt python args validators to DRF action interface forms
Browse files Browse the repository at this point in the history
Type: trivial
  • Loading branch information
wesleykendall committed Jul 2, 2020
1 parent 64f1f37 commit 45011a4
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 21 deletions.
4 changes: 3 additions & 1 deletion daf/rest_framework.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,9 @@ def run(self):
request_args = self.request.data
form = self.form_class(request_args)
default_args = {**self.get_default_args(), **request_args}
form = djarg.forms.adapt(form, self.action.func, default_args)
form = djarg.forms.adapt(
form, self.action.func, default_args, clean=False
)
form.full_clean()

self.args = {**default_args, **form.cleaned_data}
Expand Down
35 changes: 16 additions & 19 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ python = ">=3.6,<4"
django = ">=2"
djangorestframework = "^3.0.0"
python-args = "^1.0.2"
django-args = "^1.2.0"
django-args = "^1.3.0"

[tool.poetry.dev-dependencies]
beautifulsoup4 = "^4.8.2"
Expand Down

0 comments on commit 45011a4

Please sign in to comment.