File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
backend/infrahub/proposed_change Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change 88from typing import TYPE_CHECKING
99
1010import pytest
11- from infrahub_sdk .exceptions import ModuleImportError
11+ from infrahub_sdk .exceptions import ModuleImportError , NodeNotFoundError
1212from infrahub_sdk .node import InfrahubNode
1313from infrahub_sdk .protocols import (
1414 CoreArtifactValidator ,
@@ -529,7 +529,11 @@ async def run_proposed_change_user_tests(model: RequestProposedChangeUserTests)
529529 log = get_run_logger ()
530530 client = get_client ()
531531
532- proposed_change = await client .get (kind = InfrahubKind .PROPOSEDCHANGE , id = model .proposed_change )
532+ try :
533+ proposed_change = await client .get (kind = CoreProposedChange , id = model .proposed_change )
534+ except NodeNotFoundError :
535+ log .warning (f"Proposed change ({ model .proposed_change } ) not found, skipping user tests execution" )
536+ return
533537
534538 def _execute (
535539 directory : Path , repository : ProposedChangeRepository , proposed_change : InfrahubNode
You can’t perform that action at this time.
0 commit comments