ruff
ruff copied to clipboard
Docs: Microsoft Visual C++ 2015 Redistributable is required on Windows
OS: Windows 10
ruff: version 0.4.4 (installed via pipx)
Issue
ruff.exe silently fails to run from the terminal if Microsoft Visual C++ 2015 Redistributable is not installed.
Running
> ruff --version
does not show the version in the terminal nor is an error shown. Complete silence.
Double-clicking the executable, located at ..\pipx\venvs\ruff\Scripts\ruff.exe, pops-up the following window
Fix
Install Microsoft Visual C++ 2015 Redistributable, then
> ruff --version
ruff 0.4.4
Suggestion
Perhaps adding something to the docs (https://docs.astral.sh/ruff/installation/) for Windows users that Microsoft Visual C++ 2015 Redistributable must be installed. Either provide the download link (https://www.microsoft.com/en-us/download/details.aspx?id=52685) and/or specify the command to run to install it winget install --exact --id Microsoft.VCRedist.2015+.x64
Currently Windows builds uses msvc runtime. we can eaither use different runtime (using mingw), or statically link it into binary at link time which causes larger binary.
Certainly, those additional options would resolve the external VCRUNTIME###.dll dependency issue. I do not have a preference for which option (update docs, use mingw, statically link, ...) the maintainers of ruff decide to go with.
@BurntSushi what's your experience with statically linking the CRT on windows? Any drawbacks that you've become aware after shipping the change in ripgrep?
https://github.com/BurntSushi/ripgrep/blob/35160a1cdb4c7e2c370e8a7fad6508ff922a33c2/.cargo/config.toml#L4C8-L8
@BurntSushi what's your experience with statically linking the CRT on windows? Any drawbacks that you've become aware after shipping the change in ripgrep?
https://github.com/BurntSushi/ripgrep/blob/35160a1cdb4c7e2c370e8a7fad6508ff922a33c2/.cargo/config.toml#L4C8-L8
Not that I'm aware of! It's been without incident to the point that I totally forgot that this change even happened. :-)
Also, ripgrep's msvc zip archive size went from ~1.6MB in ripgrep 13 to ~1.9MB in ripgrep 14. So at least in compressed form, the size difference seems tolerable.
Would someone be interested in contributing the change to Ruff? It requires porting the configuration from ripgrep to ruff and doing a quick analysis of the file size change between the two versions (release mode).
Can I take this one?
Can I take this one?
@T-256 definitely okay with me.
Go for it!