refactor(shipping-notice): 收紧通知单与导出上传事实边界
This commit is contained in:
1 parent
b5d894a923
commit
8ec028e6a3
12 files changed
+312
-318
No files matched your search
@@ -12,7 +12,17 @@ import pytest
|
||||
|
||||
from app import db
|
||||
from app.core.errors import ConflictError
|
||||
from app.models import ShippingBusinessSequence, ShippingCustomer, ShippingNotice, ShippingTaskEvent
|
||||
from app.models import (
|
||||
ShippingBusinessSequence,
|
||||
ShippingCustomer,
|
||||
ShippingNotice,
|
||||
ShippingTaskEvent,
|
||||
ShippingOrderTask,
|
||||
ShippingOrderExtraction,
|
||||
ShippingCustomerShadowResolution,
|
||||
ShippingOrderSchema,
|
||||
ShippingOrderSchemaVersion,
|
||||
)
|
||||
from app.services.shipping_notice.business_numbering_service import (
|
||||
assign_notice_business_number,
|
||||
format_business_no,
|
||||
@@ -22,23 +32,42 @@ from app.services.shipping_notice.customer_identity_gate import confirm_task_cus
|
||||
from app.services.shipping_notice.query_service import extract_task_no_from_text, get_task_by_ref
|
||||
|
||||
|
||||
def _seed_notice(*, short_code: str = "WYC", task_no: str = "SN-NUMBER-001"):
|
||||
"""创建待客户确认的 Notice 和启用客户。"""
|
||||
customer = ShippingCustomer(
|
||||
standard_name=f"编号测试客户 {short_code}",
|
||||
short_code=short_code,
|
||||
status="active",
|
||||
)
|
||||
db.session.add(customer)
|
||||
def _seed_notice(*, short_code: str = "WYC", task_no: str = "SN-NUMBER-001", customer: ShippingCustomer | None = None):
|
||||
"""创建带客户识别结果的待确认 Notice。"""
|
||||
if customer is None:
|
||||
customer = ShippingCustomer(
|
||||
standard_name=f"编号测试客户 {short_code}",
|
||||
short_code=short_code,
|
||||
status="active",
|
||||
)
|
||||
db.session.add(customer)
|
||||
db.session.flush()
|
||||
schema = ShippingOrderSchema(schema_code=f'SHIPPING_ORDER_{task_no}', display_name='Order')
|
||||
db.session.add(schema)
|
||||
db.session.flush()
|
||||
task = ShippingNotice(
|
||||
task_no=task_no,
|
||||
customer_resolution_status="pending",
|
||||
source_type="manual",
|
||||
version = ShippingOrderSchemaVersion(
|
||||
schema_id=schema.id, version=1, status='published', definition_json={'fields': []}, checksum='a' * 64,
|
||||
)
|
||||
db.session.add(task)
|
||||
db.session.add(version)
|
||||
db.session.flush()
|
||||
owner = ShippingOrderTask(task_no=f'OT-{task_no}', user_id=1, status='ready', current_step='customer_review')
|
||||
db.session.add(owner)
|
||||
db.session.flush()
|
||||
extraction = ShippingOrderExtraction(
|
||||
task_id=owner.id, schema_version_id=version.id, input_snapshot_hash='b' * 64, status='accepted',
|
||||
)
|
||||
db.session.add(extraction)
|
||||
db.session.flush()
|
||||
owner.current_order_extraction_id = extraction.id
|
||||
from tests.conftest import confirm_test_customer_resolution
|
||||
confirm_test_customer_resolution(owner, customer=customer, extraction=extraction)
|
||||
resolution = ShippingCustomerShadowResolution.query.filter_by(candidate_id=owner.candidate_id).one()
|
||||
resolution.status = 'unique_candidate'
|
||||
resolution.confirmed_customer_id = None
|
||||
notice = ShippingNotice(task_no=task_no, source_type='manual', order_task_id=owner.id)
|
||||
db.session.add(notice)
|
||||
db.session.commit()
|
||||
return task, customer
|
||||
return notice, customer
|
||||
|
||||
|
||||
def test_number_format_and_shanghai_date_boundary(app):
|
||||
@@ -54,31 +83,31 @@ def test_confirmation_assigns_idempotent_business_number(app):
|
||||
"""重复确认同一客户不得重复占用流水,正式编号保持不变。"""
|
||||
with app.app_context():
|
||||
task, customer = _seed_notice()
|
||||
first = confirm_task_customer(task, customer_id=customer.id, actor_id=None)
|
||||
first_no = first.business_no
|
||||
second = confirm_task_customer(first, customer_id=customer.id, actor_id=None)
|
||||
confirm_task_customer(task, customer_id=customer.id, actor_id=None)
|
||||
first_no = assign_notice_business_number(task)
|
||||
confirm_task_customer(task, customer_id=customer.id, actor_id=None)
|
||||
second = task
|
||||
|
||||
assert first_no
|
||||
assert second.business_no == first_no
|
||||
assert ShippingBusinessSequence.query.one().current_value == 1
|
||||
assert second.customer_short_code_snapshot == "WYC"
|
||||
assert ShippingTaskEvent.query.filter_by(event_type="business_number_assigned").count() == 1
|
||||
resolution = ShippingCustomerShadowResolution.query.one()
|
||||
assert resolution.confirmed_customer_id == customer.id
|
||||
|
||||
|
||||
def test_each_notice_gets_a_distinct_business_number_for_same_customer(app):
|
||||
"""同一客户 PO 的不同发货通知必须各自占用独立业务流水。"""
|
||||
with app.app_context():
|
||||
customer = ShippingCustomer(
|
||||
standard_name='通知单波次客户', short_code='WVC', status='active',
|
||||
)
|
||||
customer = ShippingCustomer(standard_name='通知单波次客户', short_code='WVC', status='active')
|
||||
db.session.add(customer)
|
||||
db.session.flush()
|
||||
first = ShippingNotice(task_no='SN-NOTICE-NO-1', customer_resolution_status='confirmed')
|
||||
second = ShippingNotice(task_no='SN-NOTICE-NO-2', customer_resolution_status='confirmed')
|
||||
db.session.add_all([first, second])
|
||||
db.session.flush()
|
||||
first.customer_id = customer.id
|
||||
second.customer_id = customer.id
|
||||
first, _ = _seed_notice(short_code='WVC', task_no='SN-NOTICE-NO-1', customer=customer)
|
||||
second, _ = _seed_notice(short_code='WVC', task_no='SN-NOTICE-NO-2', customer=customer)
|
||||
for notice in (first, second):
|
||||
owner = db.session.get(ShippingOrderTask, notice.order_task_id)
|
||||
resolution = ShippingCustomerShadowResolution.query.filter_by(candidate_id=owner.candidate_id).one()
|
||||
resolution.confirmed_customer_id = customer.id
|
||||
resolution.status = 'confirmed'
|
||||
db.session.flush()
|
||||
|
||||
first_no = assign_notice_business_number(first)
|
||||
@@ -95,21 +124,17 @@ def test_notice_confirms_customer_and_assigns_number_without_shipping_case(app):
|
||||
customer = ShippingCustomer(
|
||||
standard_name='Notice 自持客户', short_code='NHC', status='active',
|
||||
)
|
||||
task = ShippingNotice(
|
||||
task_no='SN-NOTICE-SELF-CUSTOMER',
|
||||
customer_resolution_status='pending',
|
||||
source_type='manual',
|
||||
)
|
||||
db.session.add_all([customer, task])
|
||||
db.session.commit()
|
||||
task, _ = _seed_notice(short_code='NHC', task_no='SN-NOTICE-SELF-CUSTOMER')
|
||||
customer = ShippingCustomer.query.filter_by(short_code='NHC').one()
|
||||
|
||||
confirmed = confirm_task_customer(task, customer_id=customer.id, actor_id=7)
|
||||
confirm_task_customer(task, customer_id=customer.id, actor_id=7)
|
||||
assign_notice_business_number(task)
|
||||
confirmed = task
|
||||
|
||||
assert confirmed.customer_id == customer.id
|
||||
assert confirmed.customer_name_snapshot == 'Notice 自持客户'
|
||||
assert confirmed.customer_short_code_snapshot == 'NHC'
|
||||
owner = db.session.get(ShippingOrderTask, confirmed.order_task_id)
|
||||
resolution = ShippingCustomerShadowResolution.query.filter_by(candidate_id=owner.candidate_id).one()
|
||||
assert resolution.confirmed_customer_id == customer.id
|
||||
assert confirmed.business_no
|
||||
assert confirmed.customer_resolution_status == 'confirmed'
|
||||
|
||||
|
||||
def test_replacement_notice_uses_next_sequence(app):
|
||||
@@ -117,16 +142,18 @@ def test_replacement_notice_uses_next_sequence(app):
|
||||
with app.app_context():
|
||||
task, customer = _seed_notice()
|
||||
confirm_task_customer(task, customer_id=customer.id, actor_id=None)
|
||||
assign_notice_business_number(task)
|
||||
revision = ShippingNotice(
|
||||
task_no="SN-NUMBER-REV",
|
||||
supersedes_task_id=task.id,
|
||||
customer_resolution_status="pending",
|
||||
order_task_id=task.order_task_id,
|
||||
source_type="manual",
|
||||
)
|
||||
db.session.add(revision)
|
||||
db.session.commit()
|
||||
|
||||
confirm_task_customer(revision, customer_id=customer.id, actor_id=None)
|
||||
assign_notice_business_number(revision)
|
||||
assert revision.business_no[:-2] == task.business_no[:-2]
|
||||
assert task.business_no.endswith("01")
|
||||
assert revision.business_no.endswith("02")
|
||||
@@ -144,8 +171,7 @@ def test_daily_sequence_blocks_one_hundredth_case(app):
|
||||
current_value=99,
|
||||
))
|
||||
db.session.commit()
|
||||
task.customer_id = customer.id
|
||||
|
||||
confirm_task_customer(task, customer_id=customer.id, actor_id=None)
|
||||
with pytest.raises(ConflictError) as exc_info:
|
||||
assign_notice_business_number(task)
|
||||
assert exc_info.value.code == "SHIPPING.BUSINESS_NUMBER_DAILY_LIMIT_REACHED"
|
||||
@@ -165,14 +191,17 @@ def test_numbering_failure_rolls_back_customer_confirmation(app):
|
||||
))
|
||||
db.session.commit()
|
||||
|
||||
confirm_task_customer(task, customer_id=customer.id, actor_id=None)
|
||||
with pytest.raises(ConflictError):
|
||||
confirm_task_customer(task, customer_id=customer.id, actor_id=None)
|
||||
assign_notice_business_number(task)
|
||||
db.session.rollback()
|
||||
db.session.expire_all()
|
||||
persisted_task = db.session.get(ShippingNotice, task.id)
|
||||
assert persisted_task.customer_id is None
|
||||
owner = db.session.get(ShippingOrderTask, persisted_task.order_task_id)
|
||||
resolution = ShippingCustomerShadowResolution.query.filter_by(candidate_id=owner.candidate_id).one()
|
||||
assert resolution.confirmed_customer_id == customer.id
|
||||
assert resolution.status == 'confirmed'
|
||||
assert persisted_task.business_no is None
|
||||
assert persisted_task.customer_resolution_status == "pending"
|
||||
|
||||
|
||||
def test_business_number_query_returns_exact_notice(app):
|
||||
@@ -180,11 +209,12 @@ def test_business_number_query_returns_exact_notice(app):
|
||||
with app.app_context():
|
||||
task, customer = _seed_notice()
|
||||
confirm_task_customer(task, customer_id=customer.id, actor_id=None)
|
||||
assign_notice_business_number(task)
|
||||
revision = ShippingNotice(
|
||||
task_no="SN-NUMBER-QUERY-REV",
|
||||
supersedes_task_id=task.id,
|
||||
document_version=2,
|
||||
customer_resolution_status="pending",
|
||||
order_task_id=task.order_task_id,
|
||||
source_type="manual",
|
||||
)
|
||||
db.session.add(revision)
|
||||
@@ -199,7 +229,7 @@ def test_numbering_rejects_invalid_short_code_even_if_data_bypasses_service(app)
|
||||
"""客户简码绕过管理服务写入异常值时,编号服务仍必须阻断。"""
|
||||
with app.app_context():
|
||||
task, customer = _seed_notice()
|
||||
task.customer_id = customer.id
|
||||
confirm_task_customer(task, customer_id=customer.id, actor_id=None)
|
||||
customer.short_code = "W1"
|
||||
# 数据库 CHECK 已阻断非法落库;no_autoflush 用于单独验证编号服务仍保留纵深校验。
|
||||
with db.session.no_autoflush, pytest.raises(ConflictError) as exc_info:
|
||||
|
||||
@@ -1,52 +1,42 @@
|
||||
"""
|
||||
用途:验证人工上传必须引用用户私有回执资产。
|
||||
依赖:上传 Attempt 服务、FileAsset 服务、滚动履约测试夹具。
|
||||
逻辑:无回执请求被拒;有已上传资产时创建 manual Attempt 并锁定预约单。
|
||||
用途:验证人工上传不再要求回执/截图证据,仅记录目标 Excel Artifact 与服务端操作人。
|
||||
依赖:上传 Attempt 服务、滚动履约测试夹具。
|
||||
逻辑:人工确认无需回执资产即成功创建 manual Attempt 并锁定预约单。
|
||||
"""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
from io import BytesIO
|
||||
|
||||
import pytest
|
||||
from werkzeug.datastructures import FileStorage
|
||||
|
||||
from app import db
|
||||
from app.core.errors import ValidationError
|
||||
from app.models import ShippingUploadAttempt, User
|
||||
from app.services.file_assets.service import upload_file_asset
|
||||
from app.services.shipping_notice.upload_attempt_service import record_manual_upload
|
||||
from tests.test_shipping_upload_attempt import _ready_artifact
|
||||
|
||||
|
||||
def test_manual_upload_requires_receipt_asset(app):
|
||||
"""人工确认不可仅凭文本或参考号,缺少回执文件必须返回专用业务错误。"""
|
||||
def test_manual_upload_requires_no_receipt_asset(app):
|
||||
"""人工确认不再采集回执/截图证据;仅凭操作者与目标 Excel 即可成功。"""
|
||||
with app.app_context():
|
||||
task, artifact, _reservation = _ready_artifact()
|
||||
user = User(username='manual-evidence', email='manual-evidence@example.test', password_hash='x')
|
||||
db.session.add(user); db.session.flush()
|
||||
with pytest.raises(ValidationError) as exc_info:
|
||||
record_manual_upload(task, artifact_id=artifact.id, evidence_asset_no='', operator_id=user.id)
|
||||
assert exc_info.value.code == 'SHIPPING.MANUAL_UPLOAD_EVIDENCE_REQUIRED'
|
||||
attempt = record_manual_upload(task, artifact_id=artifact.id, operator_id=user.id)
|
||||
assert attempt.mode == 'manual'
|
||||
assert attempt.evidence_asset_id is None
|
||||
assert attempt.freight_ref_no is None
|
||||
|
||||
|
||||
def test_manual_upload_records_receipt_asset(app):
|
||||
"""已上传的私有截图资产会成为 manual Attempt 的不可变证据。"""
|
||||
def test_manual_upload_records_operator_and_locks_reservation(app):
|
||||
"""人工确认记录操作者并完成上传事实;不产生任何截图/PDF 证据。"""
|
||||
with app.app_context():
|
||||
task, artifact, reservation = _ready_artifact()
|
||||
user = User(username='manual-evidence-ok', email='manual-evidence-ok@example.test', password_hash='x')
|
||||
db.session.add(user); db.session.commit()
|
||||
payload = upload_file_asset(
|
||||
user_id=user.id,
|
||||
upload=FileStorage(stream=BytesIO(b'receipt'), filename='receipt.png', content_type='image/png'),
|
||||
)
|
||||
attempt = record_manual_upload(
|
||||
task, artifact_id=artifact.id, evidence_asset_no=payload['asset_no'], operator_id=user.id,
|
||||
freight_ref_no='FREIGHT-RECEIPT-1',
|
||||
)
|
||||
attempt = record_manual_upload(task, artifact_id=artifact.id, operator_id=user.id)
|
||||
assert attempt.mode == 'manual'
|
||||
assert attempt.status == 'succeeded'
|
||||
assert attempt.evidence_asset_id is not None
|
||||
assert attempt.freight_ref_no == 'FREIGHT-RECEIPT-1'
|
||||
assert attempt.evidence_asset_id is None
|
||||
assert attempt.freight_ref_no is None
|
||||
assert attempt.operator_id == user.id
|
||||
assert db.session.get(type(reservation), reservation.id).status == 'uploaded'
|
||||
assert ShippingUploadAttempt.query.count() == 1
|
||||
@@ -53,9 +53,14 @@ def test_inventory_callback_id_is_checked_before_attempt_identity(app):
|
||||
task = ShippingNotice(task_no='SN-CB-ID-FIRST', source_type='manual')
|
||||
db.session.add(task)
|
||||
db.session.flush()
|
||||
# 冻结的逐源 Attempt 须携带完整 v2 身份(lease_token / candidate_set / execution / gate),
|
||||
# 否则回调会先在 _validate_callback_attempt_identity 被 identity_mismatch 拒绝,
|
||||
# 无法走到失败分支去写 callback_id。
|
||||
first = ShippingTaskInventoryRpaAttempt(
|
||||
task_no=task.task_no, source_code='SRC-A', attempt_no=1,
|
||||
source_run_no='PSR-FIRST', status='failed', callback_id=None,
|
||||
lease_token='lease-first',
|
||||
extra_json={'candidate_set_id': 1, 'execution_id': 1, 'gate_id': 1},
|
||||
)
|
||||
second = ShippingTaskInventoryRpaAttempt(
|
||||
task_no='SN-CB-ID-OTHER', source_code='SRC-B', attempt_no=1,
|
||||
@@ -64,23 +69,43 @@ def test_inventory_callback_id_is_checked_before_attempt_identity(app):
|
||||
db.session.add_all([first, second])
|
||||
db.session.flush()
|
||||
|
||||
def _payload(run_no: str, source_code: str, attempt_no: int) -> dict:
|
||||
"""构造完整 v2 身份围栏的回调 payload。
|
||||
|
||||
与 _validate_callback_attempt_identity 的 required 字段一一对应,
|
||||
使失败回调(error_code)能通过身份校验并回写 callback_id。
|
||||
"""
|
||||
return {
|
||||
'schema_version': 'shipping_inventory_rpa.v2',
|
||||
'callback_id': 'cb-unique',
|
||||
'task_no': task.task_no,
|
||||
'source_code': source_code,
|
||||
'source_run_no': run_no,
|
||||
'attempt_no': attempt_no,
|
||||
'lease_token': 'lease-first',
|
||||
'candidate_set_id': 1,
|
||||
'execution_id': 1,
|
||||
'gate_id': 1,
|
||||
'error_code': 'RPA_TIMEOUT',
|
||||
}
|
||||
|
||||
result, handled = per_source_callback_handler(
|
||||
task, source_code='SRC-A', run_no='PSR-FIRST',
|
||||
callback_payload={'callback_id': 'cb-unique', 'error_code': 'RPA_TIMEOUT'},
|
||||
callback_payload=_payload('PSR-FIRST', 'SRC-A', 1),
|
||||
)
|
||||
assert result == 'failed'
|
||||
assert handled.id == first.id
|
||||
|
||||
result, handled = per_source_callback_handler(
|
||||
task, source_code='SRC-A', run_no='PSR-FIRST',
|
||||
callback_payload={'callback_id': 'cb-unique', 'error_code': 'RPA_TIMEOUT'},
|
||||
callback_payload=_payload('PSR-FIRST', 'SRC-A', 1),
|
||||
)
|
||||
assert result == 'idempotent_ok'
|
||||
assert handled.id == first.id
|
||||
|
||||
result, handled = per_source_callback_handler(
|
||||
task, source_code='SRC-B', run_no='PSR-SECOND',
|
||||
callback_payload={'callback_id': 'cb-unique', 'error_code': 'RPA_TIMEOUT'},
|
||||
callback_payload=_payload('PSR-SECOND', 'SRC-B', 1),
|
||||
)
|
||||
assert result == 'callback_conflict'
|
||||
assert handled.id == first.id
|
||||
@@ -13,12 +13,12 @@ tests/test_shipping_uploaded_gate_closure.py
|
||||
from __future__ import annotations
|
||||
|
||||
from app import db
|
||||
from app.models import ShippingNotice, ShippingProcessExecution, ShippingProcessGate
|
||||
from app.models import ShippingNotice, ShippingOrderTask, ShippingProcessExecution, ShippingProcessGate, User
|
||||
from app.services.shipping_notice.process_gate_bridge import sync_fulfillment_gates_from_task
|
||||
from app.services.shipping_notice.process_gate_service import ensure_execution_for_workflow_version
|
||||
|
||||
|
||||
def _mk_execution(task: ShippingNotice) -> ShippingProcessExecution:
|
||||
def _mk_execution(task: ShippingOrderTask) -> ShippingProcessExecution:
|
||||
"""建正式 20-Gate Execution,并把 inventory_sufficiency 置为人工阻断,让任务停留在「通知准备」。"""
|
||||
execution = ensure_execution_for_workflow_version(task_id=int(task.id))
|
||||
task.active_process_execution_id = int(execution.id)
|
||||
@@ -33,12 +33,18 @@ def _mk_execution(task: ShippingNotice) -> ShippingProcessExecution:
|
||||
return execution
|
||||
|
||||
|
||||
def test_step1a_closes_all_gates_when_uploaded(app):
|
||||
def test_step1a_closes_all_gates_when_uploaded(app, monkeypatch):
|
||||
"""upload_status=uploaded → STEP 1A 收口全部前置 Gate,Execution 落到 completed。"""
|
||||
task = ShippingNotice(task_no='SN-UPLOADED-GATE', upload_status='uploaded', match_status='fulfillable')
|
||||
user = User(username='uploaded-gate-user', email='uploaded-gate@example.com', password_hash='x')
|
||||
db.session.add(user); db.session.flush()
|
||||
task = ShippingOrderTask(task_no='OT-UPLOADED-GATE', user_id=user.id)
|
||||
db.session.add(task)
|
||||
db.session.flush()
|
||||
execution = _mk_execution(task)
|
||||
monkeypatch.setattr(
|
||||
'app.services.shipping_notice.process_gate_bridge._derived_fulfillment_status',
|
||||
lambda _task: 'uploaded',
|
||||
)
|
||||
|
||||
sync_fulfillment_gates_from_task(execution=execution, actor_type='user', actor_id=1)
|
||||
db.session.commit()
|
||||
@@ -53,17 +59,18 @@ def test_step1a_closes_all_gates_when_uploaded(app):
|
||||
assert execution.status == 'completed'
|
||||
|
||||
|
||||
def test_uploaded_fact_closes_gates_despite_stale_upload_pending_reason(app):
|
||||
def test_uploaded_fact_closes_gates_despite_stale_upload_pending_reason(app, monkeypatch):
|
||||
"""上传已成功时,历史 upload_rpa_pending 不得将正式 Gate 重新投影为阻断。"""
|
||||
task = ShippingNotice(
|
||||
task_no='SN-UPLOADED-STALE-PENDING',
|
||||
upload_status='uploaded',
|
||||
pending_human_reason='upload_rpa_pending',
|
||||
match_status='fulfillable',
|
||||
)
|
||||
user = User(username='uploaded-stale-user', email='uploaded-stale@example.com', password_hash='x')
|
||||
db.session.add(user); db.session.flush()
|
||||
task = ShippingOrderTask(task_no='OT-UPLOADED-STALE-PENDING', user_id=user.id, pending_human_reason='upload_rpa_pending')
|
||||
db.session.add(task)
|
||||
db.session.flush()
|
||||
execution = _mk_execution(task)
|
||||
monkeypatch.setattr(
|
||||
'app.services.shipping_notice.process_gate_bridge._derived_fulfillment_status',
|
||||
lambda _task: 'uploaded',
|
||||
)
|
||||
|
||||
sync_fulfillment_gates_from_task(execution=execution, actor_type='user', actor_id=1)
|
||||
db.session.commit()
|
||||
@@ -75,7 +82,9 @@ def test_uploaded_fact_closes_gates_despite_stale_upload_pending_reason(app):
|
||||
|
||||
def test_missing_upload_status_keeps_gate_stuck(app):
|
||||
"""upload_status != uploaded → STEP 1A 不触发,前置 Gate 保留(阶段投影可被回退)。"""
|
||||
task = ShippingNotice(task_no='SN-UPLOAD-NOT-SET', upload_status='partial', match_status='fulfillable')
|
||||
user = User(username='upload-not-set-user', email='upload-not-set@example.com', password_hash='x')
|
||||
db.session.add(user); db.session.flush()
|
||||
task = ShippingOrderTask(task_no='OT-UPLOAD-NOT-SET', user_id=user.id)
|
||||
db.session.add(task)
|
||||
db.session.flush()
|
||||
execution = _mk_execution(task)
|
||||
|
||||
Reference in new issue
Block a user