And do not grieve the Holy Spirit of God, by whom you were sealed for the day of redemption.
While this verse likely connects with verse 30, it truly can connect with all of these already mentioned — our sin and our unrighteousness grieves the Holy Spirit. And with this we see that all those critics who say that the Holy Spirit is a force or simply a source of energy must deal with the fact that the Holy Spirit grieves and weeps thus demonstrating his personhood. When we see wicked behavior and sinfulness in others, it is difficult, but when we see our children engaged in this, it cuts right to our hearts.
If you look back at verse 27, you see the connection there as well. If you grieve the Holy Spirit of God, you give the devil a foothold. Yet, we are not to grieve but to gladden the Spirit of God — why? — because we “were sealed by Him for the day of redemption.” Ephes. 1:13-14 says, “In him you also, when you heard the word of truth, the gospel of your salvation, and believed in him, were sealed with the promised Holy Spirit,  who is the guarantee of our inheritance until we acquire possession of it, to the praise of his glory.” The seal is his personal mark of ownership — his seal of approval, if you will. John MacArthur notes:
How can we grieve the One who is our Helper, Comforter, Teacher, Advocate, Divine Resident of our hearts, and guarantor of our eternal redemption? How can we ungraciously grieve God’s infinitely gracious Holy Spirit? He has done so much for us that, out of gratitude, we ought not to grieve Him (Ephesians, 189).
Did you notice that every one of these issues deals with human relationships? And do you see how they can tear down unity and fellowship even among believers? Bitterness and anger are like piranhas in the Amazon that can debone a horse in thirty seconds — anger does the same thing.
St. Francis of Assisi penned a prayer that has brought comfort and motivation to millions throughout church history:
Lord, make me an instrument of your peace;
where there is hatred, let me sow love;
when there is injury, pardon;
where there is doubt, faith;
where there is despair, hope;
where there is darkness, light;
and where there is sadness, joy.
Grant that I may not so much seek
to be consoled as to console;
to be understood, as to understand,
to be loved as to love;
for it is in giving that we receive,
it is in pardoning that we are pardoned,
and it is in dying [to ourselves] that we are born to eternal life.