File tree Expand file tree Collapse file tree 1 file changed +12
-20
lines changed Expand file tree Collapse file tree 1 file changed +12
-20
lines changed Original file line number Diff line number Diff line change @@ -171,29 +171,21 @@ def job_failed_name(request):
171171
172172@pytest .fixture (scope = "session" , autouse = True )
173173def completed_quantum_job (job_completed_name ):
174- job_arn = (
175- [
176- job ["jobArn" ]
177- for job in boto3 .client ("braket" ).search_jobs (filters = [])["jobs" ]
178- if job ["jobName" ] == job_completed_name
179- ][0 ]
180- if os .getenv ("JOBS_STARTED" )
181- else None
182- )
174+ job_arn = [
175+ job ["jobArn" ]
176+ for job in boto3 .client ("braket" ).search_jobs (filters = [])["jobs" ]
177+ if job ["jobName" ] == job_completed_name
178+ ][0 ]
183179
184- return AwsQuantumJob (arn = job_arn ) if os . getenv ( "JOBS_STARTED" ) else None
180+ return AwsQuantumJob (arn = job_arn )
185181
186182
187183@pytest .fixture (scope = "session" , autouse = True )
188184def failed_quantum_job (job_failed_name ):
189- job_arn = (
190- [
191- job ["jobArn" ]
192- for job in boto3 .client ("braket" ).search_jobs (filters = [])["jobs" ]
193- if job ["jobName" ] == job_failed_name
194- ][0 ]
195- if os .getenv ("JOBS_STARTED" )
196- else None
197- )
185+ job_arn = [
186+ job ["jobArn" ]
187+ for job in boto3 .client ("braket" ).search_jobs (filters = [])["jobs" ]
188+ if job ["jobName" ] == job_failed_name
189+ ][0 ]
198190
199- return AwsQuantumJob (arn = job_arn ) if os . getenv ( "JOBS_STARTED" ) else None
191+ return AwsQuantumJob (arn = job_arn )
You can’t perform that action at this time.
0 commit comments