Project

Profile

Help

Issue #3964

OpenAPI schema requires Progress Report suffix to be 1 char or longer

Added by dkliban@redhat.com about 1 year ago. Updated 6 months ago.

Status:
MODIFIED
Priority:
Normal
Category:
-
Sprint/Milestone:
Start date:
Due date:
Severity:
2. Medium
Version:
Platform Release:
Blocks Release:
OS:
Backwards Incompatible:
No
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
QA Contact:
Complexity:
Smash Test:
Verified:
No
Verification Required:
No
Sprint:
Sprint 42

Description

As a result of this, the bindings generated from the OpenAPI schema produce the following error:

>>> api.tasks_read('/pulp/api/v3/tasks/487f9f07-5056-413f-a7f6-1a59117e2b66/')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/api/pulp_api.py", line 7533, in tasks_read
    (data) = self.tasks_read_with_http_info(task_href, **kwargs)  # noqa: E501
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/api/pulp_api.py", line 7611, in tasks_read_with_http_info
    collection_formats=collection_formats)
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/api_client.py", line 322, in call_api
    _preload_content, _request_timeout)
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/api_client.py", line 161, in __call_api
    return_data = self.deserialize(response_data, response_type)
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/api_client.py", line 233, in deserialize
    return self.__deserialize(data, response_type)
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/api_client.py", line 272, in __deserialize
    return self.__deserialize_model(data, klass)
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/api_client.py", line 613, in __deserialize_model
    kwargs[attr] = self.__deserialize(value, attr_type)
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/api_client.py", line 250, in __deserialize
    for sub_data in data]
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/api_client.py", line 250, in <listcomp>
    for sub_data in data]
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/api_client.py", line 272, in __deserialize
    return self.__deserialize_model(data, klass)
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/api_client.py", line 615, in __deserialize_model
    instance = klass(**kwargs)
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/models/progress_report.py", line 71, in __init__
    self.suffix = suffix
  File "/home/vagrant/.virtualenvs/pulp/lib64/python3.6/site-packages/my_pulp3_client/models/progress_report.py", line 192, in suffix
    raise ValueError("Invalid value for `suffix`, length must be greater than or equal to `1`")  # noqa: E501
ValueError: Invalid value for `suffix`, length must be greater than or equal to `1`

The serializer needs to define 'allow_blank=True' for the suffix field.


Related issues

Related to Pulp - Issue #3755: allow_blank is not set to true for optional fields MODIFIED Actions
Related to Pulp - Test #4123: Test the generated API binds MODIFIED Actions

Associated revisions

Revision 29973ba5 View on GitHub
Added by dkliban@redhat.com about 1 year ago

Problem: suffix field is required in the serializer, but can be ''

Solution: set allow_blank=True in the serializer

closes: #3964
https://pulp.plan.io/issues/3964

Revision 29973ba5 View on GitHub
Added by dkliban@redhat.com about 1 year ago

Problem: suffix field is required in the serializer, but can be ''

Solution: set allow_blank=True in the serializer

closes: #3964
https://pulp.plan.io/issues/3964

Revision 29973ba5 View on GitHub
Added by dkliban@redhat.com about 1 year ago

Problem: suffix field is required in the serializer, but can be ''

Solution: set allow_blank=True in the serializer

closes: #3964
https://pulp.plan.io/issues/3964

History

#1 Updated by dkliban@redhat.com about 1 year ago

  • Sprint/Milestone set to 3.0
  • Tags Pulp 3, Pulp 3 MVP added

#2 Updated by daviddavis about 1 year ago

  • Triaged changed from No to Yes
  • Sprint set to Sprint 42

#3 Updated by dkliban@redhat.com about 1 year ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to dkliban@redhat.com

#4 Updated by dkliban@redhat.com about 1 year ago

  • Description updated (diff)
  • Status changed from ASSIGNED to POST
  • Triaged changed from Yes to No
  • Sprint deleted (Sprint 42)

#5 Updated by dkliban@redhat.com about 1 year ago

  • Triaged changed from No to Yes
  • Sprint set to Sprint 42

#6 Updated by dkliban@redhat.com about 1 year ago

  • Status changed from POST to MODIFIED

#7 Updated by daviddavis about 1 year ago

  • Related to Issue #3755: allow_blank is not set to true for optional fields added

#8 Updated by kersom 12 months ago

  • Related to Test #4123: Test the generated API binds added

#9 Updated by bmbouter 6 months ago

  • Tags deleted (Pulp 3, Pulp 3 MVP)

Please register to edit this issue

Also available in: Atom PDF