File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -286,7 +286,7 @@ export MACOS="${MACOS}"
286286
287287# # Create venv
288288if [[ $( type -p uv) ]]; then
289- uv venv -p 3.12 " ${SWAP_DATADIR} /venv" --seed
289+ uv venv -p ${py_maj} . ${py_min} " ${SWAP_DATADIR} /venv" --seed
290290else
291291 python3 -m venv " ${SWAP_DATADIR} /venv"
292292fi
Original file line number Diff line number Diff line change @@ -10,6 +10,10 @@ export TOR_DNS_PORT=15353
1010export BSX_LOCAL_TOR=true # sets host to 127.0.0.1
1111export BSX_ALLOW_ENV_OVERRIDE=true # required to change the ports
1212
13+ # Python vwrsion
14+ export py_maj=3
15+ export py_min=13
16+
1317# Network
1418[[ " ${1}${2}${3}${4}${5} " == * " regtest" * ]] && export regtest=" --regtest"
1519
Original file line number Diff line number Diff line change 11#! /bin/bash
2+ source bsx/shared.sh
23
34# Move scripts
45rm -r $HOME /.local/bin/bsx $HOME /.local/bin/basicswap-*
@@ -8,6 +9,16 @@ echo "Updating BasicSwapDEX" && sleep 1
89# Delete dangling build folder. Same as --no-cache for docker
910rm -rf $SWAP_DATADIR /basicswap/build
1011
12+ # Check and update UV python version
13+ if type -p uv; then
14+ cd $SWAP_DATADIR
15+ if uv run python -c " import sys; exit(0 if sys.version_info <= (${py_maj} ,${py_min} ) else 1)" ; then
16+ rm -rf venv
17+ green " Updating uv Python to ${py_maj} .${py_min} "
18+ uv venv -p ${py_maj} .${py_min} " ${SWAP_DATADIR} /venv" --seed
19+ fi
20+ fi
21+
1122# BasicSwap, coincurve, and dependencies
1223# Switch to new repo: basicswap/basicswap
1324cd $SWAP_DATADIR /basicswap
You can’t perform that action at this time.
0 commit comments