| Server IP : 93.115.150.27 / Your IP : 216.73.216.221 Web Server : LiteSpeed System : Linux host2.azar.host 4.18.0-553.80.1.lve.el8.x86_64 #1 SMP Wed Oct 22 19:29:36 UTC 2025 x86_64 User : dorfakkh ( 1797) PHP Version : 8.1.34 Disable Function : show_source, system, passthru, exec, popen, proc_open, mail MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /opt/cloudlinux/venv/lib/python3.11/site-packages/alembic/script/__pycache__/ |
Upload File : |
�
�|oi�� � � � d dl mZ d dlmZ d dlZd dlZd dlZd dlZd dlZd dl m
Z
d dlmZ d dlm
Z
d dlmZ d dlmZ d d lmZ d d
lmZ d dlmZ d dlmZ d d
lmZ d dlmZ d dlmZ ddlmZ ddlmZ ddlmZ ddlmZ ddlmZ erddlmZ ddlm Z ddl!m"Z" ddl!m#Z# ddl$m%Z% d dl&m'Z' n
# e($ r dZ'Y nw xY wee)ee) f Z* ej+ d� � Z, ej+ d� � Z- ej+ d� � Z. ej+ d � � Z/ ej+ d!� � Z0d"Z1 ej+ d#� � Z2 ej+ d$� � Z3 G d%� d&� � Z4 G d'� d(ej% � � Z5dS ))� )�annotations)�contextmanagerN)�
ModuleType)�Any)�cast)�Iterator)�List)�Mapping)�Optional)�Sequence)�Set)�Tuple)�
TYPE_CHECKING)�Union� ��revision)�write_hooks� )�util)� migration)�not_none)�Config)�MessagingOptions)�RevisionStep)� StampStep)�Revision)�tzz (?!\.\#|__init__)(.*\.py)(c|o)?$z(?!\.\#|__init__)(.*\.py)$z([a-f0-9]+)\.py$z(upgrade|downgrade)_([a-z0-9]+)z\w+z%(rev)s_%(slug)sz
, *|(?: +)z
, *|(?: +)|\:c � � e Zd ZdZeddddddd edej � � f dad�Ze dbd�� � Z
ej d� � � Zdcd�Z
eddd �� � Ze dedfd'�� � Z dgdhd+�Zdid/�Zdjd2�Zdkd4�Zdld6�Zdmd<�Zdnd=�Zdod?�Zdnd@�ZdodA�ZdpdE�ZdqdF�ZdrdI�ZdsdJ�Ze dK� � � Z dtdN�Z!dudO�Z"dvdQ�Z#dwdS�Z$ dxdyd]�Z%dzd`�Z&dS ){�ScriptDirectoryaH Provides operations upon an Alembic script directory.
This object is useful to get information as to current revisions,
most notably being able to get at the "head" revision, for schemes
that want to test if the current revision in the database is the most
recent::
from alembic.script import ScriptDirectory
from alembic.config import Config
config = Config()
config.set_main_option("script_location", "myapp:migrations")
script = ScriptDirectory.from_config(config)
head_revision = script.get_current_head()
�( NF�utf-8r �dir�str�
file_template�truncate_slug_length�
Optional[int]�version_locations�Optional[List[str]]�
sourceless�bool�output_encoding�timezone�
Optional[str]�hook_config�Optional[Mapping[str, str]]�recursive_version_locations�messaging_opts�return�Nonec �x � || _ || _ || _ |pd| _ || _ || _ t
j | j � � | _ || _
|| _ | | _ |
| _
t j |t j � � s4t# j dt j � |� � z � � �d S )Nr! zVPath doesn't exist: %r. Please use the 'init' command to create a new scripts folder.)r# r% r( r&