-
Notifications
You must be signed in to change notification settings - Fork 13
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
Pipeline Response Changes #282
base: development
Are you sure you want to change the base?
Pipeline Response Changes #282
Conversation
fields.extend([f"{k}={repr(v)}" for k, v in self.additional_fields.items()]) | ||
return f"PipelineResponse({', '.join(fields)})" | ||
|
||
def __contains__(self, key: str) -> bool: |
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.
above my comment regarding making this dict like object also applies here.
from aixplain.enums.asset_status import AssetStatus | ||
|
||
|
||
# def test_list_pipelines(): |
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.
All these tests are disabled somehow. Is that by purpose?
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.
The data is not being returned properly, so I commented some out to debug. Any idea why I could be getting success status, while no data is being returned?
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.
I have really no idea on that.
start = time.time() | ||
try: | ||
response = self.run_async(data, data_asset=data_asset, name=name, **kwargs) | ||
if response["status"] == "FAILED": | ||
if response["status"] == Status.FAILED: |
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.
Here, are we sure the value of "status" in the matching enum type or a string only?
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.
The enum makes sure that if it's passed in as string it turns it into enum object
end = time.time() | ||
response = self.__polling(poll_url, name=name, timeout=timeout, wait_time=wait_time) | ||
status = Status(polling_response["status"]) |
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.
Regarding above my comment, for example here the value of "status" not seems to a be enum. Best to make sure of it.
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.
Okay I'll check again
No description provided.