The God of Israel only gave instructions to those with whom God made covenant. If you covenant with God, God has expectations of you and you have expectations of God. Like a marriage. [Leviticus 26]
If you are not in covenant with God, those instructions do not apply to you. To not live up to your covenant is sin.
So it’s only “sin” if “you are in. “*
If you are not in, you cannot “sin.”
Israel is in covenant with God. Its citizens are by birthright. God made provisions for those who sincerely sign onto that covenant, who are not natural citizens (gentiles), to join the covenant — to be bound by the covenant.
Because YHWH loves Jacob, And has fixed again on Israel, And given them rest on their own land, And immigrants who joined them, have been admitted to the house of Jacob. [Isaiah 14:1]
If you join then “you are in.”*
°