Hi @anvil bump on this.
tonight the scheduled task failed again, with the (sadly) same recurrent scheme:
anvil.tables.TableError: Internal database error: ERROR: canceling statement due to user request
<running on the server>
called from /downlink/anvil/_server.py, line 42
called from server_module, line 670
called from server_module, line 219
Session ID: NAZEDJBFIPADV6X6BJ7VYNJPIAUFB2YZ
While the failing statement is still an add_row, this time it’s not the add_row on the log table (the fixes applied in this post are in place) but:
app_tables.esaw_files_buffer.add_row(envelope_id=documento['envelope_id'],
document_id=documento['audit_trail_id'],
file_name=file_name,
file_bytes=file_bytes, file_size=file_size)
This archives a PDF document in a buffer table.
Differently from the case of the rows added to the log table, this is not executed consecutively at fast pace, let say it’s executed once every 2 secs, for let say max 10 times (it depends on the number of docs to add to the buffer).
I’m not writing now to get advices on how to solve this particular specific problem, I need to understand the context:
- (to @anvil) no user (on my side) canceled the statement. What kind of error is that?
- (to @anvil) since march, I am constantly fighting with the database (this post and this other post where transaction fails while the operation is carried on single-user), while in more than 1 year being with Anvil (and in particular this very same application) I’ve never had such problems. Have you made significant changes on DB side? What are they?
- (to @anvil) is it preferred I ask these questions to support@anvil.works rather than here in the forums?
- (to the community): am I alone? Are you all going along “well as before” with database interaction?
Thanks