Errors during synchronization

Every day I manually sync my .thunderbird email folder to an encrypted library on my company’s server. The sync almost always fails with these messages in the log:

[05/10/24 07:39:13] http-tx-mgr.c(939): libcurl failed to PUT https://basket.fi.infn.it/seafhttp/repo/d5f29533-2819-4a45-a71d-56bf2de2daa8/block/ec4d001d4dfd59c8a8e63f38bbae77d719dbeb35: Failed to open/read local data from file/application.
[05/10/24 07:39:13] http-tx-mgr.c(939): libcurl failed to PUT https://basket.fi.infn.it/seafhttp/repo/d5f29533-2819-4a45-a71d-56bf2de2daa8/block/fe693a59b4adc3383ac120e8ea49d964922f2ea7: Operation was aborted by an application callback.
[05/10/24 07:39:13] http-tx-mgr.c(939): libcurl failed to PUT https://basket.fi.infn.it/seafhttp/repo/d5f29533-2819-4a45-a71d-56bf2de2daa8/block/385be836ae0ae7c986a99e2505c389e78d3933ed: Operation was aborted by an application callback.
[05/10/24 07:39:13] http-tx-mgr.c(1165): Transfer repo 'd5f29533': ('normal', 'data') --> ('error', 'finished')
[05/10/24 07:39:13] sync-mgr.c(641): Repo '.thunderbird' sync state transition from uploading to 'error': 'Network error'.

I have to manually restart it several times before it finish successfully. What can I do to fix this:

I’m using Seafile client 9.0.5, curl 8.7.1, and the server is 6.0.7.