Okay, let me elaborate this a little bit further. The above code is just an example, which helps reproduce the effect.
In reality I add the image as a layer (not background-layer) to the MagickImageCollection with the following properties:
Defective means, that Photoshop wont even open the file. It says that it cannot read the layer data and asks if it should try and read the image as a whole, then resulting in another error stating, that this file is not compatible with this version of PS (which is CC2015 by the way). But when rotating such portrait images prior to saving (even with Magick.NET itself) this does not occur and the resulting psd file work like a charm.
In reality I add the image as a layer (not background-layer) to the MagickImageCollection with the following properties:
magickImage.Label = layerName;
magickImage.Format = MagickFormat.Psd;
magickImage.HasAlpha = true; // This leads to the image being threaded as a real layer (not background layer) in Photoshop.
magickImage.Compose = CompositeOperator.No; // This leads to the layer not being locked.
magickImage.CompressionMethod = CompressionMethod.RLE;
magickImage.Page = new MagickGeometry(x: 0, y: 0, width: magickImage.Width, height: magickImage.Height);
So I actually do force the use of an alpha channel, but it is not related to the error. I literally tried myriads of different combinations, like adding multiple layers (with or without including the merged layer at position zero (which, by the way, seems to be unnecessary when building an psd file with just one layer...)), changing their orientation back and forth, changing the sorting, the composition, the page-property and so on and so on. I have done this for the last two days to no avail. To reproduce the behaviour the code from the initial post suffices.Defective means, that Photoshop wont even open the file. It says that it cannot read the layer data and asks if it should try and read the image as a whole, then resulting in another error stating, that this file is not compatible with this version of PS (which is CC2015 by the way). But when rotating such portrait images prior to saving (even with Magick.NET itself) this does not occur and the resulting psd file work like a charm.