Functions execute commands out of order when containing /say
When running a function that contains /say commands, the order of execution is incorrect - specifically, commands involving /say
To reproduce:
Start a new world, with a datapack that contains this function:
say a tellraw @s "a" say b tellraw @s "b" say c tellraw @s "c"
Run this function, you will get these results:
a
b
c
Executed 6 command(s) from function 'foo:bar'
[Player] a
[Player] b
[Player] c
You would expect to get:
[Player] a
a
[Player] b
b
[Player] c
c
Executed 6 command(s) from function 'foo:bar'
Created Issue:
functions execute commands out of order when containing /say
When running a function that contains /say commands, the order of execution is incorrect - specifically, commands involving /say
To reproduce:
Start a new world, with a datapack that contains this function:
say a tellraw @s "a" say b tellraw @s "b" say c tellraw @s "c"
Run this function, you will get these results:
a b c Executed 6 command(s) from function 'foo:bar' [Player] a [Player] b [Player] c
You would expect to get:
[Player] a a [Player] b b [Player] c c Executed 6 command(s) from function 'foo:bar'
When running a function that contains /say commands, the order of execution is incorrect - specifically, commands involving /say
To reproduce:
Start a new world, with a datapack that contains this function:
say a tellraw @s "a" say b tellraw @s "b" say c tellraw @s "c"
Run this function, you will get these results:
a b c Executed 6 command(s) from function 'foo:bar' [Player] a [Player] b [Player] c
You would expect to get:
[Player] a a [Player] b b [Player] c c Executed 6 command(s) from function 'foo:bar'
functions execute commands out of order when containing /sayFunctions execute commands out of order when containing /say

Just for reference, an impractical workaround is to use /reload to block the server and force it to process the pending tasks.
When you run the following function:
You will likely get the following output:
[Player] a Executed 3 command(s) from function 'foo:bar' [Player] bSeems to still be a thing in 23w32a, despite being marked as fixed.
Also affects 23w32a