-
-
Notifications
You must be signed in to change notification settings - Fork 14.2k
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
wrangler: init at 3.62.0 #322573
wrangler: init at 3.62.0 #322573
Conversation
@SuperSandro2000 @lelgenio @a-kenji @friedow can you please review |
this makes wrangler build as far as nix is concerned but the binary itself still has some issues
Eventually this probably should be resolved too if it happens on other machines, but I'm not entirely sure the reasons/solution for that issue. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You could also update the hash for the other systems:
Using nix-hash to-sri --type sha512 "$(nix-prefetch-url --type sha512 <URL>)"
, I get:
System | Hash |
---|---|
linux-64 | sha512-2zDcadR7+Gs9SjcMXmwsMji2Xs+yASGNA2cEHDuFc4NMUup+eL1mkzxc/QzvFjyBck98e92rBjMZt2dVscpGKg== |
linux-arm64 | sha512-7y41rPi5xmIYJN8CY+t3RHnjLL0xx/WYmaTd/j552k1qSr02eTE2o/TGyWZmGUC+lWnwdPQJla0mXbvdqgRdQg== |
darwin-64 | sha512-YanZ1iXgMGaUWlleB5cswSE6qbzyjQ8O7ENWZcPAcZZ6BfuL7q3CWi0t9iM1cv2qx92rRztsRTyjcfq099++XQ== |
darwin-arm64 | sha512-bRe/y/LKjIgp3L2EHjc+CvoCzfHhf4aFTtOBkv2zW+VToNJ4KlXridndf7LvR9urfsFRRo9r4TXCssuKaU+ypQ== |
I didn't know you could do that. I'll update |
It seems that workerd is important to you. Please move it out of nodePackages to prevent such regressions in the future. see #229475 |
issues with pnpm monorepo, looking at suggestions from #316908 which may have a path forward |
I was looking at this a week or two ago - this is what I've come up with - this resulted in a successful
|
I did a little more on this and this variant seems to somehow work (in the sense that it is possible to print version, login and list dbs) but it feels very brittle and I really don't have much understanding of any model assumed by Might be useful/helpful in any case...
|
getting closer, now i'm looking at this when i run the derivation as part of a larger nixos deploy
i'm guessing i pull in typescript as part of the build or something, but i'm not sure if that's a good solution. there are probably other npm deps after typescript. i'm definitely way out past my ski's here, but i'll try hacking a bit at this on my laptop for a while. |
@seanrmurphy it still builds when i removed autopatch altogether and that seems to have worked.. but should i have just removed the preBuild step? what do you think? guessing one of those subcommands might fail if we don't have the autopatch |
The autopatch is necessary to run It can be built without the autopatch, because the 'build' is mostly just copying and downloading files afaict. I believe functionalities that involve querying the API should prob be fine without the autopatching but anything which is dependent on the binaries could fail. I think the |
@seanrmurphy ill add back autopatch, makes sense to me |
Co-authored-by: Sean Murphy <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks almost perfect! Well done :).
c91a862
to
18338bc
Compare
987add4
to
3554346
Compare
Also please don't push so frequently - you are exhausting CI. Push only after you have tested it builds locally and after you have gone through all the unresolved review comments at least twice and made sure they are all addressed. |
48bf9a2
to
8cbda5f
Compare
@dezren39 you are not behaving as I asked you. Not only that, you are marking conversations as resolved without really resolving them. I won't be helping you to get this in if you won't behave. |
Co-authored-by: Sean Murphy <[email protected]>
Looks awesome 👏! Hopes this can be shipped soon 👌👌 |
Result of 1 package built:
|
Description of changes
updates wrangler to be standalone package.
previously it was available but only as part of the nodePackages set.
initially i had just updated hashes because wrangler build broke.
wrangler build had other issues even after hash update,
and it was also suggested that it's preferred to use the new way to handle npm builds.
wrangler is published to npm without a package-lock,
it uses a pnpm build with workspaces as part of the cloudflare/workers-sdk monorepo.
some dependencies of wrangler are part of the monorepo and are unavailable on npm.
the pnpm helper functions such as
pnpm.fetchDeps
do not support monorepos directly.this deployment works around that by copying a large part of the pnpm cache (hard links in node_modules into the cache) directly into the workflow.
because pnpm dependency resolution can sometimes pull dev dependencies and other utilities,
a few dev dependencies that are also binaries are removed in the build script.
typescript
eslint
prettier
there may be other dependencies which could conflict other nixos builds.
fixes #322571
may relate to #319134
Things done
i confirmed this builds on my nixos framework 13 intel 11 gen,
as opposed to before when build threw.
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.