-
Notifications
You must be signed in to change notification settings - Fork 19
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
Proposition to lower FSharp.Core requirements #89
Comments
Sure no problem at all. Can I ask what prompted this issue for you? |
I was working on Fable.Form implementation for Sutil and when adding it to repository I had an issue because my requested FSharp.Core version is lower than the one from Sutil. All libraries from Fable.Form are using FSharp.Core 5.0.2, so it forced I can of course make that specific library depends on that version, but because |
Ok. I didn't know you used Sutil. Yes, I will make this change. I never really know what to do about those dependencies. Sometimes I feel like I'm juggling to make it all work. |
I am starting to experiment with it, especially now that Fable.Form rewrite allows it to target any renderer. A version of FuncUI (desktop app), is planned too 🚀 |
Regarding the dependency in this case you probably just need to set Version 5 should be enough because it gives you access to string interpolation if you use that. FSharp.Core 6+ introduces |
Adding that reference now gives this warning
There are definitely no other references to FSharp.Core elsewhere. I'm not sure what it means about "use Update" Also, I get these build failures now:
I think I can rebuild Feliz.Engine.Bulma, but I don't know about Fable.ShadowStyles. |
Ah yes sorry in you case you need to use This is because by default F# add a And you can't |
Can you show me how to use Update to avoid that warning/error please? |
The additional errors in that log above are about Fable.ShadowStyles and Feliz.Engine.Bulma, which is why I talked about reuilding them (with FSharp.Core dependencies that follow your guidelines above). |
Ahhhhh, sorry I didn't read the error messages thinking I knew what it was 🤦♂️ And that's why I moved the discussion regarding Feliz.Engine & co to the other issue.
You need to replace <PackageReference Update="FSharp.Core" Version="8.0.101" /> But if you have others dependencies using |
If I followed everything as I think I did there's a newer version of the shadow styles package with the lowered down requirements for FSharp.Core Feel free to let me know if that works! @MangelMaxime regarding the maintenance of that package, there's not a lot to do there it isn't really a used package so sporadic items like these are fine for me to update if there was more demand I'd consider more maintainers. |
Thank a lot @AngelMunoz 👍 |
@MangelMaxime
Do you mean to say 5.0.2 there? |
@davedawkins Yes, indeed If you are in doubt, you can run |
This has worked!! I'll build a new Sutil in just a moment The only thing bothering me right now is build.fsx, it also has dependencies:
|
Perhaps, you can reference FSharp.Core in the fsi directly via Or don't use Fake, personally I don't like using it because it often caused issues to my projects. Now days, there is Fun.Build which provides a good DSL for people who like Or personally, my favorite way of doing it now days, it to create real project and create a CLI tool. This way, I get a good DX + I can do anything I want because this is a real F# project so I can do complex manipulation. You can look at the following file to get a feeling of how it looks. If you want to go with the CLI/project approach I can look to send a PR for Sutil. |
That's amazing. I love it :-) |
Ok, I will send a PR later this week then :) |
I've done it :-) Sorry -- I didn't see that you'd offered to do a PR! I hope you haven't started it. I'll commit and push now |
Sutil now ships with FSharp.Core 5.0.2 in v2.0.16. |
Hello,
When authoring F# libraries, it is recommended to make FSharp.Core dependency as low as possible. It allows a library to reach a larger range of codebase.
Otherwise people will get warning like:
Would it be is possible to lower FSharp.Core version to 5.0.2 or 4.7.2 depending on if you need some new feature from FSharp.Core.
You can read more about FSharp.Core management here
In general, I propose 5.0.2 because based on my experience this works fine.
The text was updated successfully, but these errors were encountered: