
20 So.3d 24 (2009)
Otha HORTON, Appellant,
v.
Christopher EPPS, Margaret Bingham and Michelle Taylor, Appellees.
No. 2008-CP-00430-COA.
Court of Appeals of Mississippi.
April 21, 2009.
Rehearing Denied October 27, 2009.
*26 Otha Horton, pro se.
Office of the Attorney General by Jane L. Mapp, attorney for appellee.
EN BANC.
CARLTON, J., for the Court.
¶ 1. This matter is before this Court for a second time. The underlying issue in this case concerns whether Otha Horton is eligible for trusty status, which would allow him to earn a ten day reduction in his sentence of confinement for every thirty days he serves in trusty status. Previously, the Circuit Court of Rankin County found that Horton's pleading raised a matter of post-conviction relief and dismissed Horton's action for lack of "venue jurisdiction." This Court reversed and remanded, finding that Horton's claim did not attack his underlying conviction; rather, it challenged his inmate status. Horton v. Epps, 966 So.2d 839, 841(¶ 4) (Miss.Ct.App.2007). Therefore, the Court found that Horton's claim involved no claim for post-conviction relief, and venue was indeed proper in Rankin County, where Horton was incarcerated. Id. at (¶¶ 4-5). Upon remand, the circuit court again characterized this matter as post-conviction relief, and again dismissed the action, although the second dismissal was based upon findings that the claim was both without merit and untimely filed.
¶ 2. Horton appealed the second dismissal pro se, and the appeal was assigned to this Court. He raises six assignments of error, which are consolidated into four issues for a more concise discussion: (1) the circuit court erred in dismissing the claim pursuant to Mississippi Rule of Appellate Procedure 12(b)(6) for failure to state a claim upon which relief could be granted; (2) the circuit court erred in finding that the claim was frivolous and in ordering a forfeiture of earned time; (3) the circuit court erred in dismissing the claim for failure to file an appeal within thirty days of notice of the adverse administrative decision by the Mississippi Department of Corrections (MDOC); and (4) the circuit court erred in denying Horton's post-dismissal motions. We reverse and remand this case to the MDOC's Administrative Remedies Program for further proceedings as will be more fully discussed below.

FACTS
¶ 3. On May 8, 2006, Horton filed a petition concerning trusty status in the Circuit Court of Rankin County, Mississippi. He styled his petition as habeas corpus or/alternative motion to show cause. The basis of Horton's petition surrounded an amendment to Mississippi Code Annotated section 47-5-138.1 (Rev.2004), which became effective on April 28, 2004. The amendment specifically excluded certain offenders from being able to receive trusty earned time allowance. Id. One of the new exclusions applied to offenders convicted of selling a controlled substance. Id. Prior to the amendment, there was no such exclusion.
¶ 4. In his pleadings Horton confesses that he committed the crime of sale of cocaine on January 29, 2004. On September 14, 2005, Horton pleaded guilty before the Attala County Circuit Court. The dates are significant because Horton committed his crime before the amendment became effective, yet he pleaded guilty and was sentenced after the amendment took effect. Since Horton committed the crime prior to the amendment, he argues that it would constitute an ex post facto law if the amended law applied to him and that he should be eligible for trusty earned time.

DISCUSSION

I. Motion to Dismiss Horton's Petition for Habeas Corpus Or/ Alternative Motion to Show Cause
*27 ¶ 5. The circuit court granted the State's motion to dismiss. The appellate standard of review as to dismissals of actions on the pleadings is de novo. Thiroux v. Austin, 749 So.2d 1040, 1041(¶ 2) (Miss. 1999) (citing Young v. State, 731 So.2d 1120, 1122(¶ 6) (Miss.1999)). On appeal, the State asserts that Horton possessed no liberty or vested property interest in obtaining trusty status; therefore, he failed to state a claim upon which relief could be granted. The State further asserts that an ex post facto claim can exist in some instances where the inmate possesses no vested liberty or vested property interests. However, in this case, the State argues that Horton's expectation of obtaining trusty status at the time he committed his offense was, at best, speculative. The State argues that since Horton's expectation of obtaining trusty status was at best speculative, the court properly dismissed Horton's claims.
¶ 6. Mississippi is prohibited by both the federal constitution as well as our state constitution from enacting laws that retroactively increase the punishment for criminal offenses. Article I, Section 9, Clause 3 of the United States Constitution stating: "No Bill of Attainder or ex post facto Law shall be passed." Article I, Section 10, Clause 1 of the United States Constitution prohibits a state from passing ex post facto laws, stating: "No State shall ... pass any... ex post facto law...." The State of Mississippi adopted this prohibition in its Constitution in Article 3, Section 16, stating: "Ex post facto laws ... shall not be passed."
¶ 7. The MDOC argues in its brief that Horton was never placed in trusty status. Inmates rendered ineligible for trusty status by the amendment, but who the MDOC already placed in trusty status, were not removed from such status. Rather, the change in the law only applied to incoming inmates and those inmates already in custody but who had not achieved trusty status. The United States Supreme Court has considered the necessity of a liberty or property interest in stating an ex post facto claim. The Supreme Court stated:
[T]he focus of the ex post facto inquiry is not on whether a legislative change produces some ambiguous sort of "disadvantage,"... but on whether any such change alters the definition of criminal conduct or increases the penalty by which a crime is punishable.
California v. Morales, 514 U.S. 499, 506 n. 3, 115 S.Ct. 1597, 131 L.Ed.2d 588 (1995) (internal citations omitted). While the Morales Court found no ex post facto violation in Morales, the Court clearly explained that the existence of a liberty interest is not a bright dividing line in whether a legislative change constitutes an ex post facto violation. Id. at 509, 115 S.Ct. 1597.
¶ 8. The Supreme Court revisited its Morales holding in Garner v. Jones, 529 U.S. 244, 248, 120 S.Ct. 1362, 146 L.Ed.2d 236 (2000). The Supreme Court elaborated on the test set forth in Morales, stating as follows:
The standard announced in Morales requires a more rigorous analysis of the level of risk created by the change in law. When the rule does not by its own terms show a significant risk, the respondent must demonstrate, by evidence drawn from the rule's practical implementation by the agency charged with exercising discretion, that its retroactive application will result in a longer period of incarceration than under the earlier rule.... In the case before us, [the] respondent must show that as applied to his own sentence the law created a significant risk of increasing his punishment. This remains the issue in the *28 case, though the general operation of the Georgia parole system may produce relevant evidence and inform further analysis on the point.
Id. at 255, 120 S.Ct. 1362 (internal citations omitted).
¶ 9. The Mississippi Supreme Court has found an ex post facto deprivation despite the lack of a vested liberty or property interest. Puckett v. Abels, 684 So.2d 671 (Miss.1996). In Puckett, the Mississippi Supreme Court addressed whether Mississippi Code Annotated section 47-5-138 (Supp.1995) constituted an ex post facto violation. Id. at 672. The statute required that an inmate serve eighty-five percent of his or her sentence before being eligible for parole and applied to prisoners convicted before, but sentenced after, the new law's effective date. Id. Under the old law, prisoners were eligible for parole after serving twenty-five percent of their sentence, or they could obtain early release by way of the earned-time provisions by serving fifty percent of their sentence. Id. The supreme court in Puckett reasoned that:
In Morales, the Court stated: "The ex post facto standard we apply today is constant: it looks to whether a given legislative change has the prohibited effect of altering the definition of crimes or increasing punishments."....
. . . .
Under Morales, "what legislative adjustments `will be held to be of sufficient moment to transgress the constitutional prohibition' must be a matter of `degree.'" The Morales decision means that when an amendment does not retrospectively "change the sentencing range" applicable to an offense, but does make a procedural or other change, that may indirectly affect the length of time that a prisoner may serve, no violation of the Ex [P]ost [F]acto Clause has occurred because of the possibility of such an indirect effect is "speculative and conjectural." In other words the new law must have a direct effect on the sentence length.
Id. at 676 (internal citations omitted). Applying the Morales test, the court found that the law constituted an improper ex post facto law. Id. at 678. The court reasoned that unlike in Morales, the Mississippi law (1) affected a large class of prisoners, (2) completely eliminated the possibility of parole for the prisoners rather than just affecting the timing of suitability hearings, and (3) applied "automatically across the board" with no "case specific inquiry or hearing conducted." Id. at 677. Unfortunately, in the case at bar, the record contains no factual findings or evidence indicating whether the MDOC granted trusty status automatically with no case-specific inquiry prior to the amendment.
¶ 10. In analyzing whether the application of section 47-5-138.1 to Horton constitutes an ex post facto violation, we must begin with the test set forth by the Supreme Court in Morales and later clarified in Garner. In order to show an ex post facto violation, Horton must demonstrate that the application of section 47-5-138.1 creates "a sufficient risk of increasing the measure of punishment attached to the covered crimes." Garner, 529 U.S. at 250, 120 S.Ct. 1362. As the Supreme Court stated in Garner, "[w]hen the rule does not by its own terms show a significant risk, the respondent must demonstrate, by evidence drawn from the rule's practical implementation ... that its retroactive application will result in a longer period of incarceration than under the earlier rule." Id. at 255, 120 S.Ct. 1362. Utilizing this test, we find that the trial court erred in summarily dismissing Horton's motion. However, the record before *29 us lacks sufficient factual findings to determine whether the application of section 47-5-138.1 to Horton constitutes an ex post facto violation. Accordingly, we find that a determination of this issue requires an evidentiary hearing to decide factual aspects of this issue.
¶ 11. As discussed above, the pertinent question in this case is whether the application of section 47-5-138.1 creates "a sufficient risk of increasing the measure of punishment attached to the covered crimes." Garner, 529 U.S. at 250, 120 S.Ct. 1362. At the time the new law took effect, Horton had not been placed in trusty status so as to make him eligible for trusty-earned time. In order to demonstrate an ex post facto violation with regard to the new law, the record must demonstrate that there was a significant likelihood or probability that Horton would have been placed in trusty status and would have received a ten-day reduction for every thirty days served of his sentence. This showing would demonstrate that the new law created a "significant risk of prolonging [Horton's] incarceration." See id. at 251, 120 S.Ct. 1362.
¶ 12. Evidentiary information relevant to the resolution of Horton's claim would include the following: (1) how the trusty program works; (2) what are the requirements for obtaining trusty status; (3) how many prisoners have trusty status, and how many prisoners are similarly situated to Horton who, but for the legislative change, would have trusty status; (4) prior to the statute's amendment, was trusty status granted automatically to those similarly situated to Horton without a case-specific inquiry or hearing, or what factors contributed to the decision; and (5) when in trusty status, what are the requirements for trusty-earned time. Without a record setting forth such evidentiary information, this Court lacks the factual findings to determine whether Horton has been subjected to an improper ex post facto law.
¶ 13. As the Supreme Court found in Garner, the internal policies and actual practices of an agency charged with administering a statute "provide important instruction as to how [the agency] interprets its enabling statute and regulations," and "[i]t is often the case that an agency's policies and practices will indicate the manner in which it is exercising its discretion." Garner, 529 U.S. at 256, 120 S.Ct. 1362. The MDOC itself must be the source of the information as to how the MDOC interpreted the applicable statutes and regulations prior to the statute's amendment. Therefore, factual findings must be garnered to determine whether the MDOC's denial of Horton's request for trusty status based upon the amended statute violates the prohibition on ex-post facto punishment. We reverse the judgment and remand this matter to the circuit court to remand to the MDOC for proceedings consistent with this opinion. In order to determine whether Horton states a valid ex post facto claim, the MDOC will have to provide information sufficient to provide a reviewing court with factual findings supported by a record addressing at least the five questions stated above. See URCCC 5.02 ("it is the duty of the lower court ... to make and preserve a record of the proceedings sufficient for the [appellate] court to review").

II. and III. Timely Appeal and Dismissal of Post-Dismissal Motions
¶ 14. These two issues ultimately turn on the same facts and are, therefore, discussed together. Horton contends that the circuit court erred in dismissing his action for failure to file his notice of appeal in the circuit court within thirty days of receipt of notice of the MDOC's adverse administrative decision. Mississippi Code Annotated section 47-5-807 (Rev.2004) requires *30 that any action seeking judicial review of an adverse administrative decision from the MDOC's administrative review program must be brought within thirty days that an inmate was notified of a final administrative decision. MDOC raised the issue of untimely appeal as an affirmative defense in its response and motion to dismiss Horton's complaint. Horton filed a response to the MDOC's responsive pleading, and he argued that he timely filed his notice of appeal as he failed to receive notice of the adverse decision until April 7, 2006. Horton's response stated that he attached a copy of the notice as "Exhibit A," but the record does not show that this exhibit is attached to that pleading. However, Horton filed a post-dismissal motion to alter or amend judgment. He attached as "Exhibit A" to this post-dismissal motion a copy of an Administrative Remedies Program form reflecting a denial of administrative remedies. This document shows that Horton was not notified of the adverse decision until April 7, 2006. Thus, Horton's notice of appeal was timely filed.
¶ 15. In its brief before this Court, the MDOC states:
The lower court's findings in its January 18, 2008 Order of Dismissal were entirely reasonable based on the record before the court at that time. The issue of whether on not Horton timely sought judicial review was raised as far back as May 31, 2006 in the Defendant's Response and Motion to Dismiss, yet it appears that Horton never included a copy of the receipt for the Third Step Response to his grievance with any of his pleadings filed with the court until after the trial court's January 18, 2008 Order of Dismissal was entered. All the evidence before the court indicated that Horton did not seek judicial review within the 30[-]day time period required by law.
The MDOC raised the issue of an untimely appeal as an affirmative defense. The party raising an affirmative defense bears the burden of proving such defense. Hinton v. McKee, 329 So.2d 519, 520-21 (Miss. 1976). Moreover, prior to the order of dismissal, the MDOC had notice from Horton's response to its motion for dismissal that Horton contested the MDOC's assertion that he had not timely filed his notice of appeal. The MDOC is the custodian of records concerning its administrative remedies program. If the MDOC wished to assert this affirmative defense, then the MDOC bore the burden to show that the filing was untimely. Similarly, the MDOC has not made a motion to this Court for leave to supplement the record to reflect any evidence to show that Horton filed an untimely appeal. Consequently, both the circuit court and this Court are presented with an incomplete record. The appellate standard of review as to dismissal of actions on the pleadings is de novo. Thiroux, 749 So.2d at 1041(¶ 2). Applying this standard of review to this case, we have no choice but to reverse the circuit court's finding that this action is time-barred for failure to timely file a notice of appeal.
¶ 16. Additionally, when a dismissal is granted pursuant to Mississippi Rule of Civil Procedure 12(b)(6), a plaintiff "shall" be granted leave to amend his complaint under Mississippi Rule of Civil Procedure 15(a). Poindexter v. S. United Fire Ins. Co., 838 So.2d 964, 969(¶ 24) (Miss.2003). The circuit court judge was of the opinion that Horton's claim was meritless, as well as time-barred, so obviously a motion to amend was futile. However, as discussed in the first assignment of error, we find the conclusion that no claim can be stated under the facts present was precipitous and possibly made in error. Moreover, following a Mississippi Rule of Civil Procedure *31 12(b)(6) dismissal, a party has a right to amend a complaint even where a trial court may find the claim futile. Id. at 970-71 (¶¶ 28-29). Therefore, we find that the circuit court judge abused his discretion in denying leave to amend the pleading to set forth that the notice of appeal was timely filed.

IV. Forfeiture of Earned Time
¶ 17. Horton asserts the circuit court erred in finding his action was frivolous in ordering the MDOC to deduct earned time. This argument misstates the issue. Mississippi Code Annotated section 47-5-138(3)(a) (Supp.2008) requires that earned time be forfeited when a final order is entered stating that a prisoner's complaint failed to state a claim upon which relief could be granted. Because we reverse and remand this case, there should be no forfeiture of earned time. However, Horton should be apprised that should his arguments ultimately be dismissed for a failure to state a claim upon which relief can be granted, forfeiture of earned time is mandatory, and not a matter of judicial discretion.
¶ 18. THE JUDGMENT OF THE RANKIN COUNTY CIRCUIT COURT IS REVERSED AND REMANDED FOR FURTHER PROCEEDINGS CONSISTENT WITH THIS OPINION. ALL COSTS OF THIS APPEAL ARE ASSESSED TO THE APPELLEES.
KING, C.J., LEE AND MYERS, P.JJ., IRVING, GRIFFIS, BARNES, ISHEE, ROBERTS AND MAXWELL, JJ., CONCUR.
