Skip to content

Commit

Permalink
PICARD-2331: Fixed QNetworkReply error handling
Browse files Browse the repository at this point in the history
QNetworkReply.NetworkError.NoError no longer evaluates to False. Set error to None if there was no error.
  • Loading branch information
phw committed Oct 13, 2023
1 parent 20271dd commit d26569f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions picard/webservice/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -513,6 +513,7 @@ def _handle_reply(self, reply, request):
slow_down = (slow_down or response_code >= 500)

else:
error = None
redirect = reply.attribute(QNetworkRequest.Attribute.RedirectionTargetAttribute)
from_cache = reply.attribute(QNetworkRequest.Attribute.SourceIsFromCacheAttribute)
cached = ' (CACHED)' if from_cache else ''
Expand Down

0 comments on commit d26569f

Please sign in to comment.