I'm not talking about Ruby, but I suspect that you have the wrong blending mode. On the command line, you can see the available blending modes with:
identify -list compose
Output
Atop Blend Blur Bumpmap ChangeMask Clear ColorBurn ColorDodge Colorize CopyBlack CopyBlue CopyCyan CopyGreen Copy CopyMagenta CopyOpacity CopyRed CopyYellow Darken DarkenIntensity DivideDst DivideSrc Dst Difference Displace Dissolve Distort DstAtop DstIn DstOut DstOver Exclusion HardLight HardMix Hue In Lighten LightenIntensity LinearBurn LinearDodge LinearLight Luminize Mathematics MinusDst MinusSrc Modulate ModulusAdd ModulusSubtract Multiply None Out Overlay Over PegtopLight PinLight Plus Replace Saturate Screen SoftLight Src SrcAtop SrcIn SrcOut SrcOver VividLight Xor
I expect you to see something like this if you look at the file where your Magick::CopyOpacityCompositeOp . So, if I take Mr Bean and a magenta rectangle of the same size:

I can run the command as follows:
convert MrBean.jpg overlay.png -compose blend -composite output.jpg
and I will get this:

Now this may or may not be what you want, so I can run all the available blending modes, for example:
for blend in $(identify -list compose|grep -v Blur ); do convert -label "$blend" MrBean2.jpg overlay.png -compose $blend -composite miff:- done | montage - -tile 5x result.png
which gives this, which shows various results:

source share