-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[Bug?]: supported architectures behaviour doesn't support zero installs #4615
Comments
Do you know if SWC supplies prebuilt binaries for each platform? For instance, ESBuild does that, running install locally, gives me all the binaries (arm, x64, darwin, linux) etc. Unless the package supplies prebuilt binaries or cross-build install script, there really isn't much you can do. |
So when using my local (Mac) env it installs the darwin specific prebuilt
binary (which is at least better than all binaries) to the unplugged folder.
Ideally when using supportedArchitectures it would grab all binaries that
meet my specified platforms?
…On Sat., Jul. 9, 2022, 10:24 Seivan, ***@***.***> wrote:
Do you know if SWC supplies prebuilt binaries for each platform?
For instance, ESBuild does that, running install locally, gives me all the
binaries (arm, x64, darwin, linux) etc.
They are part of the repo.
Unless the package supplies prebuilt binaries or cross-build install
script, there really isn't much you can do.
—
Reply to this email directly, view it on GitHub
<#4615 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ACJVU776YC723DQSOFAH3NDVTGYTBANCNFSM53BXCICQ>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
https://swc.rs/docs/getting-started#supported-binaries
On Sat., Jul. 9, 2022, 10:34 Layton Gilbraith, ***@***.***>
wrote:
… So when using my local (Mac) env it installs the darwin specific prebuilt
binary (which is at least better than all binaries) to the unplugged folder.
Ideally when using supportedArchitectures it would grab all binaries that
meet my specified platforms?
On Sat., Jul. 9, 2022, 10:24 Seivan, ***@***.***> wrote:
> Do you know if SWC supplies prebuilt binaries for each platform?
>
> For instance, ESBuild does that, running install locally, gives me all
> the binaries (arm, x64, darwin, linux) etc.
> They are part of the repo.
>
> Unless the package supplies prebuilt binaries or cross-build install
> script, there really isn't much you can do.
>
> —
> Reply to this email directly, view it on GitHub
> <#4615 (comment)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/ACJVU776YC723DQSOFAH3NDVTGYTBANCNFSM53BXCICQ>
> .
> You are receiving this because you authored the thread.Message ID:
> ***@***.***>
>
|
@laytong That's what ESBuild does for me. It's part of it's post-install script (I am guessing). |
I guess this is actually an issue with SWC rather than yarn? |
Yep, there is stuff Yarn could do to make i easier, but yeah. Sorry. |
Ok seems it does work, But they need all supportedArchitectures critieria needed to specify both cpu and libc sub options for @swc-core-linux-x64-gnu-npm to be installed |
Can you point me to some guidance on when/why a package needs to be unplugged i.e. in this instance could the package be modified in some way that it can link to these built binaries without needing to be unplugged? |
As far as I understand it, something is unplugged if it has characteristics of not being something that can be shared. Now for instance, CoreJS is unplugged, and it's unplugged because it has a post-install script, that you can disable in |
Even with Example working config: supportedArchitectures:
os:
- current
- darwin
- linux
cpu:
- current
- x64
- arm64
libc:
- current
- glibc
- musl |
@laytong this is still broken on yarn@4 Downgrading to 3.7.0 helps atm. |
Thanks for the update. I've moved away from using zero installs mostly due to issues like this, so I no longer check in my yarn cache |
The whole thing is flaky as hell. I am getting install issues on the Github CI ubuntu runners depending on how many zip files were cached. It's completely unpredictable. |
is it possible to restrict supported archs only to given combination of os and cpu? like: |
I don't think it is, but that would be very helpful |
This is the expected behavior. Some packages specify the OS, CPU and/or the C library needed for the package to work (e.g. Say if you are installing If you only specify
then In order for
Have you tried
|
Self-service
Describe the bug
I have a repo using zero installs approach that requires one unplugged package (@swc-core)
its unplugged as it appears to require platform specific binaries. My CI environment is a linux env, whereas local is mac
I added the specific platforms to the
supportedArchitectures
field in my .yarnrc.ymlI had hoped/expected that with zero-installs the platform specific binaries would have been installed/added to the repo on local install so that when i run my ci i do not need to do a yarn install step (in keeping with the zero installs approach)
This may be the intended behaviour, but then how do I maintain zero installs in this case?
To reproduce
I don't believe this can be reproduced in sherlock due to the cross platform nature of the issue
Environment
System: OS: macOS 11.6.5 CPU: (12) x64 Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz Binaries: Node: 16.15.1 - /private/var/folders/bl/q3538n111qsck6ll41877f440000gp/T/xfs-d4f8e23c/node Yarn: 3.2.1 - /private/var/folders/bl/q3538n111qsck6ll41877f440000gp/T/xfs-d4f8e23c/yarn npm: 8.11.0 - ~/.nvm/versions/node/v16.15.1/bin/npm
Additional context
Here's the ci error if i do not include yarn install step
Yarnrc file
The text was updated successfully, but these errors were encountered: