(a) A final judgment entered under the provisions of this article by a statutory court may be appealed by the petitioner or the state to the circuit court of the county upon application for an appeal or writ of error in the manner and within the time provided in article four, chapter fifty-eight of this code, as amended. A final judgment entered under the provisions of this article by a circuit court or a final judgment entered by the circuit court after an appeal or writ of error was granted by such circuit court with respect to the judgment of a statutory court entered under the provisions of this article, as well as an order by a circuit court rejecting an appeal from or writ of error to the judgment of a statutory court entered under the provisions of this article, may be appealed by the petitioner or the state to the Supreme Court of Appeals upon application for an appeal or writ of error in the manner and within the time provided by law for civil appeals generally. When an application for an appeal or writ of error is rejected by the circuit court (and the order of rejection is not appealed to the Supreme Court of Appeals), or the Supreme Court of Appeals, as the case may be, or both, the order sought to be reviewed shall thereby become final to the same extent and with like effect as if said order had been affirmed on appeal.
(b) When the petitioner is remanded, execution of the judgment entered under the provisions of this article shall not be suspended by the granting of an appeal or writ of error, or suspended while the petitioner is applying for an appeal or writ of error. When the petitioner is ordered to be discharged, and execution of the judgment entered under the provisions of this article is ordered suspended to permit the state to apply for an appeal or writ of error, the court making such suspending order may, in its discretion, admit the petitioner to bail until expiration of the time allowed for making application for an appeal or writ of error, or, in case the appeal or writ of error is allowed, until the decision of the appellate court thereon is duly certified.