Comments (8)
My guess would be that CI runs against the local SDK (path reference) rather than the remote SDK (git reference), I believe that Windows + Git + symlinks is a whole exciting world of hurt that Windows + symlinks alone is not. (Cf. the lengthy, nuanced. and occasionally terrifying answers on this SO post (although the post itself is not directly relevant to this situation).)
(Which is presumably why crates.io
is fine - I'm guessing in that case the symlink is followed at publish time, so that when Windows downloads from crates.io
the files are packaged in the right place.)
from spin.
Worst-case scenario here if we can't address the above would be to just (yet-again) create another copy of the wits into sdk/rust..... cc/ @vdice if you have any thoughts.
I don't have any brighter ideas than this for unblocking Windows users when using the "main"
git ref.
from spin.
Note: with the forthcoming 2.2.0 release and thereafter, the Rust templates will use crate references rather than git (ref #2221). This should fix the issue for Windows users.
from spin.
I was able to reproduce by following the steps given (thank you!), and I was also able to reproduce the errors by building Spin directly on Windows with make build
Changing path: "./wit"
to path: "../../wit"
on this line referenced by the build error allowed my local build to succeed. I did not verify whether this change builds on Unix systems though. I do not have context on the wit file currently used as an intermediate - let me know if there is a reason that is needed! Otherwise, I am happy to publish a PR for this change tomorrow after the 9-5! Edit: Looks like this symlink was added to resolve an issue with cargo publish
- #2151 (comment). One route could be to update templates to reference the published SDK crate rather than Spin repository artifacts.
I see that Windows is added to the build CI here - feels like this should already be caught in the CI step
from spin.
Adding this to the 2.2 milestone as a reminder to wrangle the scripts so the released templates reference crates.io
instead of GH (which appears to fix this).
Although it would still be good to also fix on main, so that Windows folks could use canary templates. @fibonacci1729 are you the knowledgeable person for the Rust SDK WIT stuff?
from spin.
@itowlson Happy to help with any Rust SDK WIT stuff but from reading the above, it seems like the symlink created to link ./wit
-> ../../wit
isn't working on Windows as expected. As @ogghead mentions, i am befuddled by this not being caught in CI when building for windows.
Worst-case scenario here if we can't address the above would be to just (yet-again) create another copy of the wits into sdk/rust
..... cc/ @vdice if you have any thoughts.
from spin.
I've marked the 2.2 work involved as Done, but I'm leaving this open until 2.2 ships so that 2.1 users can find it!
from spin.
Spin v2.2.0 is out and the corresponding Rust templates now pull in the spin-sdk via the "2.2.0" crate reference. (Note: you'll need to run spin templates upgrade
after upgrading to Spin v2.2 to pull down the latest templates.) Closing for now but please let us know if other issues arise.
from spin.
Related Issues (20)
- Move to badgen badge for discord in README
- Referencing files outside of app root produces bad error messages HOT 3
- Deprecate execution of "uncomponentizable" WAGI modules
- Signing the spin executable breaks it HOT 9
- Terminating the app while a prompt is waiting will not restore terminal settings HOT 4
- `spin build`: detect if invoking Spin, and if so use current Spin binary HOT 2
- Support graph-DBs HOT 4
- Support overriding the "Spin data dir" via env var
- Record OTel metrics in host components
- OTel features overwhelmed during high load HOT 5
- Build failed (aedc2b8ccc65f41615fa7beb3e427843dd782114) HOT 3
- Spin 2.6 release HOT 11
- Spin apps are no longer allowed to set host headers with Wasmtime 21.0.1 HOT 6
- Enable mustache-inspired string templates for `key_value_stores` and others HOT 5
- Add version control support to `spin new` or spin CLI HOT 12
- Rust and Python traces with KV store are not showing all KV spans in the same trace
- Remove HTTP trigger `base` option
- Consider deprioritizing the environment variable provider HOT 6
- Add `spin up --trigger-type` flag
- Enable pushing components with `spin registry push`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from spin.