Export to jpeg strips the EXIF tags

I am using the latest Windows 2.4.0 (on Windows 10).
When I export the images to JPEG, I don’t see any original EXIF tags. I am using exiftool.exe to check the tags.
Is the default behaviour to strip the EXIF tags on export? How to change that? Thanks

No, it ist not the default. There ist even no way to turn exporting of tags of. Personal tags are written to the xmp and EXIF inside the JPG, but not to the IPTC. So what Kinds of tags do you mean?

Maybe you can provide a sample JPG. Can be a very small crop of an image.

Here is an image.
FYI, I have used earlier versions of darktable (user builds) and they were okay.

Ok. Here is one more factor.
The issue is found in files exported from images shot with Pentax K1.
But not found in images shot with Pentax K5iis.

Can you please provide an example raw file?

I’m a Pentax user and do not have any problems with the K-3II on Debian, which is my primary plattform for raw development.

I have tested this with a fresh darktable install on Windows 10 with the Pentax K-1 DNG and PEF sample from https://raw.pixls.us/ and it works for me. Be sure to use the official version of darktable and that RAW files have not been touched by other software.

Could you please have a look in the log file? It might be that exiv2 doesn’t like your raw file for some reason.