Short answer. Not to undo it. Article 1102 bars an heir who has sold the whole or a considerable part of the real property received from partition from suing to rescind it for lesion. You still have a right to be indemnified in cash for the shortfall, just not to unwind the partition itself.
What the law says
An heir who has alienated the whole or a considerable part of the real property adjudicated to him cannot maintain an action for rescission on the ground of lesion, but he shall have a right to be indemnified in cash.
Civil Code, Article 1102 — An Heir Who Has Sold Cannot Sue. Read the full provision →
Selling the property forecloses rescission
Article 1102 draws a line at the moment you sell what the partition gave you. It provides that an heir who has alienated the whole or a considerable part of the real property adjudicated to him cannot maintain an action for rescission on the ground of lesion, but he shall have a right to be indemnified in cash. Rescission on the ground of lesion is the remedy that would undo the partition because you received significantly less than your fair share. Once you have sold the property that came out of that partition, that particular remedy is no longer available to you.
You are not left without a remedy, though
The article does not leave a shortchanged heir with nothing just because they sold what they received. It preserves a separate right: to be indemnified in cash for the loss caused by the unfair partition. Instead of unwinding the division of the estate, which would be difficult or impossible once the property has passed to a buyer, the law lets you recover the value of what you were shorted, converting your grievance into a monetary claim rather than a claim to the property itself.
Why the law shifts the remedy after a sale
Rescission generally requires being able to return things to their original state, and once a considerable part of the inherited real property has been sold to someone else, undoing the partition would disturb a transaction with a third party who may have had nothing to do with the unfairness in the first place. Limiting you to cash indemnity after a sale protects buyers who relied on the partition being final, while still giving you a way to be made whole for the actual shortfall you suffered.
What this means if you already sold your share
If you received property in an estate partition that you believe was unfair, and you have since sold the whole or a considerable part of it, your path forward is generally a claim for cash indemnity rather than an attempt to reopen or rescind the partition itself. Whether the sale involved the whole of what you received or only a smaller portion can matter to how this plays out, since the article speaks of alienating the whole or a considerable part.