Does the Parent-child stream functionality in the ...
# singer-tap-development
j
Does the Parent-child stream functionality in the SDK make it possible to modify things other than the
path
attribute of the child stream? I need to use those parent context keys to update the request payload.
a
Hi, @josh_lloyd - I believe you should get the parent keys anywhere you see
context
in the method signature. The
context
object should always be one of the following: 1. If this is a child stream: a. The parent's get_child_context() result if defined. b. The second object in the tuple if get_records() returns a tuple. c. The parent's record dict if neither of the above is true. 2. If not a child stream and
partitions
property is defined: the value of the active partition. 3. Otherwise:
None
Does this help?
j
yes! I’ll give this a shot. Thank you! Rereading the docs makes me realize this was there all along, but it didn’t dawn on me to try it this way, sorry 😞
a
No prob 😄 Happy to help