Error with poetry and python when running gdk rake setup_ai_gateway

Overview

Setting up AI Gateway with the provided GDK commands results in poetry and then python errors.

The problem is ultimately with this command:

make gitlab-ai-gateway-update

Error:

  --------------------------------------------------------------------------------
  Performing poetry steps for /Users/pamartiaga/Code/gdk/gitlab-ai-gateway
  --------------------------------------------------------------------------------
  # Set Python version for poetry to fix Python upgrades.
  xargs: poetry: No such file or directory
  make[1]: *** [gitlab-ai-gateway-poetry-install] Error 127
  make: *** [gitlab-ai-gateway-update-timed] Error 2
  [2025-10-20 16:17:14.266363] ERROR: --- Task update:make:gitlab-ai-gateway-update failed ---
  [sentry] `config.logger` is deprecated. Please use `config.sdk_logger` instead.

❌️ ERROR: Updating GDK failed. Make sure `gdk update` command succeeds in your terminal.

Workaround - use poetry globally:

mise use --global poetry

New Error after workaround

--------------------------------------------------------------------------------
Performing poetry steps for /Users/pamartiaga/Code/gdk/gitlab-ai-gateway
--------------------------------------------------------------------------------
# Set Python version for poetry to fix Python upgrades.

Could not find the python executable 3.12.12
make[1]: *** [gitlab-ai-gateway-poetry-install] Error 1
make: *** [gitlab-ai-gateway-update-timed] Error 2

Workaround - use python globally

mise use --global python@3.12

Actual Issue

The .tool-versions in the GDK root directory doesn't list poetry and python, so mise can't find these. It's probably best to add a poetry and python versions here rather than assume that the developer has these installed globally.

Alternately, the gitlab-ai-gateway directory has both poetry and python configured in the .tool-versions. So we just need to make sure that when running make gitlab-ai-gateway-update, the relevant setup command is being run in the gitlab-ai-gateway directory.

Impacted categories

The following categories relate to this issue:

Steps to replicate (optional)

Proposal (optional)

Environment (optional)

  • Operating system name: <!-- output of `uname -a` command -->
  • Architecture: <!-- output of `arch` or `uname -m` command -->
  • The contents of your gdk.yml (if any)
  • Ruby version: <!-- output of `ruby --version` command -->
  • GDK version: <!-- output of `git rev-parse --short HEAD` command -->
Edited by Pam Artiaga