Skip to content

Commit e9980ee

Browse files
[v1.2] Fix bootstrapping (#34477)
* Fix bootstrap if repository path contains symlinks. (#32945) Pigweed seems to fail with: ERROR at /home/angus/projects/connectedhomeip/third_party/pigweed/repo/pw_build/facade.gni:187:7: Assertion failed. assert(_dep_is_in_link_dependencies, when the repo path has symlinks in it and bootstrap is run. The workaround is to change to the symlink-resolved path temporarily while doing the pigweed parts of bootstrap.sh. Fixes #31851 * Bump python versions to fix bootstrapping --------- Co-authored-by: Boris Zbarsky <bzbarsky@apple.com>
1 parent 192812d commit e9980ee

File tree

3 files changed

+15
-3
lines changed

3 files changed

+15
-3
lines changed

scripts/setup/bootstrap.sh

+12
Original file line numberDiff line numberDiff line change
@@ -150,8 +150,20 @@ EOF
150150
# bootstrap or run_in_build_env.sh can be executed in a build env
151151
_ORIGINAL_PW_ENVIRONMENT_ROOT="$PW_ENVIRONMENT_ROOT"
152152

153+
# pigweed does not seem to handle pwd involving symlinks very well.
154+
original_pwd=$PWD
155+
if hash realpath 2>/dev/null; then
156+
realpwd="$(realpath "$PWD")"
157+
if [ "$realpwd" != "$PWD" ]; then
158+
echo "Warning: $PWD contains symlinks, using $realpwd instead"
159+
cd "$realpwd"
160+
fi
161+
fi
162+
153163
_bootstrap_or_activate "$0"
154164

165+
cd $original_pwd
166+
155167
if [ "$_ACTION_TAKEN" = "bootstrap" ]; then
156168
# By default, install all extra pip dependencies even if slow. -p/--platform
157169
# arguments may override this default.

scripts/setup/constraints.txt

+2-2
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ colorama==0.4.6
4949
# west
5050
coloredlogs==15.0.1
5151
# via -r requirements.all.txt
52-
construct==2.10.54
52+
construct==2.10.70
5353
# via
5454
# -r requirements.esp32.txt
5555
# esp-coredump
@@ -208,7 +208,7 @@ python-socketio==4.6.1
208208
# via -r requirements.esp32.txt
209209
pytz==2022.7.1
210210
# via pandas
211-
pyyaml==6.0
211+
pyyaml==6.0.1
212212
# via
213213
# esptool
214214
# idf-component-manager

scripts/setup/requirements.esp32.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ pygdbmi<=0.9.0.2
88
reedsolo>=1.5.3,<=1.5.4
99
bitstring>=3.1.6,<4
1010
ecdsa>=0.16.0
11-
construct==2.10.54
11+
construct==2.10.70
1212
python-socketio<5
1313
itsdangerous<2.1 ; python_version < "3.11"
1414
esp_idf_monitor==1.1.1

0 commit comments

Comments
 (0)