lwip submodule should point to a tag or branch tip in the remote repository #1244
Labels
No labels
bazel
bluetooth
board settings
boot_stage2
bug
build
c++
can't reproduce
clang
clib-interface
cmsis
code cleanliness
code size
compiler version issues
cyw43_driver
debug
discussion
documentation
duplicate
dynamic_clock
elf2uf2
enhancement
errata
filesystem
flash layout
floating point
FreeRTOS
hardware_adc
hardware_claim
hardware_clocks
hardware_dma
hardware_exception
hardware_flash
hardware_gpio
hardware_i2c
hardware_irq
hardware_pio
hardware_pwm
hardware_rcp
hardware_rtc
hardware_spi
hardware_sync
hardware_uart
hardware_vreg
hardware_watchdog
hardware_xosc
help wanted
host
IAR
installation
invalid
linker scripts
lto
lwip
mbedtls
missing API
needs reporter detail
networking
newlib
newlib-multicore
non-c
non-cmake
non-gcc
openocd
orphan PR
OS integration
pico_async_context
pico_base
pico_binary_info
pico_flash
picolibc
pico_lwip
pico_malloc
pico_multicore
pico_printf
pico_runtime
pico_stdio
pico_stdio_usb
pico_sync
pico_time
pico_util
pioasm
port
question
review
review2
rtos interop
runtime init
static library
svd
test
tinyusb
vscode
wifi integration
wontfix
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
gh-raspberrypi/pico-sdk#1244
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Currently the lwip submodule points to an arbitrary commit c385f31076b27efb8ee37f00cb5568783a58f299. Most git servers, including GNU Savannah, only allow shallow clones of branch tips and tags. This means if you do a shallow recursive clone of pico-extras (for example, in a CI pipeline), you will get the following error:
User must instead do a full clone of the submodule, which might mean doing a full clone of pico-extras too. This is slow, wastes bandwidth and electricity, uses up extra Actions minutes, and hammers the GNU servers.
This can be fixed by either changing the submodule to point to an existing tag or branch (if branch, you have to keep on updating the submodule whenever the branch tip changes), or by forking the upstream repository and adding a tag to the commit you want to use, and then adjusting the submodule to point to your fork.
I believe the contents of this repo are basically "unsupported, use at your own risk", and I'm not aware of any plans to actively update the contents of this repo.
Looking at https://savannah.nongnu.org/projects/lwip/ I see that lwIP 2.1.2 was released in November 2018 and lwIP 2.1.3 was released in November 2021. I've never looked at any of the lwIP stuff myself, so would you be willing to do some testing to see if
STABLE-2_1_3_RELEASEwould be a suitable tag for us to pin the submodule to?yes we can update the tag if you find one that works
I have never used lwip either. I don't know what it is supposed to do. The only reason I even know it exists is because of the build failure it causes. There are no mentions of it anywhere in pico-sdk or pico-playground repositories and the only use in pico-extras is where the platform code initializes it. As such it isn't clear how I would determine whether it is working correctly or not, since it doesn't actually do anything.
I can tell you that 2.1.x is a stable release with backported fixes and therefore does not contain every commit present in c385f3107 because it branched when 2.1.0 was released in 2018.
pico-extrasis effectively a "use at your own risk" collection of not-yet-officially-supported code, so it might be better to copy out the parts that you need into your own project, rather than trying to clone the whole repo during your CI process? 🤷♂️then, you should be able just add:
to the top of your CMakeLists.txt (before you init the SDK)
That won't help because the problem occurs during the cloning of the repository:
well it is the only submodule, so you don't need to do a recursive clone...
... should be a workaround until we update it.
This seems to work for me on the sdk
git clone --recursive --depth 1 --shallow-submodules https://github.com/raspberrypi/pico-sdk
For lwip in the sdk, we are a few commits from the tip of master (not entirely sure why we made that decision) presumably it's moved on a few commits since mid 2022.
Not sure what there is to do here, I guess it would do no harm to move to the tip.
I am not sure why it works now. It could be because the remote now points to the github mirror instead of savannah, and github might configure their servers differently. They never used to allow this either though.
um; i'm a bit confused, as this issue seems to refer repeatedly to
pico-extrasnotpico-sdk... in any case it doesn't seem like #1369 is a suitable fix anyway, so won't fixing this for now - please re-open if there is still an issueThis issue was opened when lwip was a submodule of pico-extras. It is now a submodule of pico-sdk, and you moved the issue here when lwip was moved.
ha
anyways, i'm not sure there is much to be done, unless lwip makes a newer tag, right?
It does seem that this is no longer a problem. I am not sure why because github definitely is not advertising
github.com/lwip-tcpip/lwip@239918ccc1(you can confirm this withgit ls-remote.) It seems to be a change in the behavior of the git command itself, to download the full remote even when you ask for a shallow clone - and then discard anything it doesn't need.(Could still also be related to github server configuration, since when this issue was opened the submodule was not hosted on Github.)
This definitely seems like a difference in github behavior. Attempting to shallow clone an old tag of pico-extras:
git clone --branch sdk-1.2.0 --depth 1 --recursive --shallow-submodules https://github.com/raspberrypi/pico-extras
still results in the failure (because it is fetching from savannah).