future-van-44061
05/26/2025, 9:47 AMmac M1 silicon
. I have done the following:
Python3 via pyenv - 3.11.7
pants.tomal has version ->> 2.26
I am installing pants via brew install pants
when i do pants --version
--> getting verison as 2
.
When trying to run any command i am getting below error :
usage: /opt/homebrew/bin/pants [-h] [-V] {bootstrap-cache-key,bootstrap-version,help} ...
/opt/homebrew/bin/pants: error: argument {bootstrap-cache-key,bootstrap-version,help}: invalid choice: 'export' (choose from 'bootstrap-cache-key', 'bootstrap-version', 'help')
Can someone please help me here what should i do?wide-midnight-78598
05/26/2025, 11:49 AM2.26
or 2.26.0
?future-van-44061
05/26/2025, 11:49 AMwide-midnight-78598
05/26/2025, 11:54 AMpants --version
in there? It should ask to create a pants.toml
⏺ scratch/testpants % pants --version
No Pants configuration was found at or above /Users/sj/Developer/scratch/testpants.
Would you like to configure /Users/sj/Developer/scratch/testpants as a Pants project? (Y/n): y
Fetching latest stable Pants version since none is configured
Creating /Users/sj/Developer/scratch/testpants/pants.toml and configuring it to use Pants 2.26.0
07:52:37.62 [INFO] Initializing scheduler...
07:52:37.71 [INFO] Scheduler initialized.
2.26.0
future-van-44061
05/26/2025, 11:58 AMpants --version
. It started downloading ..
Downloading https://github.com/indygreg/python-build-standalone/releases/download/20240107/cpython-3.9.18%2B20240107-aarch64-apple-darwin-install_only
No Pants configuration was found at or above /Users/yyadav/testpants.
Would you like to configure /Users/yyadav/testpants as a Pants project? (Y/n): Y
Fetching latest stable Pants version since none is configured
Creating /Users/yyadav/testpants/pants.toml and configuring it to use Pants 2.26.0
Downloading https://github.com/indygreg/python-build-standalone/releases/download/20240415/cpython-3.11.9%2B20240415-aarch64-apple-darwin-install_only
2
yyadav@sbplt45lfqdhj:/Users/yyadav/testpants $ pants --version
2
yyadav@sbplt45lfqdhj:/Users/yyadav/testpants $wide-midnight-78598
05/26/2025, 11:59 AMls -a
and cat pants.toml
?future-van-44061
05/26/2025, 11:59 AMfuture-van-44061
05/26/2025, 11:59 AMwide-midnight-78598
05/26/2025, 12:00 PMwide-midnight-78598
05/26/2025, 12:01 PMwide-midnight-78598
05/26/2025, 12:01 PMfuture-van-44061
05/26/2025, 12:02 PMwide-midnight-78598
05/26/2025, 12:03 PMPANTS_BOOTSTRAP_VERSION=report pants
?future-van-44061
05/26/2025, 12:04 PMwide-midnight-78598
05/26/2025, 12:04 PMfuture-van-44061
05/26/2025, 12:05 PMPANTS_BOOTSTRAP_VERSION=report pants
usage: /Users/yyadav/.local/bin/pants [-h] [-V] {bootstrap-cache-key,bootstrap-version,help} ...
positional arguments:
{bootstrap-cache-key,bootstrap-version,help}
bootstrap-cache-key
Print an opaque value that can be used as a key for accurate and safe caching of the pants bootstrap directories. (Added in
bootstrap version 1.)
bootstrap-version Print a version number for the bootstrap script itself. Distributed scripts (such as reusable CI formulae) that use these
bootstrap tools should set PANTS_BOOTSTRAP_TOOLS to the minimum script version for the features they require. For example,
if 'some-tool' was added in version 123: PANTS_BOOTSTRAP_TOOLS=123 ./pants some-tool (Added in bootstrap version 1.)
help Show this help.
options:
-h, --help show this help message and exit
-V, --version show program's version number and exit
wide-midnight-78598
05/26/2025, 12:06 PMscratch/testpants % PANTS_BOOTSTRAP_VERSION=report pants
0.12.3
Though I'm confused why, above, you have usage: /opt/homebrew/bin/pants
and here you have usage: /Users/yyadav/.local/bin/pants
future-van-44061
05/26/2025, 12:07 PMfuture-van-44061
05/26/2025, 12:07 PMPANTS_BOOTSTRAP_VERSION=report pants
0.12.3
usage: /Users/yyadav/.local/bin/pants [-h] [-V] {bootstrap-cache-key,bootstrap-version,help} ...
positional arguments:
{bootstrap-cache-key,bootstrap-version,help}
bootstrap-cache-key
Print an opaque value that can be used as a key for accurate and safe caching of the pants bootstrap directories. (Added in
bootstrap version 1.)
bootstrap-version Print a version number for the bootstrap script itself. Distributed scripts (such as reusable CI formulae) that use these
bootstrap tools should set PANTS_BOOTSTRAP_TOOLS to the minimum script version for the features they require. For example,
if 'some-tool' was added in version 123: PANTS_BOOTSTRAP_TOOLS=123 ./pants some-tool (Added in bootstrap version 1.)
help Show this help.
options:
-h, --help show this help message and exit
-V, --version show program's version number and exit
zsh: command not found: 0.12.3
wide-midnight-78598
05/26/2025, 12:09 PMfuture-van-44061
05/26/2025, 12:10 PMpyenv versions
system
3.11.7
3.11.7/envs/venv_sbp_datalake
* venv_sbp_datalake --> /Users/yyadav/.pyenv/versions/3.11.7/envs/venv_sbp_datalake (set by PYENV_VERSION environment variable)
python --version
Python 3.11.7
future-van-44061
05/26/2025, 12:11 PMfuture-van-44061
05/26/2025, 12:11 PMwide-midnight-78598
05/26/2025, 12:11 PMzsh: command not found: 0.12.3
You also got this, which would happen if 0.12.3 was written down.
In either case, pants comes with its own interpreterfuture-van-44061
05/26/2025, 12:12 PMfuture-van-44061
05/26/2025, 12:14 PMexport ARCHFLAGS="-arch x86_64"
# Path to your oh-my-zsh installation.
export ZSH="$HOME/.oh-my-zsh"
# Set name of the theme to load --- if set to "random", it will
# load a random theme each time oh-my-zsh is loaded, in which case,
# to know which specific one was loaded, run: echo $RANDOM_THEME
# See <https://github.com/ohmyzsh/ohmyzsh/wiki/Themes>
ZSH_THEME="maran"
# Set list of themes to pick from when loading at random
# Setting this variable when ZSH_THEME=random will cause zsh to load
# a theme from this variable instead of looking in $ZSH/themes/
# If set to an empty array, this variable will have no effect.
# ZSH_THEME_RANDOM_CANDIDATES=( "robbyrussell" "agnoster" )
# Uncomment the following line to use case-sensitive completion.
# CASE_SENSITIVE="true"
# Uncomment the following line to use hyphen-insensitive completion.
# Case-sensitive completion must be off. _ and - will be interchangeable.
# HYPHEN_INSENSITIVE="true"
# Uncomment one of the following lines to change the auto-update behavior
# zstyle ':omz:update' mode disabled # disable automatic updates
# zstyle ':omz:update' mode auto # update automatically without asking
# zstyle ':omz:update' mode reminder # just remind me to update when it's time
# Uncomment the following line to change how often to auto-update (in days).
# zstyle ':omz:update' frequency 13
# Uncomment the following line if pasting URLs and other text is messed up.
# DISABLE_MAGIC_FUNCTIONS="true"
# Uncomment the following line to disable colors in ls.
# DISABLE_LS_COLORS="true"
# Uncomment the following line to disable auto-setting terminal title.
# DISABLE_AUTO_TITLE="true"
# Uncomment the following line to enable command auto-correction.
# ENABLE_CORRECTION="true"
# Uncomment the following line to display red dots whilst waiting for completion.
# You can also set it to another string to have that shown instead of the default red dots.
# e.g. COMPLETION_WAITING_DOTS="%F{yellow}waiting...%f"
# Caution: this setting can cause issues with multiline prompts in zsh < 5.7.1 (see #5765)
# COMPLETION_WAITING_DOTS="true"
source $ZSH/oh-my-zsh.sh
alias pycharm='open -na "PyCharm CE.app" --args "$@"'
if command -v pyenv 1>/dev/null 2>&1; then
eval "$(pyenv init -)"
fi
export SCIE_BOOT=bootstrap-tools
export PATH="$(pwd):$PATH"
future-van-44061
05/26/2025, 12:14 PMwide-midnight-78598
05/26/2025, 12:14 PMexport SCIE_BOOT=bootstrap-tools
can you delete this?future-van-44061
05/26/2025, 12:16 PMrm -rf $HOME/Library/Caches/nce
wide-midnight-78598
05/26/2025, 12:16 PMwide-midnight-78598
05/26/2025, 12:17 PMfuture-van-44061
05/26/2025, 12:17 PMwide-midnight-78598
05/26/2025, 12:17 PMfuture-van-44061
05/26/2025, 12:17 PMwide-midnight-78598
05/26/2025, 12:18 PMprintenv
and look for anything related to SCIE or PANTSwide-midnight-78598
05/26/2025, 12:19 PMscratch/testpants % SCIE_BOOT=bootstrap-tools pants --version
2
This is certainly the problemfuture-van-44061
05/26/2025, 12:19 PMPATH=/Users/yyadav/repos/sbp-datalake:/Users/yyadav/.pyenv/shims:/opt/homebrew/bin:/opt/homebrew/sbin:/Users/yyadav/repos/sbp-datalake:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/usr/local/go/bin:/Users/yyadav/.cargo/bin
__CFBundleIdentifier=com.jetbrains.pycharm.ce
SHELL=/bin/zsh
TERM=xterm-256color
COMMAND_MODE=unix2003
TERMINAL_EMULATOR=JetBrains-JediTerm
LC_CTYPE=UTF-8
XPC_SERVICE_NAME=0
IDEA_INITIAL_DIRECTORY=/
HOME=/Users/yyadav
SHLVL=1
PWD=/Users/yyadav/repos/sbp-datalake
OLDPWD=/Users/yyadav/repos/sbp-datalake
HOMEBREW_PREFIX=/opt/homebrew
HOMEBREW_CELLAR=/opt/homebrew/Cellar
HOMEBREW_REPOSITORY=/opt/homebrew
INFOPATH=/opt/homebrew/share/info:/opt/homebrew/share/info:
ARCHFLAGS=-arch x86_64
ZSH=/Users/yyadav/.oh-my-zsh
PAGER=less
LESS=-R
LSCOLORS=Gxfxcxdxbxegedabagacad
LS_COLORS=di=1;36:ln=35:so=32:pi=33:ex=31:bd=34;46:cd=34;43:su=30;41:sg=30;46:tw=30;42:ow=30;43
PYENV_SHELL=zsh
_=/usr/bin/printenv
wide-midnight-78598
05/26/2025, 12:22 PM.pants.d
and yeah, maybe even wipe out the ~/.cache/pants
and ``~/Library/Caches/nce` `
I'd also probably remove the pants from ~/.local and I'd also brew remove pants, and then re-install itwide-midnight-78598
05/26/2025, 12:22 PMwide-midnight-78598
05/26/2025, 12:23 PMscratch/testpants % SCIE_BOOT=bootstrap-tools pants tailor
usage: /opt/homebrew/bin/pants [-h] [-V] {bootstrap-cache-key,bootstrap-version,help} ...
/opt/homebrew/bin/pants: error: argument {bootstrap-cache-key,bootstrap-version,help}: invalid choice: 'tailor' (choose from 'bootstrap-cache-key', 'bootstrap-version', 'help')
future-van-44061
05/26/2025, 12:23 PMwide-midnight-78598
05/26/2025, 12:25 PMscratch/testpants % SCIE_BOOT=list pants
Error: `SCIE_BOOT=list` was found in the environment but "list" does not correspond to any scie-pants commands.
Isolates your Pants from the elements.
Please select from the following boot commands:
<default> (when SCIE_BOOT is not set in the environment) Detects the current Pants installation and launches it.
bootstrap-tools Introspection tools for the Pants bootstrap process.
update Update scie-pants.
You can select a boot command by setting the SCIE_BOOT environment variable.
wide-midnight-78598
05/26/2025, 12:27 PMscratch/testpants % SCIE=list pants
scie-pants
bootstrap-tools
pants
pants-debug
update
future-van-44061
05/26/2025, 12:28 PMSCIE=list pants
`No valid Python interpreter found. For pants_version = "2.26.0"
, Pants requires Python 3.7, 3.8, or 3.9 to run. Please check that a valid interpreter is installed and on your $PATH.`future-van-44061
05/26/2025, 12:29 PMpants --version
future-van-44061
05/26/2025, 12:29 PMpython --version
Python 3.11.7
wide-midnight-78598
05/26/2025, 12:30 PMSCIE_
to the start/env unless you know what's going on. pants
alone should be enough.
Pants also comes bundled with a python version that it needs.... It feels like yours is running the old bash script, but maybe brew install python 3.9 and try that? Shouldn't be required, but maybe there is a bugfuture-van-44061
05/26/2025, 12:34 PMBootstrapping Pants using /opt/homebrew/bin/python3.9
Creating the virtualenv PEX.
Downloading the Pex PEX.
SHA256 fingerprint of <https://github.com/pantsbuild/pex/releases/download/v2.1.103/pex> verified.
Installing pantsbuild.pants==2.26.0 into a virtual environment at /Users/yyadav/.cache/pants/setup/bootstrap-Darwin-arm64/2.26.0_py39
ERROR: Could not find a version that satisfies the requirement pantsbuild.pants==2.26.0 (from versions: 0.0.17, 0.0.18, 0.0.20, 0.0.21, 0.0.22, 0.0.23, 0.0.24, 0.0.25, 0.0.26, 0.0.27, 0.0.28, 0.0.29, 0.0.30, 0.0.31, 0.0.32, 0.0.33, 0.0.34, 0.0.35, 0.0.36, 0.0.37, 0.0.38, 0.0.39, 0.0.40, 0.0.41, 0.0.42, 0.0.43, 0.0.44, 0.0.45, 0.0.46, 0.0.47, 0.0.48, 0.0.49, 0.0.50, 0.0.51, 0.0.52, 0.0.53, 0.0.54, 0.0.55, 0.0.56, 0.0.57, 0.0.58, 0.0.59, 0.0.60, 0.0.61, 0.0.62, 0.0.63, 0.0.64, 0.0.65, 0.0.66, 0.0.67, 0.0.68, 0.0.69, 0.0.70, 0.0.71, 0.0.72, 0.0.73, 0.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rc0, 2.15.2, 2.16.0a0, 2.16.0a1, 2.16.0rc0, 2.16.0rc1, 2.16.0rc2, 2.16.0rc3, 2.16.0rc4, 2.16.0rc5, 2.16.0rc6, 2.16.0rc7, 2.16.0, 2.16.1rc0, 2.16.1rc3, 2.16.1rc4, 2.16.1, 2.17.0.dev0, 2.17.0.dev1, 2.17.0.dev2, 2.17.0.dev3, 2.17.0.dev4, 2.17.0.dev5, 2.17.0a1, 2.17.0rc0, 2.17.0rc1, 2.17.0rc2, 2.17.0rc3, 2.17.0rc4, 2.17.0rc5, 2.17.0, 2.17.1rc0, 2.17.1rc1, 2.17.1rc2, 2.17.1rc3, 2.17.1, 2.18.0.dev0, 2.18.0.dev1, 2.18.0.dev3, 2.18.0.dev4, 2.18.0.dev5, 2.18.0.dev6, 2.18.0.dev7, 2.18.0a0)
ERROR: No matching distribution found for pantsbuild.pants==2.26.0
wide-midnight-78598
05/26/2025, 12:35 PMfuture-van-44061
05/26/2025, 12:35 PMwide-midnight-78598
05/26/2025, 12:35 PMpants
file?
This all looks like it's trying to build using the old scriptfuture-van-44061
05/26/2025, 12:36 PMwide-midnight-78598
05/26/2025, 12:36 PMwide-midnight-78598
05/26/2025, 12:36 PMwhich pants
?future-van-44061
05/26/2025, 12:38 PM/Users/yyadav/repos/sbp-datalake/pants
yes, it is taking a old script. from the project folderwide-midnight-78598
05/26/2025, 12:39 PMwide-midnight-78598
05/26/2025, 12:39 PMPATH=/Users/yyadav/repos/sbp-datalake:
future-van-44061
05/26/2025, 12:40 PMwide-midnight-78598
05/26/2025, 12:41 PMpants
it's hitting that script instead of the brew installfuture-van-44061
05/26/2025, 12:46 PMpath
sourced it again ..
yyadav@sbplt45lfqdhj:/Users/yyadav/testpants $ pants --version
Downloading <https://github.com/indygreg/python-build-standalone/releases/download/20240107/cpython-3.9.18%2B20240107-aarch64-apple-darwin-install_only>
No Pants configuration was found at or above /Users/yyadav/testpants.
Would you like to configure /Users/yyadav/testpants as a Pants project? (Y/n): Y
Fetching latest stable Pants version since none is configured
Setting [GLOBAL] pants_version = "2.26.0" in /Users/yyadav/testpants/pants.toml
Backing up /Users/yyadav/testpants/pants.toml to /Users/yyadav/testpants/pants.toml.bak
Downloading <https://github.com/indygreg/python-build-standalone/releases/download/20240415/cpython-3.11.9%2B20240415-aarch64-apple-darwin-install_only>
Downloading <https://github.com/indygreg/python-build-standalone/releases/download/20240415/cpython-3.11.9%2B20240415-aarch64-apple-darwin-install_only>
2
yyadav@sbplt45lfqdhj:/Users/yyadav/testpants $ pants --version
2
wide-midnight-78598
05/26/2025, 12:46 PMprintenv
?future-van-44061
05/26/2025, 12:47 PMTERM_SESSION_ID=w0t0p0:1BF823C5-54E5-4434-88AD-A5DF73E9BAD0
SSH_AUTH_SOCK=/private/tmp/com.apple.launchd.U168v9ArdA/Listeners
LC_TERMINAL_VERSION=3.5.14
COLORFGBG=7;0
ITERM_PROFILE=Default
XPC_FLAGS=0x0
LANG=nl_NL.UTF-8
PWD=/Users/yyadav/testpants
SHELL=/bin/zsh
__CFBundleIdentifier=com.googlecode.iterm2
TERM_FEATURES=T3LrMSc7UUw9Ts3BFGsSyHNoSxF
TERM_PROGRAM_VERSION=3.5.14
TERM_PROGRAM=<http://iTerm.app|iTerm.app>
PATH=/Users/yyadav/testpants:/Users/yyadav/.pyenv/shims:/opt/homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/usr/local/go/bin:/Users/yyadav/.cargo/bin:/Applications/iTerm.app/Contents/Resources/utilities
LC_TERMINAL=iTerm2
COLORTERM=truecolor
COMMAND_MODE=unix2003
TERM=xterm-256color
TERMINFO_DIRS=/Applications/iTerm.app/Contents/Resources/terminfo:/usr/share/terminfo
HOME=/Users/yyadav
TMPDIR=/var/folders/gk/xfkvrv8s47b5l3rhs1sj9q4h0000gq/T/
USER=yyadav
XPC_SERVICE_NAME=0
SHLVL=1
OLDPWD=/Users/yyadav
HOMEBREW_PREFIX=/opt/homebrew
HOMEBREW_CELLAR=/opt/homebrew/Cellar
HOMEBREW_REPOSITORY=/opt/homebrew
INFOPATH=/opt/homebrew/share/info:
ARCHFLAGS=-arch x86_64
ZSH=/Users/yyadav/.oh-my-zsh
PAGER=less
LESS=-R
LSCOLORS=Gxfxcxdxbxegedabagacad
LS_COLORS=di=1;36:ln=35:so=32:pi=33:ex=31:bd=34;46:cd=34;43:su=30;41:sg=30;46:tw=30;42:ow=30;43
PYENV_SHELL=zsh
SCIE_BOOT=bootstrap-tools
PS1=%{$fg[cyan]%}%n%{$reset_color%}@%{$fg[yellow]%}%M:%{$fg[green]%}%/%{$reset_color%}$(git_prompt_info) %(!.#.$)
LDFLAGS=-L/opt/homebrew/opt/openssl@3/lib -L/opt/homebrew/opt/readline/lib -L/opt/homebrew/opt/zlib/lib
CPPFLAGS=-I/opt/homebrew/opt/openssl@3/include -I/opt/homebrew/opt/readline/include -I/opt/homebrew/opt/zlib/include
PKG_CONFIG_PATH=/opt/homebrew/opt/openssl@3/lib/pkgconfig:/opt/homebrew/opt/readline/lib/pkgconfig:/opt/homebrew/opt/zlib/lib/pkgconfig
_=/usr/bin/printenv
wide-midnight-78598
05/26/2025, 12:48 PMSCIE_BOOT=bootstrap-tools
is still therefuture-van-44061
05/26/2025, 12:48 PMfuture-van-44061
05/26/2025, 12:50 PMwide-midnight-78598
05/26/2025, 12:51 PMpants
will defer to the local script if there is one. That might mean you need to re-install python3.9, but the pants runner shouldn't affect anythingfuture-van-44061
05/26/2025, 12:52 PMfuture-van-44061
05/26/2025, 12:52 PMwide-midnight-78598
05/26/2025, 12:53 PM