The proliferation of computation-intensive applications, such as autonomous driving, has urged mobile devices to alleviate their local computation pressure using external computing resources. As a promising solution, Multi-access Edge Computing tackles this problem by offloading computational tasks from mobile devices to edge servers. However, existing offloading schemes suffer from two fundamental limitations. First, they lack built-in measures to prevent deadline misses. For safety-critical applications, including autonomous driving, a deadline miss could result in catastrophic consequences. Second, existing schemes typically update offloading policies periodically. Namely, a policy based on the current system state is generated for a time window consisting of multiple time slots. Since system states could change from one time slot to the next one, the generated policy might not work well during the entire window. In this article, we propose a novel offloading scheme for safety-critical applications, Constrained Reinforcement Learning-based Offloading (CRLO). With CRLO, a safety layer is added to the learning-based policy generator, which effectively eliminates deadline misses. Furthermore, a long-sequence forecasting model, Informer, is utilized to predict temporally dependent system states, which helps to generate appropriate offloading policies. Our experimental results indicate that CRLO outperforms existing schemes in terms of deadline satisfaction and task completion time.