-
-
Notifications
You must be signed in to change notification settings - Fork 481
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tox.ini: Add wsl
as a technology, to complement local
and docker
#30505
Comments
comment:1
This ticket is for a different purpose, namely portability testing - where you run Sage against various Linux distributions (and configurations, i.e., what system packages are installed). We do this with Docker, but on a Windows development box it may be more convenient to do it with isolated WSL instances instead. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
comment:5
Tobias, can we try to get this ticket going? Basically I want to add to the top-level tox.ini a way to create a new (isolated) WSL instance (with several options for the Linux distribution to use). |
comment:6
What exactly do you want to accomplish? Do you want to add a tox command that downloads a given ubuntu distro, installs it as a wsl, installs sage including all dependencies and then run all tests in this wsl? If that's the case, why do you want to manage the wsl installation from within tox? For integration tests, it would be easier to install wsl with a given linux distro in the github action and then run tox relative to this wsl. For development, it is also easier to let the user setup the initial wsl and reuse it. (By the way, the same also applies to docker images where you can easily run the github action jobs in a docker container and don't need to manage the container from tox, https://www.petefreitag.com/item/903.cfm. This should also somewhat speedup the workflow as github caches the container.) |
comment:7
Replying to @tobiasdiez:
For local testing and debugging of portability issues. GH Actions only goes so far, at some point one needs to get an actual local installation.
No, the point is that the tox command will automate this step so that one has a reproducible way to set up a (disposable) wsl copy. In other words, there is not "the" initial wsl but perhaps a dozen wsls with different configurations. By default, a wsl would be reused but the developer would be able to set it up from scratch using It's the same automation win that the existing |
comment:8
One question that I am unsure about: Where would |
comment:9
Thanks for your explanation. But I still don't really get why you need/want to manage the wsl installation via tox. If tox is able to configure a normal linux install, then it's only one additional step for the user to create a wsl installation with the said linux. Moreover, typical WSL installs are of the order of 2 to 5gb (mine is 22gb, which is used exclusively for sage). That's not something you would use in a use-once-then-throw-away spirit, like docker images. But, of course, you could move the current code in the github wsl workflow to a new tox environment. As a first step towards this, and what I would find actually more important, is to have
That's the same amount of characters as Replying to @mkoeppe:
You would need to have a python installed in windows, then install tox via pip. Tox would usually be invoked from the "Windows Command line" or powershell console. |
This comment has been minimized.
This comment has been minimized.
comment:11
Replying to @tobiasdiez:
OK, sounds good, let's do this as the first step. That's now #30923 |
Dependencies: #30923 |
comment:13
Setting new milestone based on a cursory review of ticket status, priority, and last modification date. |
This is for portability testing of the Sage distribution when developing on Windows, as an alternative to using Docker.
wsl
would be a "technology", likelocal
ordocker
-https://doc.sagemath.org/html/en/developer/portability_testing.html#automatic-docker-based-build-testing-using-tox
The GH workflow for wsl testing from #30216 could then be simplified and generalized by going through tox.
(follow-up from #30216)
References:
Manual install: https://docs.microsoft.com/en-us/windows/wsl/install-manual
Windows Subsystem for Linux Command Reference | Microsoft Docs
https://docs.microsoft.com/en-us/windows/wsl/reference
windows subsystem for linux - How do you install multiple, separate instances of Ubuntu in WSL? - Stack Overflow
https://stackoverflow.com/questions/51584765/how-do-you-install-multiple-separate-instances-of-ubuntu-in-wsl
DDoSolitary/LxRunOffline: A full-featured utility for managing Windows Subsystem for Linux (WSL)
https://github.com/DDoSolitary/LxRunOffline
Manually download Windows Subsystem for Linux (WSL) Distros | Microsoft Docs
https://docs.microsoft.com/en-us/windows/wsl/install-manual
Install Windows Subsystem for Linux (WSL) on Windows 10 | Microsoft Docs
https://docs.microsoft.com/en-us/windows/wsl/install-win10
WSL - Ubuntu Wiki
https://wiki.ubuntu.com/WSL
Depends on #30923
CC: @tobiasdiez @sagetrac-tmonteil
Component: porting
Issue created by migration from https://trac.sagemath.org/ticket/30505
The text was updated successfully, but these errors were encountered: