Issue #3843
closedServer translates null to "" for repo description, breaking api bindings
Description
On pulp 3, Using the generated swagger bindings, i was unable to fetch my repositories, throwing:
ArgumentError: invalid value for "description", the character length must be great than or equal to 1.
The problem was that my repositories had a 'null' description, but the api is not returning null, its returning empty string (""). There seems to be some validation on the model side of the apipie bindings that is getting tripped up on this.
Updated by jsherril@redhat.com over 6 years ago
The client side check that its doing is:
if !description.nil? && description.to_s.length < 1
fail ArgumentError, 'invalid value for "description", the character length must be great than or equal to 1.'
end
Updated by CodeHeeler over 6 years ago
- Triaged changed from No to Yes
- Sprint set to Sprint 39
Updated by dkliban@redhat.com over 6 years ago
- Sprint changed from Sprint 39 to Sprint 40
Updated by daviddavis over 6 years ago
I was unable to reproduce. Looking at the code, I think this might've been fixed in #3755. Can you regenerate the bindings and test again?
Updated by daviddavis over 6 years ago
- Status changed from NEW to CLOSED - WORKSFORME
Closing this as WORKSFORME to get it off the sprint. @jsherrill please let me know if you can reproduce this and I'll reopen it. Thanks.
Updated by ggainey over 4 years ago
- Tags Katello added
- Tags deleted (
Katello-P1)