]> git.ipfire.org Git - thirdparty/sqlalchemy/alembic.git/commitdiff
Used script to generate pyi-files.
authorTilman Krummeck <tilman.krummeck@tuev-sued.com>
Mon, 13 Sep 2021 09:23:03 +0000 (11:23 +0200)
committerTilman Krummeck <tilman.krummeck@tuev-sued.com>
Mon, 13 Sep 2021 09:23:03 +0000 (11:23 +0200)
alembic/op.pyi
alembic/operations/ops.py

index 01078daeaaf6b76ea8bd389358b7bf3c6de982b8..6bd17c751f55a96809b3bb3289a5dbdb1acc702e 100644 (file)
@@ -541,9 +541,9 @@ def create_foreign_key(
     off normally.   The :class:`~sqlalchemy.schema.AddConstraint`
     construct is ultimately used to generate the ALTER statement.
 
-    :param constraint_name: Name of the foreign key constraint.  The name is
-     necessary so that an ALTER statement can be emitted.  For setups that
-     use an automated naming scheme such as that described at
+    :param constraint_name: Name of the foreign key constraint.  The name
+     is necessary so that an ALTER statement can be emitted.  For setups
+     that use an automated naming scheme such as that described at
      :ref:`sqla:constraint_naming_conventions`,
      ``name`` here can be ``None``, as the event listener will
      apply the name to the constraint object when it is associated
@@ -643,9 +643,9 @@ def create_primary_key(
     off normally.   The :class:`~sqlalchemy.schema.AddConstraint`
     construct is ultimately used to generate the ALTER statement.
 
-    :param constraint_name: Name of the primary key constraint.  The name is
-     necessary so that an ALTER statement can be emitted.  For setups that
-     use an automated naming scheme such as that described at
+    :param constraint_name: Name of the primary key constraint.  The name
+     is necessary so that an ALTER statement can be emitted.  For setups
+     that use an automated naming scheme such as that described at
      :ref:`sqla:constraint_naming_conventions`
      ``name`` here can be ``None``, as the event listener will
      apply the name to the constraint object when it is associated
index c4712117ad423947f22088243acccf74e9020437..70d7a8eab707fc338dcc9c501790c9fb8dc58833 100644 (file)
@@ -588,7 +588,7 @@ class CreateForeignKeyOp(AddConstraintOp):
     def create_foreign_key(
         cls,
         operations: "Operations",
-        constraint_name: str,
+        constraint_name: Optional[str],
         source_table: str,
         referent_table: str,
         local_cols: List[str],