I wonder, was the spinach bitter before it started to make a flowering stem? No reason it should be before flowering, and I don’t see why your new sowing should make bitter leaves.
For cucumber I think you mean Burpless? (Burpee is an American seed company – confusing there are so many burps). Possibly you have another cucumber nearby and it is cross pollinating, could induce bitterness. My outdoor La Diva are sweet, but an indoor "lemon cucumber" with male flowers was bitter and made other nearby varieties bitter, so I pulled it out.