There is still the issue that Moses wanted God to be gracious to him by teaching him to obey the Torah that he and Israel might know Him. Likewise, in
Jeremiah 9:3 and
9:6, they did not know God and refused to know Him because in 9:13, they had forsaken the Torah, while in 9:24, those who know God know that He delights in practicing steadfast love, justice, and righteousness in all of the earth, so delighting in practicing those and other aspects of God's nature in obedience to the Torah is again the way to know Him, which is eternal life. In regard to
Jeremiah 31:33-34, in the Messianic era, know what will need to teach others how to know God because the Torah will be put in our minds and written on our hearts. Similarly, in Psalms 119, David wanted God to be gracious to Him by teaching him to obey the Torah, so obedience to it through faith in accordance with it being put in our minds and written on our hearts is how God reveals Himself to us. Righteousness is not a direct consequence of submitting ourselves to God, but rather it is submitting ourselves to God, believing in Him, hoping in Him, and loving Him.
I'd say that reconciliation with God, wrought by His Son, must come first. And that reconciliation is "appropriated" or takes place within us as we turn to Him in faith. That's our first right step, one that pleases Him immensely because it means union, agreement,
right stead with Him: that relationship is the essence or basis of man's justice. From there we're gifted with a new righteousness that comes from Him alone (which is why the law, by itself, does not justify). And we're obliged to walk in that justice or righteousness that the law makes us aware of but cannot accomplish.
"For what the law was powerless to do because it was weakened by the flesh, God did by sending his own Son in the likeness of sinful flesh to be a sin offering. And so he condemned sin in the flesh, in order that the righteous requirement of the law might be fully met in us, who do not live according to the flesh but according to the Spirit." Rom 8:3-4
But we may not even
want to know God and experience the reconciliation with Him that said knowledge results in, preferring
ourselves and our own way instead,
Nowhere does Romans 7 says that the purposes of the Torah is to demonstrate to us that we do fail at living up to it.
Sure it does.
"What shall we say, then? Is the law sinful? Certainly not! Nevertheless, I would not have known what sin was had it not been for the law."
"Did that which is good, then, become death to me? By no means! Nevertheless, in order that sin might be recognized as sin, it used what is good to bring about my death, so that through the commandment sin might become utterly sinful." Rom 7:7 &13
And this is why the law, while absolutely right and correct, has historically been understood in Christianity to serve as a
tutor, convicting us of sin while preparing us to realize that we need
more than mere exterior rules in order to be truly righteous; we need
change, interior change, new hearts. Man needs grace, man needs
God, IOW, for
everything, including success at authentic morality. The ten commandments, for example, are still held as obligatory, but fulfillable only by struggle and grace. God never commanded man to do anything that it would be impossible for man to do; He only knows that we cannot do it, we cannot be who we were created to be, when
apart from Him. Sin only exists within us and is acted out in this world because of man's spiritual separation from God.
Paul had been keeping the Torah, but without having a focus on knowing Christ, so he had been missing the whole goal of the Torah and counted it all as rubbish. Paul was in the same situation as those in
Romans 9:30-10:4, where he had failed to attain righteousness because he had misunderstood the goal of the Torah by pursuing it as through righteousness were the result of our works rather than pursuing it as through righteousness were by faith in Christ, for knowing Christ is the goal of the Torah for righteousness for everyone who has faith. Obeying the Torah while missing its goal leads to death just as assuredly as refusing to obey it.
I'm saying grace comes first. The Damascus road experience was a dramatic example of God turning a man around but we all must experience it in some manner. God appeals to us; He knocks on our door. He draws us to His righteousness by drawing us to Himself and, as we turn and follow, we grow in it, in the real thing, in
love to put it most precisely. As we come to appreciate love, because we love Him as He first loved us, and then begin to express and share that same love, it grows, and the law becomes fulfilled accordingly, the right way, God's way.
So it's not an either/or thing, but both/and, with our willingness, our cooperation in God's work with Him initiating and us following, striving to obey now with the help of His grace...or not.