Skip to content

Conversation

flub
Copy link
Contributor

@flub flub commented Mar 21, 2023

This adds a result extension trait to explicitly set the last error,
which should be the default for the FFI. Currently not touching all
APIs since that's potentially disruptive and we're close to a release.

The logging story is messy, as described in the doc comment. We
should further clean this up and tidy up these APIs so it's more
obvious to people how to do the right thing.


This is an alternative to #4187, hopefully addressing @Hocuri's
fears. I believe these APIs need further cleaning up as described,
but let's leave that for after the release.

Closes #4186, #4178

Since this now does not affect anything other than core-internal:
#skip-changelog

This adds a result extension trait to explicitly set the last error,
which *should* be the default for the FFI.  Currently not touching all
APIs since that's potentially disruptive and we're close to a release.

The logging story is messy, as described in the doc comment.  We
should further clean this up and tidy up these APIs so it's more
obvious to people how to do the right thing.
@flub flub merged commit 9c15cd5 into master Mar 21, 2023
@flub flub deleted the flub/ffi-set-last-error branch March 21, 2023 12:37
@Hocuri
Copy link
Collaborator

Hocuri commented Mar 21, 2023

Nice 🎉!

r10s added a commit that referenced this pull request Aug 8, 2025
IMEX_PROGRESS(0) event is fired in case of errors,
however, the last error was not set in this case.

this is similar to the fix at #4195
and improves the error shown in the dialog for android and iOS;
desktop does not show an error dialog at all.
r10s added a commit that referenced this pull request Aug 8, 2025
IMEX_PROGRESS(0) event is fired in case of errors, however, the last
error was not set in this case.

this is similar to the fix at #4195
and improves the error shown in the dialog for android and iOS; desktop
does not show an error dialog at all.

<img width="320" alt="IMG_9995"
src="https://github.com/user-attachments/assets/7065fc3d-3f30-4691-b1b2-1950564a25e2"
/>

relates to deltachat/deltachat-android#3533
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

failing dc_receive_backup() lacks last error set

3 participants