It's all out there if you care to search for it.
https://www.nhl.com/news/nhl-still-checking-hossa-pronger-other-contracts/c-536110
"Daly said at the time those contracts were registered an advisory letter was sent to the clubs notifying them that the League was going to investigate "the circumstances under which the contracts were negotiated to see if there is potential circumvention." There is no time limit to those investigations.
He added that deregistration is just one of several penalties that could be enacted, per Article 11 of the CBA. Other penalties, as outlined in Article 26 of the CBA, include fines against the club and/or the player, reducing the club's payroll for the following season, forfeiting draft picks, forfeiting games affected by the circumvention and suspensions of club officials, the player and his certified agent. "
I think you are still struggling with the concept of ratification in regards to a Collective Bargaining Agreement. They ratified them, or 'approved them', because they were legally bound to do so. Almost as soon as they were signed the league was very clear they would investigate these contracts and find a way to penalize them.
It isn't so much that the league retroactively punished these contracts, it's more that they were obligated to approve them but immediately sought ways to nullify the contracts or penalize the teams involved.
It was during these investigation periods that the league and NHLPA agreed on a process for them to be grandfathered in - I'm sure the NHL would've preferred to terminate these contracts but the NHLPA suggested the 'grandfathering' solution.
Also, remember that the league was investigating these, and warning teams, before the Luongo contract was signed:
"The NHL is looking to put a damper on these 10-plus-year contracts with throwaway years tacked on at the end," a league executive said last night. "They are building a strong case against Chicago to make an example of them. This issue won't just go away. Lots of other GMs are supporting the league here."
This quote is from July of 2009. I'm not sure exactly what you require in terms of warning, but it appears a very strong warning was given.
Thanks for doing my homework for me
There is a regular poster on this forum that called the punishment on these contracts way before it happened. I can't remember who it was, though.