Yep.
That’s a violation I would say right away. If you declare independent do you get to vote in the primary if there is no independent candidate?