Exceptions

The library raises two families of exceptions:
  • gwenlake.exceptions.GwenlakeException for errors the library detects itself: no usable credentials, a handle that resolves to nothing, an incremental read that the dataset cannot answer.
  • httpx.HTTPStatusError when the API answers with an error status. Every resource calls raise_for_status() on the response, so a 403 or a 404 surfaces as this exception, with the response attached.

Status codes

The body of an error is {"detail": ...}.