NixOS / nixpkgs

Nix Packages collection & NixOS
MIT License
17.31k stars 13.55k forks source link

evolution-ews: Crashes in GNOME #140853

Closed xbreak closed 1 year ago

xbreak commented 2 years ago

Describe the bug

Starting Evolution in GNOME with:

results in crash of the calendar (.evolution-cale) leading to other components to fail or "crash" as reported by gnome shell:

Oct 07 10:35:15 nixos .evolution-cale[95916]: Settings schema 'org.gnome.evolution.calendar' is not installed
Oct 07 10:35:16 nixos systemd-coredump[96849]: Process 95916 (.evolution-cale) of user 1000 dumped core.
Oct 07 10:35:16 nixos systemd[95752]: evolution-calendar-factory.service: Main process exited, code=killed, status=5/TRAP
Oct 07 10:35:16 nixos systemd[95752]: evolution-calendar-factory.service: Failed with result 'signal'.
Oct 07 10:35:16 nixos .gnome-shell-ca[95866]: The calendar backend for 'Personal' has crashed.
Oct 07 10:35:16 nixos .gnome-shell-ca[95866]: The calendar backend for 'Birthdays & Anniversaries' has crashed.
Oct 07 10:35:16 nixos .gnome-shell-ca[95866]: The calendar backend for 'Calendar' has crashed.

I'm not sure what is going on and have tried various configuration combinations.

Steps To Reproduce

I created a fresh test-user (see also config below) and did the following:

  1. Start GNOME and Evolution
  2. Add an Exchange Web Services account
  3. crash (although the main evolution process remains multiple components have failed or crashed)

edit Previously I observed that it crashed without evolution-ews, but that was a faulty conclusion based on that I removed plugin, but tested with same user account that was previously set up with an Exchange account (so there was some stored state).

Expected behavior

To not crash.

Additional context

evolution without evolution-ews works and also do not produce warning

Settings schema 'org.gnome.evolution.calendar' is not installed

"Minimized" NixOS config where I also tested


Core dump info:

$ coredumpctl info 95916 95810 PID: 95916 (.evolution-cale) UID: 1000 (test) GID: 100 (users) Signal: 5 (TRAP) Timestamp: Thu 2021-10-07 10:35:15 CEST (19min ago) Command Line: /nix/store/xz2sagk64wcjfja7wx1b4g3hyw4najp1-evolution-with-plugins/libexec/.evolution-calendar-factory-wrapped_ Executable: /nix/store/iv62wgv9ddn5dmqp3jr11l851x9k5wzq-evolution-data-server-3.40.4/libexec/.evolution-calendar-factory-wrapped Control Group: /user.slice/user-1000.slice/user@1000.service/app.slice/evolution-calendar-factory.service Unit: user@1000.service User Unit: evolution-calendar-factory.service Slice: user-1000.slice Owner UID: 1000 (test) Boot ID: c806bb1f69c643f483859014d302f1f3 Machine ID: 3129c2ed7f2145268480635abbde6a6d Hostname: nixos Storage: /var/lib/systemd/coredump/core.\x2eevolution-cale.1000.c806bb1f69c643f483859014d302f1f3.95916.1633595715000000.lz4 (inaccessible) Message: Process 95916 (.evolution-cale) of user 1000 dumped core.

       PID: 95810 (.gnome-shell-wr)
       UID: 1000 (test)
       GID: 100 (users)
    Signal: 11 (SEGV)
 Timestamp: Thu 2021-10-07 10:36:05 CEST (18min ago)

Command Line: /nix/store/vl329lbr5vfcr3xjvy3wm66yhcxjqp5g-gnome-shell-40.1/bin/gnome-shell Executable: /nix/store/vl329lbr5vfcr3xjvy3wm66yhcxjqp5g-gnome-shell-40.1/bin/.gnome-shell-wrapped Control Group: /user.slice/user-1000.slice/user@1000.service/session.slice/org.gnome.Shell@wayland.service Unit: user@1000.service User Unit: org.gnome.Shell@wayland.service Slice: user-1000.slice Owner UID: 1000 (test) Boot ID: c806bb1f69c643f483859014d302f1f3 Machine ID: 3129c2ed7f2145268480635abbde6a6d Hostname: nixos Storage: /var/lib/systemd/coredump/core.\x2egnome-shell-wr.1000.c806bb1f69c643f483859014d302f1f3.95810.1633595765000000.lz4 (inaccessible) Message: Process 95810 (.gnome-shell-wr) of user 1000 dumped core.

Additional journal logs immediately following the crash:

Oct 07 10:35:16 nixos .gnome-calendar[96230]: Error synchronizing client Oct 07 10:35:26 nixos systemd[95752]: evolution-addressbook-factory.service: Succeeded. Oct 07 10:35:38 nixos dbus-daemon[95759]: [session uid=1000 pid=95759] Activating via systemd: service name='org.gnome.evolution.dataserver.Calendar8' unit='evolution-c> Oct 07 10:35:38 nixos systemd[95752]: Starting Evolution calendar service... Oct 07 10:35:38 nixos .evolution-wrap[96637]: Your application did not unregister from D-Bus before destruction. Consider using g_application_run(). Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:140):client_data_unref: runtime check failed: (client_data->backend_died_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:141):client_data_unref: runtime check failed: (client_data->backend_error_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:142):client_data_unref: runtime check failed: (client_data->notify_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:140):client_data_unref: runtime check failed: (client_data->backend_died_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:141):client_data_unref: runtime check failed: (client_data->backend_error_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:142):client_data_unref: runtime check failed: (client_data->notify_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:140):client_data_unref: runtime check failed: (client_data->backend_died_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:141):client_data_unref: runtime check failed: (client_data->backend_error_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:142):client_data_unref: runtime check failed: (client_data->notify_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:140):client_data_unref: runtime check failed: (client_data->backend_died_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:141):client_data_unref: runtime check failed: (client_data->backend_error_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:142):client_data_unref: runtime check failed: (client_data->notify_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:140):client_data_unref: runtime check failed: (client_data->backend_died_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:141):client_data_unref: runtime check failed: (client_data->backend_error_handler_id == 0) Oct 07 10:35:38 nixos .evolution-wrap[96637]: (../src/e-util/e-client-cache.c:142):client_data_unref: runtime check failed: (client_data->notify_handler_id == 0) Oct 07 10:35:38 nixos systemd[95752]: app-gnome-org.gnome.Evolution-96637.scope: Succeeded. Oct 07 10:35:38 nixos systemd[95752]: app-gnome-org.gnome.Evolution-96637.scope: Consumed 5.528s CPU time. Oct 07 10:35:38 nixos dbus-daemon[95759]: [session uid=1000 pid=95759] Successfully activated service 'org.gnome.evolution.dataserver.Calendar8' Oct 07 10:35:38 nixos systemd[95752]: Started Evolution calendar service. Oct 07 10:35:39 nixos systemd[95752]: Started VTE child process 96876 launched by gnome-terminal-server process 96240. Oct 07 10:35:48 nixos systemd[95752]: evolution-calendar-factory.service: Succeeded.


### Notify maintainers

@dasj19

### Metadata
Please run `nix-shell -p nix-info --run "nix-info -m"` and paste the result.

```console
[test@system:~]$ nix-shell -p nix-info --run "nix-info -m"
- system: `"x86_64-linux"`
 - host os: `Linux 5.10.70, NixOS, 21.05.3509.7daf35532d2 (Okapi)`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.3.15`
 - channels(root): `"nixos-21.05.3509.7daf35532d2"`
 - nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixos`

Maintainer information:

# a list of nixpkgs attributes affected by the problem
attribute: [ evolution, evolution-ews ]
# a list of nixos modules affected by the problem
module:
hmenke commented 2 years ago

Cannot reproduce on 21.05. I'm using Evolution every day (without ews).

xbreak commented 2 years ago

@hmenke: Do you have the message Settings schema 'org.gnome.evolution.calendar' is not installed in the logs?

edit I re-ran tests without evolution-ews and without previously having set up an ews account which works fine, also without schema warning. So this problem seems limited to evolution with evolution-ews. Description and title was updated accordingly.

stale[bot] commented 2 years ago

I marked this as stale due to inactivity. → More info

xbreak commented 2 years ago

Issue is still present on NixOS 22.05.

nix-shell -p nix-info --run "nix-info -m"
 - system: `"x86_64-linux"`
 - host os: `Linux 5.15.49, NixOS, 22.05 (Quokka), 22.05.1322.915f5a5b3cc`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.8.1`
 - channels(test) `"home-manager-22.05.tar.gz, nixpkgs-unstable"`
 - channels(root): `"nixos-22.05.1322.915f5a5b3cc"`
 - nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixos`
lugeha commented 2 years ago

Still happening

Does it need a similar patch for gsettings like in evolution-data-server?

https://github.com/NixOS/nixpkgs/blob/nixos-22.05/pkgs/desktops/gnome/core/evolution-data-server/hardcode-gsettings.patch

 - system: `"x86_64-linux"`
 - host os: `Linux 5.19.2-zen1, NixOS, 22.11 (Raccoon), 22.11.20220822.54060e8`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.10.3`
 - channels(root): `"nixos"`
 - nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixos`
× evolution-calendar-factory.service - Evolution calendar service
     Loaded: loaded (/etc/systemd/user/evolution-calendar-factory.service; linked-runtime; preset: enabled)
     Active: failed (Result: core-dump) since Tue 2022-08-23 21:05:42 AEST; 7min ago
   Duration: 28.614s
    Process: 2492 ExecStart=/nix/store/w775fm3095h4ik892ig6hp78700zg1vf-evolution-with-plugins/libexec/evolution-calendar-factory (code=dumped, signal=TRAP)
   Main PID: 2492 (code=dumped, signal=TRAP)
        CPU: 442ms

Aug 23 21:05:14 pecan systemd[1626]: Starting Evolution calendar service...
Aug 23 21:05:14 pecan systemd[1626]: Started Evolution calendar service.
Aug 23 21:05:42 pecan .evolution-cale[2492]: Settings schema 'org.gnome.evolution.calendar' is not installed
Aug 23 21:05:42 pecan systemd-coredump[3206]: Process 2492 (.evolution-cale) of user 1000 dumped core.

                                              Module linux-vdso.so.1 with build-id 0830fa34821d3ec32952f8087af00776920d1c2a
                                              Module p11-kit-trust.so without build-id.
                                              Module libgmp.so.10 without build-id.
                                              Module libhogweed.so.6 without build-id.
                                              Module libnettle.so.8 without build-id.
                                              Module libgnutls.so.30 without build-id.
                                              Module libgiognutls.so without build-id.
                                              Module libgiognomeproxy.so without build-id.
                                              Module libduktape.so.207 without build-id.
                                              Module libproxy.so.1 without build-id.
                                              Module libcamelimapx.so without build-id.
                                              Module libcamelmicrosoft365.so without build-id.
                                              Module libcamelews-priv.so without build-id.
                                              Module libcamelews.so without build-id.
                                              Module libcamelpop3.so without build-id.
                                              Module libcamelsmtp.so without build-id.
                                              Module libcamellocal.so without build-id.
                                              Module libcamelnntp.so without build-id.
                                              Module libcamelsendmail.so without build-id.
                                              Module libdconfsettings.so without build-id.
                                              Module libevolution-microsoft365.so without build-id.
                                              Module libecalbackendmicrosoft365.so without build-id.
                                              Module libuuid.so.1 with build-id 8a818610ed76e05d2c5141c1c57feb56f2f56bac
                                              Module libzstd.so.1 without build-id.
                                              Module libelf.so.1 with build-id b5ede684ba0312d4bce47458fd17230e1164ed85
                                              Module liblzma.so.5 without build-id.
                                              Module libgudev-1.0.so.0 without build-id.
                                              Module libevdev.so.2 without build-id.
                                              Module libICE.so.6 without build-id.
                                              Module libSM.so.6 without build-id.
                                              Module libX11-xcb.so.1 without build-id.
                                              Module liborc-0.4.so.0 without build-id.
                                              Module libdw.so.1 with build-id 04eeb258236f49c140ff03e2b065fa686df07332
                                              Module libunwind.so.8 without build-id.
                                              Module libwoff2common.so.1.0.2 without build-id.
                                              Module libcrypto.so.1.1 with build-id 8f174298c8207ebf67978e6a893bd26cba89d5af
                                              Module libssl.so.1.1 with build-id 4d2c4dd746b27f4f9d06b43df602d52a38c25d60
                                              Module libsasl2.so.3 without build-id.
                                              Module libaspell.so.15 without build-id.
                                              Module libudev.so.1 without build-id.
                                              Module libxkbregistry.so.0 without build-id.
                                              Module libseccomp.so.2 without build-id.
                                              Module libmanette-0.2.so.0 without build-id.
                                              Module libwayland-server.so.0 with build-id 4b0b8ed4c3daa56e2281b0a16aa589e1fb73131f
                                              Module libXt.so.6 without build-id.
                                              Module libXdamage.so.1 without build-id.
                                              Module libtasn1.so.6 without build-id.
                                              Module libwebp.so.7 without build-id.
                                              Module libwebpdemux.so.2 without build-id.
                                              Module libopenjp2.so.7 without build-id.
                                              Module libgstfft-1.0.so.0 without build-id.
                                              Module libgstgl-1.0.so.0 without build-id.
                                              Module libgstvideo-1.0.so.0 without build-id.
                                              Module libgsttag-1.0.so.0 without build-id.
                                              Module libgstaudio-1.0.so.0 without build-id.
                                              Module libgstpbutils-1.0.so.0 without build-id.
                                              Module libgstreamer-1.0.so.0 without build-id.
                                              Module libgstbase-1.0.so.0 without build-id.
                                              Module libgstapp-1.0.so.0 without build-id.
                                              Module libharfbuzz-icu.so.0 without build-id.
                                              Module libwoff2dec.so.1.0.2 without build-id.
                                              Module liblcms2.so.2 without build-id.
                                              Module libGLESv2.so.2 without build-id.
                                              Module libxslt.so.1 without build-id.
                                              Module libnotify.so.4 without build-id.
                                              Module libatomic.so.1 without build-id.
                                              Module libWPEBackend-fdo-1.0.so.1 without build-id.
                                              Module libwpe-1.0.so.1 without build-id.
                                              Module libldap.so.2 without build-id.
                                              Module liblber.so.2 without build-id.
                                              Module libcmark.so.0.30.2 without build-id.
                                              Module libgspell-1.so.2 without build-id.
                                              Module libenchant-2.so.2 without build-id.
                                              Module libgnomecanvas.so without build-id.
                                              Module libessmime.so without build-id.
                                              Module libevolution-smime.so without build-id.
                                              Module libemail-engine.so without build-id.
                                              Module libevolution-mail-formatter.so without build-id.
                                              Module libeabutil.so without build-id.
                                              Module libecontactprint.so without build-id.
                                              Module libeabwidgets.so without build-id.
                                              Module libecontacteditor.so without build-id.
                                              Module libecontactlisteditor.so without build-id.
                                              Module libgnome-desktop-3.so.19 with build-id fb59e33c37c5e658efb98e04beeed3f77c83212b
                                              Module libgcr-ui-3.so.1 without build-id.
                                              Module libgailutil-3.so.0 with build-id 1b2a556e9f926fa15ff7bba1bb3d7b2887cd6f10
                                              Module libevolution-mail-composer.so without build-id.
                                              Module libevolution-calendar-importers.so without build-id.
                                              Module libjavascriptcoregtk-4.0.so.18 with build-id 2220be0cac4f6adaf619db227eebe68acef92fe2
                                              Module libwebkit2gtk-4.0.so.37 with build-id a26c7cc97df32ddf2825685b8414780a7d6851cc
                                              Module libedataserverui-1.2.so.3 without build-id.
                                              Module libevolution-util.so without build-id.
                                              Module libevolution-shell.so without build-id.
                                              Module libevolution-calendar.so without build-id.
                                              Module libevolution-ews.so without build-id.
                                              Module libecalbackendews.so without build-id.
                                              Module libecalbackendcaldav.so without build-id.
                                              Module libecalbackendwebdavnotes.so without build-id.
                                              Module libecalbackendhttp.so without build-id.
                                              Module libboost_system.so.1.79.0 without build-id.
                                              Module libboost_date_time.so.1.79.0 without build-id.
                                              Module libprotobuf.so.30 without build-id.
                                              Module libboost_thread.so.1.79.0 without build-id.
                                              Module libphonenumber.so.8 without build-id.
                                              Module libebook-contacts-1.2.so.3 without build-id.
                                              Module libedata-book-1.2.so.26 without build-id.
                                              Module libebook-1.2.so.20 without build-id.
                                              Module libecalbackendcontacts.so without build-id.
                                              Module libecalbackendgtasks.so without build-id.
                                              Module libgeocode-glib.so.0 without build-id.
                                              Module libgweather-4.so.0 without build-id.
                                              Module libecalbackendweather.so without build-id.
                                              Module libecalbackendfile.so without build-id.
                                              Module libgvfscommon.so without build-id.
                                              Module libgvfsdbus.so without build-id.
                                              Module libcap.so.2 without build-id.
                                              Module libsystemd.so.0 without build-id.
                                              Module libGLX.so.0 without build-id.
                                              Module libXdmcp.so.6 without build-id.
                                              Module libXau.so.6 without build-id.
                                              Module libGLdispatch.so.0 without build-id.
                                              Module libdatrie.so.1 without build-id.
                                              Module libatspi.so.0 without build-id.
                                              Module libdbus-1.so.3 without build-id.
                                              Module libexpat.so.1 without build-id.
                                              Module libbz2.so.1 without build-id.
                                              Module libblkid.so.1 with build-id 68b59c20d25c653ba37434be751f154a478fd697
                                              Module libbrotlicommon.so.1 without build-id.
                                              Module libidn2.so.0 without build-id.
                                              Module libunistring.so.2 without build-id.
                                              Module libgpg-error.so.0 without build-id.
                                              Module libresolv.so.2 with build-id 11c70ee6c9611a11a4dabb9904adeec593e536c8
                                              Module libkeyutils.so.1 without build-id.
                                              Module libkrb5support.so.0 without build-id.
                                              Module ld-linux-x86-64.so.2 with build-id 5fc82d34f4b3f2404903a583cb1189b544ffd180
                                              Module libjpeg.so.62 without build-id.
                                              Module libGL.so.1 without build-id.
                                              Module libXrender.so.1 without build-id.
                                              Module libxcb-render.so.0 without build-id.
                                              Module libxcb.so.1 without build-id.
                                              Module libxcb-shm.so.0 without build-id.
                                              Module libpng16.so.16 without build-id.
                                              Module libEGL.so.1 without build-id.
                                              Module libpixman-1.so.0 with build-id 87f06abd5a28da775de4b51068d2c654aca4cb8f
                                              Module libgraphite2.so.3 without build-id.
                                              Module libfreetype.so.6 without build-id.
                                              Module libthai.so.0 without build-id.
                                              Module libXinerama.so.1 without build-id.
                                              Module libXrandr.so.2 without build-id.
                                              Module libXcomposite.so.1 without build-id.
                                              Module libXcursor.so.1 without build-id.
                                              Module libXext.so.6 without build-id.
                                              Module libwayland-egl.so.1 with build-id 112c8a31477fa3708debaa78e9ba8daaea96dbd9
                                              Module libwayland-cursor.so.0 with build-id 1bf9b8cc744bdbfdcd5920311d7e2e3b41d1561a
                                              Module libwayland-client.so.0 with build-id e2447f56376e8019b3bf49694b2da6b86ccc8740
                                              Module libxkbcommon.so.0 without build-id.
                                              Module libXfixes.so.3 without build-id.
                                              Module libtracker-sparql-3.0.so.0 without build-id.
                                              Module libatk-bridge-2.0.so.0 without build-id.
                                              Module libX11.so.6 without build-id.
                                              Module libXi.so.6 without build-id.
                                              Module libepoxy.so.0 without build-id.
                                              Module libfribidi.so.0 without build-id.
                                              Module libfontconfig.so.1 without build-id.
                                              Module libpangoft2-1.0.so.0 without build-id.
                                              Module librt.so.1 with build-id 4bde1e8bce2352c3c84eca5b201a6a693bc258a9
                                              Module libdl.so.2 with build-id 46c1368a8c4898d3e8539d3966d69d27d5a84f7d
                                              Module libpcre.so.1 without build-id.
                                              Module libffi.so.8 without build-id.
                                              Module libselinux.so.1 without build-id.
                                              Module libmount.so.1 with build-id 700b69d8f3fda0c1ae7ae142e4081d6eccc1218f
                                              Module libbrotlidec.so.1 without build-id.
                                              Module libpsl.so.5 without build-id.
                                              Module libgcrypt.so.20 without build-id.
                                              Module libc.so.6 with build-id ffd9cab0fc1cbb4867229b47b440411c9afaa9aa
                                              Module libpthread.so.0 with build-id 217ec424ec584feb4eb71506c6b6edec749edb69
                                              Module libgcc_s.so.1 without build-id.
                                              Module libm.so.6 with build-id b27928d11f112c6e9f4fbed32607d366dc8da549
                                              Module libstdc++.so.6 without build-id.
                                              Module libedbus-private.so without build-id.
                                              Module libgoa-1.0.so.0 without build-id.
                                              Module libgdata.so.22 without build-id.
                                              Module libjson-glib-1.0.so.0 without build-id.
                                              Module libicudata.so.71 without build-id.
                                              Module libicuuc.so.71 without build-id.
                                              Module libicui18n.so.71 without build-id.
                                              Module libgssapi_krb5.so.2 without build-id.
                                              Module libcom_err.so.3 without build-id.
                                              Module libk5crypto.so.3 without build-id.
                                              Module libkrb5.so.3 without build-id.
                                              Module libsqlite3.so.0 with build-id b58ace329f7fd9b26607a80ddbe929c118725fba
                                              Module libcamel-1.2.so.63 without build-id.
                                              Module libp11-kit.so.0 without build-id.
                                              Module libgck-1.so.0 without build-id.
                                              Module libgcr-base-3.so.1 without build-id.
                                              Module libedataserver-1.2.so.26 without build-id.
                                              Module libecal-2.0.so.1 without build-id.
                                              Module libdb-5.3.so without build-id.
                                              Module libebackend-1.2.so.10 without build-id.
                                              Module libgdk_pixbuf-2.0.so.0 with build-id 4048674b389bc30b58c1178a98cd0c9a956246b0
                                              Module libcairo.so.2 with build-id b2d58976307b0df71e78dc5e465a3ba2214be1f2
                                              Module libcairo-gobject.so.2 with build-id 2c44e9da746131ecb4c844e1a62db7df6caac6f0
                                              Module libatk-1.0.so.0 without build-id.
                                              Module libharfbuzz.so.0 without build-id.
                                              Module libpango-1.0.so.0 without build-id.
                                              Module libpangocairo-1.0.so.0 without build-id.
                                              Module libz.so.1 without build-id.
                                              Module libgdk-3.so.0 with build-id e2406830eca8ed79211ab52da817641cc9dc4363
                                              Module libgtk-3.so.0 with build-id 4f834799f6de98bcc51a1114b138205b83183b50
                                              Module libicalvcal.so.3 without build-id.
                                              Module libicalss.so.3 without build-id.
                                              Module libical.so.3 without build-id.
                                              Module libical-glib.so.3 without build-id.
                                              Module libnspr4.so without build-id.
                                              Module libplc4.so without build-id.
                                              Module libplds4.so without build-id.
                                              Module libnssutil3.so without build-id.
                                              Module libnss3.so without build-id.
                                              Module libsmime3.so without build-id.
                                              Module libssl3.so without build-id.
                                              Module libxml2.so.2 without build-id.
                                              Module libglib-2.0.so.0 with build-id 781910b7531dc4ca375e21e5088a6e1c244d2554
                                              Module libgobject-2.0.so.0 with build-id 268dd62009d41b20688beec7d059a6a5c7de8f15
                                              Module libgio-2.0.so.0 with build-id d35c70155f65cde93965fc6c2288419755460d9e
                                              Module libgmodule-2.0.so.0 with build-id 61f01add69c982c3af52f82480ad29fd03000e4b
                                              Module libsoup-2.4.so.1 without build-id.
                                              Module libsecret-1.so.0 without build-id.
                                              Module libedata-cal-2.0.so.1 without build-id.
                                              Module .evolution-calendar-factory-wrapped without build-id.
                                              Stack trace of thread 3138:
                                              #0  0x00007ff7969ab19f g_log_structured_array (libglib-2.0.so.0 + 0x5e19f)
                                              #1  0x00007ff7969ab5b5 g_log_default_handler (libglib-2.0.so.0 + 0x5e5b5)
                                              #2  0x00007ff7969ab80d g_logv (libglib-2.0.so.0 + 0x5e80d)
                                              #3  0x00007ff7969abaef g_log (libglib-2.0.so.0 + 0x5eaef)
                                              #4  0x00007ff796be1e3e g_settings_set_property (libgio-2.0.so.0 + 0xf9e3e)
                                              #5  0x00007ff796aa2aa6 object_set_property (libgobject-2.0.so.0 + 0x1baa6)
                                              #6  0x00007ff796aa2ecc g_object_new_internal (libgobject-2.0.so.0 + 0x1becc)
                                              #7  0x00007ff796aa4818 g_object_new_valist (libgobject-2.0.so.0 + 0x1d818)
                                              #8  0x00007ff796aa4d49 g_object_new (libgobject-2.0.so.0 + 0x1dd49)
                                              #9  0x00007ff782347d08 e_util_ref_settings (libevolution-util.so + 0x147d08)
                                              #10 0x00007ff7826dd3e8 calendar_config_get_icaltimezone (libevolution-calendar.so + 0x483e8)
                                              #11 0x00007ff782c0232d ecb_ews_get_items_sync (libecalbackendews.so + 0x1632d)
                                              #12 0x00007ff782c02c4e ecb_ews_fetch_items_sync (libecalbackendews.so + 0x16c4e)
                                              #13 0x00007ff782c037b0 ecb_ews_get_changes_sync (libecalbackendews.so + 0x177b0)
                                              #14 0x00007ff796e0b9aa e_cal_meta_backend_get_changes_sync (libedata-cal-2.0.so.1 + 0x349aa)
                                              #15 0x00007ff796e10d30 ecmb_refresh_internal_sync (libedata-cal-2.0.so.1 + 0x39d30)
                                              #16 0x00007ff796df3b75 cal_backend_dispatch_thread (libedata-cal-2.0.so.1 + 0x1cb75)
                                              #17 0x00007ff7969cef34 g_thread_pool_thread_proxy (libglib-2.0.so.0 + 0x81f34)
                                              #18 0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #19 0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #20 0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 2492:
                                              #0  0x00007ff7921026c9 __poll (libc.so.6 + 0x1026c9)
                                              #1  0x00007ff7969a403e g_main_context_iterate.constprop.0 (libglib-2.0.so.0 + 0x5703e)
                                              #2  0x00007ff7969a4393 g_main_loop_run (libglib-2.0.so.0 + 0x57393)
                                              #3  0x00007ff7957dcfa9 dbus_server_run_server (libebackend-1.2.so.10 + 0x26fa9)
                                              #4  0x00007ff7945cd80a ffi_call_unix64 (libffi.so.8 + 0x780a)
                                              #5  0x00007ff7945cc943 ffi_call_int (libffi.so.8 + 0x6943)
                                              #6  0x00007ff796a9e3bd g_cclosure_marshal_generic_va (libgobject-2.0.so.0 + 0x173bd)
                                              #7  0x00007ff796a9d849 _g_closure_invoke_va (libgobject-2.0.so.0 + 0x16849)
                                              #8  0x00007ff796ab6153 g_signal_emit_valist (libgobject-2.0.so.0 + 0x2f153)
                                              #9  0x00007ff796ab641f g_signal_emit (libgobject-2.0.so.0 + 0x2f41f)
                                              #10 0x00007ff7957dd487 e_dbus_server_run (libebackend-1.2.so.10 + 0x27487)
                                              #11 0x000000000040227e main (.evolution-calendar-factory-wrapped + 0x227e)
                                              #12 0x00007ff79202924e __libc_start_call_main (libc.so.6 + 0x2924e)
                                              #13 0x00007ff792029309 __libc_start_main@@GLIBC_2.34 (libc.so.6 + 0x29309)
                                              #14 0x0000000000402365 _start (.evolution-calendar-factory-wrapped + 0x2365)

                                              Stack trace of thread 2548:
                                              #0  0x00007ff792107d3d syscall (libc.so.6 + 0x107d3d)
                                              #1  0x00007ff7969f7f0f g_cond_wait (libglib-2.0.so.0 + 0xaaf0f)
                                              #2  0x00007ff79697277b g_async_queue_pop_intern_unlocked (libglib-2.0.so.0 + 0x2577b)
                                              #3  0x00007ff7969cef07 g_thread_pool_thread_proxy (libglib-2.0.so.0 + 0x81f07)
                                              #4  0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #5  0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #6  0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 2511:
                                              #0  0x00007ff7921026c9 __poll (libc.so.6 + 0x1026c9)
                                              #1  0x00007ff7969a403e g_main_context_iterate.constprop.0 (libglib-2.0.so.0 + 0x5703e)
                                              #2  0x00007ff7969a415f g_main_context_iteration (libglib-2.0.so.0 + 0x5715f)
                                              #3  0x00007ff7969a41b1 glib_worker_main (libglib-2.0.so.0 + 0x571b1)
                                              #4  0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #5  0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #6  0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 2557:
                                              #0  0x00007ff792107d3d syscall (libc.so.6 + 0x107d3d)
                                              #1  0x00007ff7969f7f0f g_cond_wait (libglib-2.0.so.0 + 0xaaf0f)
                                              #2  0x00007ff79697277b g_async_queue_pop_intern_unlocked (libglib-2.0.so.0 + 0x2577b)
                                              #3  0x00007ff7969cef07 g_thread_pool_thread_proxy (libglib-2.0.so.0 + 0x81f07)
                                              #4  0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #5  0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #6  0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 2561:
                                              #0  0x00007ff792107d3d syscall (libc.so.6 + 0x107d3d)
                                              #1  0x00007ff7969f7f0f g_cond_wait (libglib-2.0.so.0 + 0xaaf0f)
                                              #2  0x00007ff79697277b g_async_queue_pop_intern_unlocked (libglib-2.0.so.0 + 0x2577b)
                                              #3  0x00007ff7969cef07 g_thread_pool_thread_proxy (libglib-2.0.so.0 + 0x81f07)
                                              #4  0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #5  0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #6  0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 2550:
                                              #0  0x00007ff7921026c9 __poll (libc.so.6 + 0x1026c9)
                                              #1  0x00007ff7969a403e g_main_context_iterate.constprop.0 (libglib-2.0.so.0 + 0x5703e)
                                              #2  0x00007ff7969a4393 g_main_loop_run (libglib-2.0.so.0 + 0x57393)
                                              #3  0x00007ff782b92e0e e_ews_soup_thread (libevolution-ews.so + 0x28e0e)
                                              #4  0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #5  0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #6  0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 2861:
                                              #0  0x00007ff7921026c9 __poll (libc.so.6 + 0x1026c9)
                                              #1  0x00007ff796b8cb3e g_socket_condition_timed_wait (libgio-2.0.so.0 + 0xa4b3e)
                                              #2  0x00007ff796b8dacf g_socket_receive_with_timeout (libgio-2.0.so.0 + 0xa5acf)
                                              #3  0x00007ff796b6887d g_input_stream_read (libgio-2.0.so.0 + 0x8087d)
                                              #4  0x00007ff778529b5c g_tls_connection_gnutls_pull_func (libgiognutls.so + 0xdb5c)
                                              #5  0x00007ff778248438 _gnutls_io_read_buffered (libgnutls.so.30 + 0x48438)
                                              #6  0x00007ff77823e0ce _gnutls_recv_in_buffers (libgnutls.so.30 + 0x3e0ce)
                                              #7  0x00007ff7782406a2 _gnutls_recv_int (libgnutls.so.30 + 0x406a2)
                                              #8  0x00007ff77852a4f0 g_tls_connection_gnutls_read (libgiognutls.so + 0xe4f0)
                                              #9  0x00007ff77853250e g_tls_connection_base_read (libgiognutls.so + 0x1650e)
                                              #10 0x00007ff7785334d3 g_tls_input_stream_read (libgiognutls.so + 0x174d3)
                                              #11 0x00007ff796b6887d g_input_stream_read (libgio-2.0.so.0 + 0x8087d)
                                              #12 0x00007ff796b6887d g_input_stream_read (libgio-2.0.so.0 + 0x8087d)
                                              #13 0x00007ff796d0eb56 soup_filter_input_stream_read_until (libsoup-2.4.so.1 + 0x3eb56)
                                              #14 0x00007ff796d0ee53 soup_filter_input_stream_read_line (libsoup-2.4.so.1 + 0x3ee53)
                                              #15 0x00007ff796d1af9e io_read (libsoup-2.4.so.1 + 0x4af9e)
                                              #16 0x00007ff796d1b721 io_run_until (libsoup-2.4.so.1 + 0x4b721)
                                              #17 0x00007ff796d1c2b4 io_run (libsoup-2.4.so.1 + 0x4c2b4)
                                              #18 0x00007ff796d18944 soup_message_send_request (libsoup-2.4.so.1 + 0x48944)
                                              #19 0x00007ff796d2c97c soup_session_process_queue_item.part.0 (libsoup-2.4.so.1 + 0x5c97c)
                                              #20 0x00007ff796d2cd55 soup_session_real_send_message (libsoup-2.4.so.1 + 0x5cd55)
                                              #21 0x00007ff782bbabf6 e_ews_notification_unsubscribe_folder_sync.isra.0 (libevolution-ews.so + 0x50bf6)
                                              #22 0x00007ff782bbb270 e_ews_notification_get_events_thread (libevolution-ews.so + 0x51270)
                                              #23 0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #24 0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #25 0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 2513:
                                              #0  0x00007ff7921026c9 __poll (libc.so.6 + 0x1026c9)
                                              #1  0x00007ff7969a403e g_main_context_iterate.constprop.0 (libglib-2.0.so.0 + 0x5703e)
                                              #2  0x00007ff7969a4393 g_main_loop_run (libglib-2.0.so.0 + 0x57393)
                                              #3  0x00007ff796c060f6 gdbus_shared_thread_func (libgio-2.0.so.0 + 0x11e0f6)
                                              #4  0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #5  0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #6  0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 2538:
                                              #0  0x00007ff7921026c9 __poll (libc.so.6 + 0x1026c9)
                                              #1  0x00007ff7969a403e g_main_context_iterate.constprop.0 (libglib-2.0.so.0 + 0x5703e)
                                              #2  0x00007ff7969a4393 g_main_loop_run (libglib-2.0.so.0 + 0x57393)
                                              #3  0x00007ff795515fc4 source_registry_object_manager_thread (libedataserver-1.2.so.26 + 0x6bfc4)
                                              #4  0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #5  0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #6  0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 3135:
                                              #0  0x00007ff792107d3d syscall (libc.so.6 + 0x107d3d)
                                              #1  0x00007ff7969f7f0f g_cond_wait (libglib-2.0.so.0 + 0xaaf0f)
                                              #2  0x00007ff79697277b g_async_queue_pop_intern_unlocked (libglib-2.0.so.0 + 0x2577b)
                                              #3  0x00007ff7969cef07 g_thread_pool_thread_proxy (libglib-2.0.so.0 + 0x81f07)
                                              #4  0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #5  0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #6  0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 2537:
                                              #0  0x00007ff7921026c9 __poll (libc.so.6 + 0x1026c9)
                                              #1  0x00007ff7969a403e g_main_context_iterate.constprop.0 (libglib-2.0.so.0 + 0x5703e)
                                              #2  0x00007ff7969a415f g_main_context_iteration (libglib-2.0.so.0 + 0x5715f)
                                              #3  0x00007ff77b7c342d dconf_gdbus_worker_thread (libdconfsettings.so + 0xb42d)
                                              #4  0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #5  0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #6  0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 2546:
                                              #0  0x00007ff792107d3d syscall (libc.so.6 + 0x107d3d)
                                              #1  0x00007ff7969f7f0f g_cond_wait (libglib-2.0.so.0 + 0xaaf0f)
                                              #2  0x00007ff79697277b g_async_queue_pop_intern_unlocked (libglib-2.0.so.0 + 0x2577b)
                                              #3  0x00007ff7969cef07 g_thread_pool_thread_proxy (libglib-2.0.so.0 + 0x81f07)
                                              #4  0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #5  0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #6  0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 2558:
                                              #0  0x00007ff7921026c9 __poll (libc.so.6 + 0x1026c9)
                                              #1  0x00007ff7969a403e g_main_context_iterate.constprop.0 (libglib-2.0.so.0 + 0x5703e)
                                              #2  0x00007ff7969a4393 g_main_loop_run (libglib-2.0.so.0 + 0x57393)
                                              #3  0x00007ff782ddedf4 book_client_dbus_thread (libebook-1.2.so.20 + 0x13df4)
                                              #4  0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #5  0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #6  0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)

                                              Stack trace of thread 3136:
                                              #0  0x00007ff792107d3d syscall (libc.so.6 + 0x107d3d)
                                              #1  0x00007ff7969f8032 g_cond_wait_until (libglib-2.0.so.0 + 0xab032)
                                              #2  0x00007ff796972761 g_async_queue_pop_intern_unlocked (libglib-2.0.so.0 + 0x25761)
                                              #3  0x00007ff7969cf08a g_thread_pool_thread_proxy (libglib-2.0.so.0 + 0x8208a)
                                              #4  0x00007ff7969ce63d g_thread_proxy (libglib-2.0.so.0 + 0x8163d)
                                              #5  0x00007ff792088e86 start_thread (libc.so.6 + 0x88e86)
                                              #6  0x00007ff79210fc60 __clone3 (libc.so.6 + 0x10fc60)
                                              ELF object binary architecture: AMD x86-64
Aug 23 21:05:42 pecan systemd[1626]: evolution-calendar-factory.service: Main process exited, code=dumped, status=5/TRAP
Aug 23 21:05:42 pecan systemd[1626]: evolution-calendar-factory.service: Failed with result 'core-dump'.
flintflump commented 1 year ago

@symphorien Shouldn't this be fixed by #190960? Or is this a different issue?

I'm asking since I can still reproduce the crash on current NixOS unstable and assumed that it should work by now.

symphorien commented 1 year ago

sorry I lost access to my ews account, so I can't help.

flintflump commented 1 year ago

@blitz @jtojnar Are you able to help here, since you were involved in the ews gsettings patch?

Can I provide further information to find the cause of the problem? Does anyone have any guesses what the problem might be?

Thank you all for your great work anyways. :)

blitz commented 1 year ago

I see the same issue on my daily driver. :(

jtojnar commented 1 year ago

Yeah, I would expect it to be fixed by https://github.com/NixOS/nixpkgs/pull/190960.

Try installing debug symbols:

{ pkgs, ... }:
let
  evolution-ews = pkgs.evolution-ews.overrideAttrs (attrs: {
    separateDebugInfo = true;
  });
in
{
  environment.enableDebugInfo = true;
  environment.systemPackages = [
    gdb
    # Install debug symbols
    evolution-ews
  ];
  programs.evolution.plugins = [
    evolution-ews
  ];
}

Then you should get a stack trace if you enter bt into coredumpctl gdb after the crash. That should point you to appropriate place in evolution-ews source code.

Maybe there is still some settings use that the auto-generated patch does not cover.

flintflump commented 1 year ago

Thank you for your time. I tried to investigate this issue further based on your comments.

With bt, I got the following backtrace:

(gdb) bt
#0  0x00007fc96fa30dcf in g_log_structured_array () from /nix/store/mxn46y68rsmx83qcraivfx2fmzx4aqc4-glib-2.74.1/lib/libglib-2.0.so.0
#1  0x00007fc96fa311e5 in g_log_default_handler () from /nix/store/mxn46y68rsmx83qcraivfx2fmzx4aqc4-glib-2.74.1/lib/libglib-2.0.so.0
#2  0x00007fc96fa3143d in g_logv () from /nix/store/mxn46y68rsmx83qcraivfx2fmzx4aqc4-glib-2.74.1/lib/libglib-2.0.so.0
#3  0x00007fc96fa3171f in g_log () from /nix/store/mxn46y68rsmx83qcraivfx2fmzx4aqc4-glib-2.74.1/lib/libglib-2.0.so.0
#4  0x00007fc96fc6ce6e in g_settings_set_property () from /nix/store/mxn46y68rsmx83qcraivfx2fmzx4aqc4-glib-2.74.1/lib/libgio-2.0.so.0
#5  0x00007fc96fb2aa37 in object_set_property () from /nix/store/mxn46y68rsmx83qcraivfx2fmzx4aqc4-glib-2.74.1/lib/libgobject-2.0.so.0
#6  0x00007fc96fb2b328 in g_object_new_internal () from /nix/store/mxn46y68rsmx83qcraivfx2fmzx4aqc4-glib-2.74.1/lib/libgobject-2.0.so.0
#7  0x00007fc96fb2cec1 in g_object_new_valist () from /nix/store/mxn46y68rsmx83qcraivfx2fmzx4aqc4-glib-2.74.1/lib/libgobject-2.0.so.0
#8  0x00007fc96fb2d4e9 in g_object_new () from /nix/store/mxn46y68rsmx83qcraivfx2fmzx4aqc4-glib-2.74.1/lib/libgobject-2.0.so.0
#9  0x00007fc957740a98 in e_util_ref_settings () from /nix/store/4h373hv5scj8477jr8q8x1h3f1gfvlcv-evolution-3.46.1/lib/evolution/libevolution-util.so
#10 0x00007fc95795a928 in calendar_config_get_icaltimezone () from /nix/store/4h373hv5scj8477jr8q8x1h3f1gfvlcv-evolution-3.46.1/lib/evolution/libevolution-calendar.so
#11 0x00007fc9547d6ef5 in ecb_ews_get_items_sync () from /nix/store/wrsx33c06wfip49hph5d21vx1ijkp53x-evolution-ews-3.46.1/lib/evolution-data-server/calendar-backends/libecalbackendews.so
#12 0x00007fc9547d780e in ecb_ews_fetch_items_sync () from /nix/store/wrsx33c06wfip49hph5d21vx1ijkp53x-evolution-ews-3.46.1/lib/evolution-data-server/calendar-backends/libecalbackendews.so
#13 0x00007fc9547d8498 in ecb_ews_get_changes_sync () from /nix/store/wrsx33c06wfip49hph5d21vx1ijkp53x-evolution-ews-3.46.1/lib/evolution-data-server/calendar-backends/libecalbackendews.so
#14 0x00007fc96fe92a3a in e_cal_meta_backend_get_changes_sync () from /nix/store/6b9fl3is7817l38wm7faz7q9i8ylyg0k-evolution-data-server-3.46.1/lib/libedata-cal-2.0.so.2
#15 0x00007fc96fe97cb7 in ecmb_refresh_internal_sync () from /nix/store/6b9fl3is7817l38wm7faz7q9i8ylyg0k-evolution-data-server-3.46.1/lib/libedata-cal-2.0.so.2
#16 0x00007fc96fe7abd5 in cal_backend_dispatch_thread () from /nix/store/6b9fl3is7817l38wm7faz7q9i8ylyg0k-evolution-data-server-3.46.1/lib/libedata-cal-2.0.so.2
#17 0x00007fc96fa551b4 in g_thread_pool_thread_proxy () from /nix/store/mxn46y68rsmx83qcraivfx2fmzx4aqc4-glib-2.74.1/lib/libglib-2.0.so.0
#18 0x00007fc96fa548cd in g_thread_proxy () from /nix/store/mxn46y68rsmx83qcraivfx2fmzx4aqc4-glib-2.74.1/lib/libglib-2.0.so.0
#19 0x00007fc96b909e86 in start_thread () from /nix/store/hsk71z8admvgykn7vzjy11dfnar9f4r1-glibc-2.35-163/lib/libc.so.6
#20 0x00007fc96b990c60 in clone3 () from /nix/store/hsk71z8admvgykn7vzjy11dfnar9f4r1-glibc-2.35-163/lib/libc.so.6

The last mention of ews is in #9 with ecb_ews_get_items_sync which is defined in https://gitlab.gnome.org/GNOME/evolution-ews/-/blob/6d474c1d083afdd4d675bef50748f068b2d171d1/src/EWS/calendar/e-cal-backend-ews.c#L1272 .

The next step in the back trace is calendar_config_get_icaltimezone which seems to come from ecb_ews_item_to_component_sync (https://gitlab.gnome.org/GNOME/evolution-ews/-/blob/6d474c1d083afdd4d675bef50748f068b2d171d1/src/EWS/calendar/e-cal-backend-ews.c#L555) which in turn is called in ecb_ews_get_items_sync (https://gitlab.gnome.org/GNOME/evolution-ews/-/blob/6d474c1d083afdd4d675bef50748f068b2d171d1/src/EWS/calendar/e-cal-backend-ews.c#L1272).

The call to calendar_config_get_icaltimezone from libevolution-calendar.so might be an error in ews since there is a seemingly equivalent function ews_get_configured_icaltimezone (see https://gitlab.gnome.org/GNOME/evolution-ews/-/blob/6d474c1d083afdd4d675bef50748f068b2d171d1/src/EWS/common/e-ews-calendar-utils.c#L407) in ews which I would guess should be used there.

ews_get_configured_icaltimezone is patched with the auto generated patch. I'm not sure if calendar_config_get_icaltimezone from evolution is patched, but my guess would be that it isn't?

I hope that helps somehow and that I didn't go down a rabbit hole. :)

jtojnar commented 1 year ago

If evolution is used as a library (which appears to be the case from your exploration), it needs to be patched the same way as https://github.com/NixOS/nixpkgs/pull/190960.

symphorien commented 1 year ago

Unfortunately evolution has a function e_util_ref_settings that defeats the automatic patching to save memory: https://gitlab.gnome.org/GNOME/evolution/-/issues/1998#note_1602389 https://gitlab.gnome.org/GNOME/evolution/-/blob/master/src/e-util/e-misc-utils.c#L3359

flintflump commented 1 year ago

I parallelly raised an issue in evolution-ews if the crashing function could be replaced by the one in evolution-ews, but it doesn't seem that this will solve the problem in the long term (or at all).

Would the proposed solution of using the GSETTINGS_SCHEMA_DIR variable be viable here?

symphorien commented 1 year ago

this is clearly a nixos-specific issue, so please don't file bugs upstream...

flintflump commented 1 year ago

I hope I made that clear upstream. I raised a bug because the included comment suggests that the function should not be in use at all.

pschyska commented 1 year ago

I was able to add an ews account successfully, but I'm hitting the same crash as soon as I add a Task. (The account didn't have any tasks before, so maybe that's the condition) After:

{
  systemd.user.services.evolution-calendar-factory.environment.XDG_DATA_DIRS =
    pkgs.glib.makeSchemaDataDirPath pkgs.evolution pkgs.evolution.name;
}

… the crash doesn't happen anymore. I can add, delete and sync server additions/deletions without issues so far. I'm failing to understand the patching business in https://github.com/NixOS/nixpkgs/pull/190960, so I'm not sure if that work around is wise. @symphorien ?

symphorien commented 1 year ago

I tried to implement your idea differently https://github.com/NixOS/nixpkgs/pull/214413 can you try it ?

blitz commented 1 year ago

This issue is fixed for me since #214413 got backported to 22.11. :rocket: Thank you @symphorien! This is very much appreciated.