-
Notifications
You must be signed in to change notification settings - Fork 0
MPT-12840 Endpoint commerce agreements attachments #26
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
Conversation
0c44c49 to
51555c1
Compare
3483671 to
d86f918
Compare
d86f918 to
2c3600c
Compare
|
|
|
||
| def build_url( | ||
| self, | ||
| query_params: dict[str, Any] | None = None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can remove the comma to avoid splitting the code
| def _json_to_file_payload(resource_data: ResourceData) -> bytes: | ||
| return json.dumps( | ||
| resource_data, ensure_ascii=False, separators=(",", ":"), allow_nan=False | ||
| ).encode("utf-8") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As we've already discussed, at some point it would be good to move this
| files["_attachment_data"] = ( | ||
| None, | ||
| _json_to_file_payload(resource_data), | ||
| "application/json", | ||
| ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Umm… I believe we can also remove the comma to avoid splitting the code unnecessarily
| files["_attachment_data"] = ( | ||
| None, | ||
| _json_to_file_payload(resource_data), | ||
| "application/json", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same here
| service = AgreementsService(http_client=http_client) | ||
| assert hasattr(service, method) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| service = AgreementsService(http_client=http_client) | |
| assert hasattr(service, method) | |
| service = AgreementsService(http_client=http_client) | |
| assert hasattr(service, method) |
| service = AgreementsService(http_client=async_http_client) | ||
| assert hasattr(service, method) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| service = AgreementsService(http_client=async_http_client) | |
| assert hasattr(service, method) | |
| service = AgreementsService(http_client=async_http_client) | |
| assert hasattr(service, method) |
svazquezco
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apologies, I didn't do a deep review (holidays are coming 🌴 ) but it looks really good. Just a few boring comments....



Uh oh!
There was an error while loading. Please reload this page.