File tree Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Original file line number Diff line number Diff line change 4
4
5
5
import datetime
6
6
import io
7
- from typing import List
7
+ from typing import List , Optional
8
8
from urllib .parse import urljoin
9
9
10
10
import requests
21
21
from vws .reports import QueryResult , TargetData
22
22
23
23
24
- def _cloud_reco_response_item_to_query_result ():
25
- pass
26
-
27
-
28
24
class CloudRecoService :
29
25
"""
30
26
An interface to the Vuforia Cloud Recognition Web APIs.
@@ -142,6 +138,7 @@ def query(
142
138
result = []
143
139
result_list = list (response .json ()['results' ])
144
140
for item in result_list :
141
+ target_data : Optional [TargetData ] = None
145
142
if 'target_data' in item :
146
143
target_data_dict = item ['target_data' ]
147
144
metadata = target_data_dict ['application_metadata' ]
@@ -154,8 +151,6 @@ def query(
154
151
application_metadata = metadata ,
155
152
target_timestamp = target_timestamp ,
156
153
)
157
- else :
158
- target_data = None
159
154
160
155
query_result = QueryResult (
161
156
target_id = item ['target_id' ],
You can’t perform that action at this time.
0 commit comments