trying to launch a workflow from another workflow ...
# ask-the-community
a
trying to launch a workflow from another workflow (trigger workflow based on SNS message). what does this "SYSTEM ERROR! Contact platform administrators." mean? my code is belwo and it work on local
Copy code
remote = FlyteRemote(Config.auto(), default_project=project, domain=domain)
wf = remote.fetch_workflow(name=workflow, project=project, domain=domain, version=version)
Copy code
[3/3] currentAttempt done. Last Error: SYSTEM::Traceback (most recent call last):

      File "/usr/local/lib/python3.10/site-packages/flytekit/exceptions/scopes.py", line 219, in user_entry_point
        return wrapped(*args, **kwargs)
      File "/root/workflows/triggers.py", line 25, in sqs_poll_pdf_loop
        wf = remote.fetch_workflow(name=workflow, project=project, domain=domain, version=version)
      File "/usr/local/lib/python3.10/site-packages/flytekit/remote/remote.py", line 384, in fetch_workflow
        admin_workflow = self.client.get_workflow(workflow_id)
      File "/usr/local/lib/python3.10/site-packages/flytekit/clients/friendly.py", line 305, in get_workflow
        super(SynchronousFlyteClient, self).get_workflow(_common_pb2.ObjectGetRequest(id=id.to_flyte_idl()))
      File "/usr/local/lib/python3.10/site-packages/flytekit/clients/raw.py", line 247, in get_workflow
        return self._stub.GetWorkflow(get_object_request, metadata=self._metadata)
      File "/usr/local/lib/python3.10/site-packages/grpc/_interceptor.py", line 277, in __call__
        response, ignored_call = self._with_call(
      File "/usr/local/lib/python3.10/site-packages/grpc/_interceptor.py", line 329, in _with_call
        call = self._interceptor.intercept_unary_unary(
      File "/usr/local/lib/python3.10/site-packages/flytekit/clients/grpc_utils/wrap_exception_interceptor.py", line 44, in intercept_unary_unary
        raise e
      File "/usr/local/lib/python3.10/site-packages/flytekit/clients/grpc_utils/wrap_exception_interceptor.py", line 40, in intercept_unary_unary
        self._raise_if_exc(request, e)
      File "/usr/local/lib/python3.10/site-packages/flytekit/clients/grpc_utils/wrap_exception_interceptor.py", line 31, in _raise_if_exc
        raise FlyteSystemException() from e

Message:

    

SYSTEM ERROR! Contact platform administrators.
y
this looks to be an error with auth or something.
do you have auth enabled? this is the tricky bit with remote tasks… you have to figure out how to access the control plane from the data plane
a
i do have auth enabled
is there a deisgn pattern for how to do it?
y
there’s a few options but it depends on the idp
they should support a basic client credentials concept
and then you can somehow inject those creds into the task container.
and they should be able to auth
a
i see - i thought there is a built-in way but thx - i got it working with manual injection