When using a command like: '/fill ~10 ~10 ~10 ~-10 ~-10 ~-10 air 0 replace portal' it gives the output: 'The number you have entered (-4.00) is too small, it must be at least 0'
But when changing it to -5 it works.
Also when using it in the nether it works. This worked fine in 1.12*
You're too low – likely in a superflat world. The
~-10
is ending up below bedrock, which is negative and out of bounds.