Bug 1450986
Summary: | [RFE] Could the ovirtsdk4.Error improved ? | ||
---|---|---|---|
Product: | [oVirt] ovirt-engine-sdk-python | Reporter: | Fabrice Bacchella <fabrice.bacchella> |
Component: | RFEs | Assignee: | Ondra Machacek <omachace> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Petr Kubica <pkubica> |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 4.1.3 | CC: | bugs, juan.hernandez, lsvaty, mgoldboi, mperina, oourfali, stirabos |
Target Milestone: | ovirt-4.1.3 | Keywords: | FutureFeature |
Target Release: | 4.1.4 | Flags: | rule-engine:
ovirt-4.1+
lsvaty: testing_plan_complete- mgoldboi: planning_ack+ mperina: devel_ack+ lsvaty: testing_ack+ |
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | python-ovirt-engine-sdk4-4.1.4 | Doc Type: | If docs needed, set a value |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2017-07-06 13:19:09 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | Infra | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Fabrice Bacchella
2017-05-15 13:57:32 UTC
Another use case where a smart exception would be useful: ovirtsdk4.Error: Error during SSO revoke server_error : UT000021: Session already invalidated I can catch this exception and transform it as a warning or a notice if details can be used, instead of having to use a brittle regex. Yes, that can be useful. I'd suggest to add two properties: 'code' and 'fault'. The first should be an integer containing the HTTP response code. The second should be an instance of the 'Fault' type, containing the detail and reason. Both should be optional, as certain errors won't have an HTTP error code or a fault (timeout, for example). Verified in python-ovirt-engine-sdk4-4.1.4-1.el7ev.x86_64 |