Deuteronomy 17:2

2 "If there is found among you, within any of your towns which the LORD your God gives you, a man or woman who does what is evil in the sight of the LORD your God, in transgressing his covenant,

Deuteronomy 17:2 Meaning and Commentary

Deuteronomy 17:2

If there be found among you, within any of thy gates which the
Lord thy God giveth thee
In any of their cities in the land of Canaan:

man or woman that hath wrought wickedness in the sight of the Lord thy
God:
as all that is wrought is in the sight of the omniscient God; here it means not any kind of wickedness, for there is none lives without committing sin of one sort or another, all which is known to God the searcher of hearts, but such wickedness as is after described:

in transgressing his covenant;
that is, his law, and particularly the first table of it, which respects divine worship, and which is in the nature of a marriage contract or covenant; which, as that is transgressed by adultery committed by either party, so the covenant between God and Israel was transgressed by idolatry, which is spiritual adultery, and going a whoring after other gods, as it follows:

Deuteronomy 17:2 In-Context

1 "You shall not sacrifice to the LORD your God an ox or a sheep in which is a blemish, any defect whatever; for that is an abomination to the LORD your God.
2 "If there is found among you, within any of your towns which the LORD your God gives you, a man or woman who does what is evil in the sight of the LORD your God, in transgressing his covenant,
3 and has gone and served other gods and worshiped them, or the sun or the moon or any of the host of heaven, which I have forbidden,
4 and it is told you and you hear of it; then you shall inquire diligently, and if it is true and certain that such an abominable thing has been done in Israel,
5 then you shall bring forth to your gates that man or woman who has done this evil thing, and you shall stone that man or woman to death with stones.
Revised Standard Version of the Bible, copyright 1952 [2nd edition, 1971] by the Division of Christian Education of the National Council of the Churches of Christ in the United States of America. Used by permission. All rights reserved.