Passage
Then I am not ashamed In my looking unto all Thy commands.
Then I am not ashamed In my looking unto all Thy commands.
Psalms 119:4 Thou hast commanded us Thy precepts to keep diligently,
Psalms 119:5 O that my ways were prepared to keep Thy statutes,
Psalms 119:6 Then I am not ashamed In my looking unto all Thy commands.
Psalms 119:7 I confess Thee with uprightness of heart, In my learning the judgments of Thy righteousness.
Psalms 119:8 Thy statutes I keep, leave me not utterly!
The verse centers on "ashamed", "looking", and "commands". It is saying that the verse draws attention to "ashamed" and "looking", so its meaning should be read from those terms before moving to application.
The nearby context moves from verse 5's "O that my ways were prepared to..." into verse 7's "I confess Thee with uprightness of heart...", so "ashamed" and "looking" belong inside that flow. In Psalms context, the local focus is worship, trust, the LORD's kingship, and covenant mercy.
A plain takeaway is to answer the verse's own emphasis on "ashamed" and "looking" with trust shaped by these words, not by a vague optimism outside the passage.