sparse-intern-71089
08/13/2020, 6:00 PMwhite-balloon-205
get_policy_document don't accept Output[T] values as inputs, only raw strings and such, so the user.arn.apply(lambda arn: arn) above looks likely to be problematic.
The typical approach is to call get_policy_document inside the apply. Which is typcially done by creating a helper function that will call this function with the real str value, and passing that function to apply.