20
20
21
21
22
22
class MockTopic (Topic ):
23
- """A mock topic that registers in a global messages dictionary rather than Google Pub/Sub."""
23
+ """A mock topic that registers in a global topics dictionary rather than Google Pub/Sub."""
24
24
25
25
def create (self , allow_existing = False ):
26
- """Register the topic in the global messages dictionary.
26
+ """Register the topic in the global topics dictionary.
27
27
28
28
:param bool allow_existing: if True, don't raise an error if the topic already exists
29
29
:raise google.api_core.exceptions.AlreadyExists: if the topic already exists
@@ -38,7 +38,7 @@ def create(self, allow_existing=False):
38
38
self ._created = True
39
39
40
40
def delete (self ):
41
- """Delete the topic from the global messages dictionary.
41
+ """Delete the topic from the global topics dictionary.
42
42
43
43
:return None:
44
44
"""
@@ -48,7 +48,7 @@ def delete(self):
48
48
pass
49
49
50
50
def exists (self , timeout = 10 ):
51
- """Check if the topic exists in the global messages dictionary.
51
+ """Check if the topic exists in the global topics dictionary.
52
52
53
53
:param float timeout:
54
54
:return bool:
@@ -326,6 +326,7 @@ def ask(
326
326
allow_local_files = False ,
327
327
save_diagnostics = "SAVE_DIAGNOSTICS_ON_CRASH" ,
328
328
question_uuid = None ,
329
+ parent_question_uuid = None ,
329
330
push_endpoint = None ,
330
331
asynchronous = False ,
331
332
timeout = 86400 ,
@@ -342,6 +343,7 @@ def ask(
342
343
:param bool allow_local_files:
343
344
:param str save_diagnostics:
344
345
:param str|None question_uuid:
346
+ :param str|None parent_question_uuid:
345
347
:param str|None push_endpoint:
346
348
:param bool asynchronous:
347
349
:param float|None timeout:
@@ -356,6 +358,7 @@ def ask(
356
358
allow_local_files = allow_local_files ,
357
359
save_diagnostics = save_diagnostics ,
358
360
question_uuid = question_uuid ,
361
+ parent_question_uuid = parent_question_uuid ,
359
362
push_endpoint = push_endpoint ,
360
363
asynchronous = asynchronous ,
361
364
timeout = timeout ,
@@ -380,6 +383,7 @@ def ask(
380
383
"datetime" : "2024-04-11T10:46:48.236064" ,
381
384
"uuid" : "a9de11b1-e88f-43fa-b3a4-40a590c3443f" ,
382
385
"question_uuid" : question_uuid ,
386
+ "parent_question_uuid" : parent_question_uuid ,
383
387
"forward_logs" : subscribe_to_logs ,
384
388
"save_diagnostics" : save_diagnostics ,
385
389
"order" : 0 ,
0 commit comments