Skip to content
Snippets Groups Projects
Commit 098c38c9 authored by Mohammad Torkashvand's avatar Mohammad Torkashvand
Browse files

regnerated the PartnerTable migration again

parent bcea3135
No related branches found
No related tags found
No related merge requests found
Pipeline #85928 failed
......@@ -221,9 +221,7 @@ def import_partners(file_path: str = typer.Argument(..., help="Path to the CSV f
try:
for partner in partners:
if partner.get("created_at"):
partner["created_at"] = datetime.strptime(partner["created_at"], "%Y-%m-%d").replace(
tzinfo=UTC
)
partner["created_at"] = datetime.strptime(partner["created_at"], "%Y-%m-%d").replace(tzinfo=UTC)
new_partner = PartnerTable(**partner)
db.session.add(new_partner)
......
......@@ -49,8 +49,6 @@ def create_partner(
raise
finally:
db.session.close()
finally:
db.session.close()
def delete_partner_by_name(name: str) -> None:
......@@ -67,5 +65,3 @@ def delete_partner_by_name(name: str) -> None:
raise
finally:
db.session.close()
finally:
db.session.close()
......@@ -258,7 +258,8 @@ def iptrunk_subscription_factory(iptrunk_side_subscription_factory, faker, geant
iptrunk_sides = iptrunk_sides or [iptrunk_side_a, iptrunk_side_b]
iptrunk_subscription = IptrunkInactive.from_product_id(
product_id, customer_id=partner["partner_id"], insync=True)
product_id, customer_id=partner["partner_id"], insync=True
)
iptrunk_subscription.iptrunk.geant_s_sid = geant_s_sid
iptrunk_subscription.iptrunk.iptrunk_description = iptrunk_description
iptrunk_subscription.iptrunk.iptrunk_type = iptrunk_type
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment