Skip to content

Commit

Permalink
Use action_tag instead of default
Browse files Browse the repository at this point in the history
  • Loading branch information
dannon authored and mvdbeek committed Jul 10, 2024
1 parent 0d0e2a1 commit 6be9f23
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lib/galaxy/web/framework/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -251,8 +251,13 @@ def handle_request(self, request_id, path_info, environ, start_response, body_re
raise
trans.controller = controller_name
trans.action = action

# Action can still refer to invalid and/or inaccurate paths here, so we use the actual
# controller and method names to set the timing key.

action_tag = getattr(method, "__name__", "default")
environ["controller_action_key"] = (
f"{'api' if environ['is_api_request'] else 'web'}.{controller_name}.{action or 'default'}"
f"{'api' if environ['is_api_request'] else 'web'}.{controller_name}.{action_tag}"
)
# Combine mapper args and query string / form args and call
kwargs = trans.request.params.mixed()
Expand Down

0 comments on commit 6be9f23

Please sign in to comment.