delivered the opinion of the court:
The defendant, Edward J. Harris, appeals from an order of the circuit court of St. Clair County denying his pro se petition for relief *247from judgment pursuant to section 2 — 1401 of the Code of Civil Procedure (735 ILCS 5/2 — 1401 (West 2006)). The defendant contends that (1) the circuit court erred when it failed to recharacterize his pro se pleading as a postconviction petition pursuant to the Post-Conviction Hearing Act (725 ILCS 5/122 — 1 et seq. (West 2006)) and (2) his plea agreement was violated because he negotiated a six-year imprisonment term but was not admonished of the required period of mandatory supervised release to follow as required by People v. Whitfield, 217 Ill. 2d 177 (2005). For the following reasons, we affirm.
The defendant was charged with unlawful possession of a stolen vehicle, unlawful possession of a controlled substance, and unlawful possession with intent to deliver a controlled substance. On September 14, 2005, the defendant pled guilty to all three counts as a result of a plea agreement with the State. At the defendant’s plea hearing, the State explained the terms of the plea agreement, stating that there was a “joint recommendation” to the court that the defendant be sentenced to six years’ imprisonment, along with paying a $200 DNA analysis fee and submitting a DNA sample. The State’s recitation of the plea agreement did not mention mandatory supervised release. The circuit court admonished the defendant of the effects of his guilty plea and sentenced the defendant to six years’ imprisonment on each count, to be served concurrently, and with day-for-day credit. The sentencing order made no reference to the defendant’s two-year period of mandatory supervised release.
On January 24, 2007, the defendant sent a handwritten letter to the circuit court stating that he had not been properly advised that he would have to serve a period of mandatory supervised release. On March 5, 2007, the defendant filed a pro se petition for relief from judgment pursuant to section 2 — 1401 of the Code of Civil Procedure (735 ILCS 5/2 — 1401 (West 2006)). In his petition, the defendant asserted that he had not been properly advised of the required period of mandatory supervised release, therefore rendering his guilty plea unknowing.
On March 20, 2007, the court entered an order denying the defendant’s petition, stating:
“The court does not find that the defendant Harris has plead [sic] or otherwise shown any meritorious defense to the judgment. Harris has failed to plead or otherwise raise any issues that could not have been presented to the trial court. Further, the [p]etition fails to raise any disputed issues of material fact.”
On appeal, the defendant first argues that the circuit court erred when it failed to recharacterize his pro se petition for relief from judgment pursuant to section 2 — 1401 of the Code of Civil Procedure (735 *248ILCS 5/2 — 1401 (West 2006)) as a postconviction petition pursuant to the Post-Conviction Hearing Act (725 ILCS 5/122 — 1 et seq. (West 2006)). The defendant asserts that while the circuit court was not required to do so, the court had the authority to reclassify his pro se petition in “unusual and compelling circumstances” (People v. Purnell, 356 Ill. App. 3d 524, 529 (2005)). The defendant alleges that such compelling circumstances are present in his case in that there was a constitutional violation of record which will force him to serve a longer sentence than is permitted for his convicted offenses. More specifically, the defendant argues that the circuit court’s failure to comply with Supreme Court Rule 402 (177 Ill. 2d R. 402) and admonish him of the required period of mandatory supervised release resulted in the defendant not getting the benefit of his plea bargain, thereby violating due process.
While we agree that the circuit court had the authority to treat the defendant’s pleading as a petition under the Post-Conviction Hearing Act, we do not agree that the court erred in failing to do so. The Post-Conviction Hearing Act specifically provides that a circuit court is under no obligation to treat a postconviction pleading as one brought under that Act unless the pleading so specifies:
“A person seeking relief by filing a petition under this Section must specify in the petition or its heading that it is filed under this Section. A trial court that has received a petition complaining of a conviction or sentence that fails to specify in the petition or its heading that it is filed under this Section need not evaluate the petition to determine whether it could otherwise have stated some grounds for relief under this Article.” (Emphasis added.) 725 ILCS 5/122 — 1(d) (West 2006).
This statutory provision was added to the Post-Conviction Hearing Act by amendment in 1997 in order to undo the line of cases (see, e.g., People v. Sturgeon, 272 Ill. App. 3d 48 (1995)) holding that a trial court was required to recharacterize a defendant’s pleading as a post-conviction petition if that recharacterization could fairly be done based upon the contents of the pleading, even though the pleading made no reference to the Post-Conviction Hearing Act. See People v. Holliday, 369 Ill. App. 3d 678, 681 (2007). While the statutory provision does not prohibit a court from recharacterizing a petition, it removes any obligation on the part of the circuit court to even consider doing so.
In accordance with the statute, the Illinois Supreme Court has held that while a circuit court has the authority to recharacterize a petition for relief from judgment as a petition brought under the Post-Conviction Hearing Act, a circuit court is not required to even consider or evaluate the petition to determine whether it could have been *249brought under the Post-Conviction Hearing Act. People v. Shellstrom, 216 Ill. 2d 45, 53 n.l (2005). The supreme court was quite explicit about this in Shellstrom, when it stated, “[I]f a pro se pleading alleges constitutional deprivations that are cognizable under the [Post-Conviction Hearing] Act, *** a trial court is under no obligation to treat the pleading as a postconviction petition.” 216 Ill. 2d at 53 n.l.
We acknowledge that line of appellate court cases which holds that a circuit court’s decision whether to recharacterize a petition is reviewable under the abuse-of-discretion standard. See, e.g., People v. Smith, 386 Ill. App. 3d 473 (2008) (and cases cited therein). However, even if we review for an abuse of discretion, it is clear from the statutory language and the supreme court’s decision in Shellstrom that a circuit court’s failure to recharacterize a petition would not constitute an abuse of discretion. Circuit courts have unfettered discretion to decline to consider even whether a petition could qualify as one filed pursuant to the Post-Conviction Hearing Act and unfettered discretion to refuse to so recharacterize a petition. To hold otherwise would effectively require every circuit court to evaluate petitions to determine whether they should be recharacterized as having been brought under the Post-Conviction Hearing Act, in direct contravention of the plain language of section 122 — 1(d) of that Act (725 ILCS 5/122 — 1(d) (West 2006)). Accordingly, in the defendant’s case, we cannot conclude that the circuit court abused its discretion in failing to recharacterize the defendant’s section 2 — 1401 petition as one filed under the Post-Conviction Hearing Act.
The next issue raised by the defendant on appeal is that his guilty plea was entered into unknowingly in that he negotiated a six-year imprisonment term but was not properly admonished of the required period of mandatory supervised release to follow as required by People v. Whitfield, 217 Ill. 2d 177 (2005), thereby violating the terms of his plea agreement. The defendant argues that the circuit court failed to substantially comply with Supreme Court Rule 402, which resulted in a violation of his due process rights. As a result, the defendant claims that his prison sentence should be reduced to include the two-year mandatory-supervised-release term.
The purpose of a section 2 — 1401 petition for relief from judgment is to correct all errors of fact occurring in the prosecution of a cause, unknown to the petitioner or court at the time the judgment was entered, which, if known then, would have prevented the judgment’s rendition. People v. Haynes, 192 Ill. 2d 437, 461 (2000). Such a petition is not designed to provide a general review of all trial errors or to substitute for a direct appeal. Haynes, 192 Ill. 2d at 461. In the defendant’s case, by arguing that the circuit failed to properly admon*250ish him of the required period of mandatory supervised release, the defendant alleged a constitutional violation under People v. Whitfield, 217 Ill. 2d 177 (2005). The defendant did not allege any errors of fact in his petition for relief from judgment. The defendant’s Whitfield claim is not properly pursued in a petition for relief from judgment under section 2 — 1401. Thus, we do not need to address the merits of the defendant’s Whitfield claim, and we find that the circuit court properly denied the defendant’s petition.
For the foregoing reasons, the order of the circuit court of St. Clair County is hereby affirmed.
Affirmed.