If you mean a petition in a summary proceeding, some errors may not be subject to amendment or correction, if the errors compromise the jurisdiction of the court to do anything with the case other than to dismiss for lack of jurisdiction or failure to state or make out a cause of action.
The answer provided to you is in the nature of general information. The general proposition being that you should try to avoid a bad outcome if you can.
As my colleagues indicated, it depends on the type of petition and the nature of the error. If you are pro se and facing dismissal of an otherwise valid claim, you should consider engaging an attorney to clean up the potentially fatal errors.
Disclaimer- The information you obtain at our web-site or through postings on such sites as this is not, nor is it intended to be, legal advice. You should consult an attorney for specific advice regarding your individual situation. Any response given here is not intended to create, nor does it create an ongoing duty to respond to questions. The response does not form an attorney-client relationship, nor is it intended to be relied upon as legal advice. The response given is based upon the limited facts provided by the person asking the question. To the extent additional or different facts exist, the response may change appropriately.