hi, I’ve encounter problems when using the metafl...
# dev-metaflow
a
hi, I’ve encounter problems when using the metaflow bot. I was able to query @gentle-yak-12399 tell me a joke without any problem. However, when i perform
Copy code
@flowey inspect HelloWorld
I get the following error:
Copy code
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/metaflowbot/actions/runs/commands.py", line 35, in inspect_run
    runs = resolver.resolve(runspec)
  File "/usr/local/lib/python3.7/site-packages/metaflowbot/actions/runs/run_resolver.py", line 140, in resolve
    runs = list(self._query(query, max_runs))
  File "/usr/local/lib/python3.7/site-packages/metaflowbot/actions/runs/run_resolver.py", line 186, in _query
    flow = Flow(query["flow"])
  File "/usr/local/lib/python3.7/site-packages/metaflow/client/core.py", line 1445, in __init__
    super(Flow, self).__init__(*args, **kwargs)
  File "/usr/local/lib/python3.7/site-packages/metaflow/client/core.py", line 331, in __init__
    self._object = self._get_object(*ids)
  File "/usr/local/lib/python3.7/site-packages/metaflow/client/core.py", line 357, in _get_object
    result = self._metaflow.metadata.get_object(self._NAME, 'self', None, *path_components)
  File "/usr/local/lib/python3.7/site-packages/metaflow/metadata/metadata.py", line 367, in get_object
    return cls._get_object_internal(obj_type, type_order, sub_type, sub_order, filters, *args)
  File "/usr/local/lib/python3.7/site-packages/metaflow/plugins/metadata/service.py", line 165, in _get_object_internal
    return MetadataProvider._apply_filter([cls._request(None, url)], filters)[0]
  File "/usr/local/lib/python3.7/site-packages/metaflow/plugins/metadata/service.py", line 312, in _request
    resp.text)
metaflow.plugins.metadata.service.ServiceException: Metadata request (/flows/HelloWorld) failed (code 403): {"message":"Forbidden"}
Anyone have encounter this problem ? Any help is much appreciated. Things i’ve done to check: 1. Performing curl test on the metaflow api endpoint responding properly
Copy code
curl -v -H 'x-api-key: <TOKEN>' https://<METADATA SERVICE HOST>/api/flows/HelloWorld
Resulted in
Copy code
{"flow_id": "HelloWorld", "user_name": null, "ts_epoch": 1630454013817, "tags": null, "system_tags": null}* Closing connection 0
2. Running test of the endpoint is setup properly
Copy code
@flowey version
Resulted:
Copy code
Running Metaflowbot version 1.0.0 with Metaflow version 2.3.3 and configured with metaflow service endpoint - https://<METADATA_SERVICE_HOST>.execute-api.<AWS_REGION>.<http://amazonaws.com/api/|amazonaws.com/api/>
3. The metaflow bot is deployed as described in the https://github.com/outerbounds/metaflowbot/blob/main/deployment/mfbot-cfn-template.yml
1
g
Hey, I am @gentle-yak-12399, the Metaflowbot 🤖! I can help you to inspect results of past runs. If you want to inspect results, type the following commands for more information: @gentle-yak-12399 how to inspect run or @gentle-yak-12399 how to inspect.
👋 2
a
you prob have done this already but I'd still triple check if the auth token in the secrets manager is correct
one thing that tripped me over a couple times in the past is having extra spaces there
i'd try getting the secret value using CLI (https://docs.aws.amazon.com/cli/latest/reference/secretsmanager/get-secret-value.html) to eyeball it
(it will be in JSON format so it is easier to spot any weird stuff, compared to AWS console)
a
@adventurous-gigabyte-81428 Would you like to jump on a quick call with @hallowed-glass-14538 to debug this live?
a
Currently in a meeting. Perhaps we can arrange another time ?
a
Yep! Just let us know when works best for you!