Methyl diazoacetate regioselectively adds to N-substituted imides of itaconic acid to afford 2-pyrazolines, methyl 7-aryl-6,8-dioxo-1,2,7-triazaspiro[4.4]non-2-ene-3-carboxylates that in reaction with halogens (Cl
2, Br
2) yield methyl 5-aryl-1-halo-4,6-dioxo-5-azaspiro[2.4]heptane-1-carboxylates as a mixture of
syn- and anti-isomers.