gimp-2.10 and 2.99 fail exporting an xcf as png or jpg
Output exporting as png in gimp-2.99:
GIMP-Error: Calling error for procedure 'gimp-drawable-type':
Procedure 'gimp-drawable-type' has been called with an invalid ID for argument 'drawable'. Most likely a plug-in is trying to work on a layer that doesn't exist any longer.
GIMP-Error: Calling error for procedure 'gimp-drawable-has-alpha':
Procedure 'gimp-drawable-has-alpha' has been called with an invalid ID for argument 'drawable'. Most likely a plug-in is trying to work on a layer that doesn't exist any longer.
GIMP-Error: Calling error for procedure 'gimp-drawable-get-format':
Procedure 'gimp-drawable-get-format' has been called with an invalid ID for argument 'drawable'. Most likely a plug-in is trying to work on a layer that doesn't exist any longer.
(file-png:37573): GEGL-CRITICAL **: 18:20:42.771: gegl_buffer_get_extent: assertion 'GEGL_IS_BUFFER (buffer)' failed
/home/massimo/prefix/lib64/gimp/2.99/plug-ins/file-png/file-png: fatal error: Segmentation fault
/home/massimo/prefix/lib64/gimp/2.99/plug-ins/file-png/file-png (pid:37573): [E]xit, show [S]tack trace or [P]roceed: plug-in 'file-png' aborted before sending its procedure return values
GIMP-Error: Plug-in crashed: "file-png"
(/home/massimo/prefix/lib64/gimp/2.99/plug-ins/file-png/file-png)
The dying plug-in may have messed up GIMP's internal state. You may want to save your images and restart GIMP to be on the safe side.
GIMP-Error: Saving '/home/massimo/Documenti/Untitled.png' failed:
Procedure 'file-png-save' returned no return values