In what way does it not work?
If you’re getting blocked because Frozen Orb is on Cooldown then it’s working as expected. Castsequence doesn’t skip stuff when it’s on Cooldown or uncastable. Anything uncastable blocks the sequence. Also if your pet dies, freeze becomes uncastable.
Otherwise, the only two possible technical issues I can see are with Frozen orb and freeze. Both had some glitchiness with castsequence at one time but I’m pretty sure both issues were fixed long ago.
At one time, if you were carrying Frozen Orb the crafting reagent from wotlk, macros would glitch out and get confused (are you trying to cast the spell or use the item?). It’s easily solved by moving those items to your bank and /reload but I think changing the name from “Frozen Orb” to “Frozen Orb(Spell)” helped differentiate as well. It’s been a while since I dealt with that, so I’m not sure about the solution.
Freeze (and pet abilities in general) had an issue with castsequence at one time. It would cast everything up to and including freeze in the sequence but then it wouldn’t progress. If that was the issue, it would never cast Ice Nova and never reset to the beginning. If that’s still a bug the only way to fix it is remove Ice nova (it won’t help you anyways) and add a reset, like this
/castsequence [@cursor] reset=5 Frozen Orb, Comet Storm, Freeze
5 seconds after the last time you activate the macro, the sequence will reset back to the first spell. I’m intentionally leaving Ice nova out of the sequence
Personally I wouldn’t use that sequence, the frozen orb cd and inclusion of Frost Nova (it’s not giving you anything extra over freeze), make it glitchy and inefficient.
You could change it to this:
#showtooltip
/castsequence [@cursor,nomod] Frozen Orb; [@cursor] reset=5 comet storm, freeze
Hold down a modifier key (alt, shift or control - assuming they aren’t keybind to something else) and you get the comet storm and freeze sequence, otherwise it casts frozen orb.
The comet storm cooldown is longer than freeze’s cd so the sequence should always fully cycle but if it doesn’t, the reset is there.