-
Notifications
You must be signed in to change notification settings - Fork 89
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
Glue packages with working Pkg compat versioning #280
Comments
Is it decided that this won't just go in SpecialFunctions.jl itself (JuliaMath/SpecialFunctions.jl#238)? |
A more wild idea for making it an optional dependency. I think we can accomplish this via making a release of ChainRules_SpecialFunctions_Glue.jl
does this work? cc @StefanKarpinski |
I am going to keep this open. while we now have moved out SpecialFunctions and have just plain deleted NaNMath, the root desire still remains. |
This is the outcome of a discussion I had with @KristofferC about how to make glue packages work.
We should put it into practice for SpecialFunctions.jl and NaNMath.jl
We make a new package called:
ChainRules_SpecialFunctions_Glue.jl
which has the released with compat on SpecialFunctions.jl declared
then in ChainRules.jl we would declare a dependency NOT on SpecialFunctions
but on ChainRules_SpecialFunctions_Glue.jl
and then in the source code of ChainRules.jl would do:
So ChainRules.jl never has a direct dependency on SpecialFunctions.jl
only on ChainRules_SpecialFunctions_Glue.jl.
But ChainRules.jl does use Require to conditionally load ChainRules_SpecialFunctions_Glue.jl in response to SpecialFunction.jl being loaded.
and ChainRules_SpecialFunctions_Glue.jl does have a direct dependency on SpecialFunctions.jl (and on ChainRulesCore.jl), and it declares constraints on it
so the pakcage manager can workout which should be loaded.
In pacticular, ChainRules_SpecialFunctions_Glue.jl would not support both SpecialFunctions.jl v0.7 and v0.8 at the same time.
Rather ChainRules_SpecialFunctions_Glue.jl v1.0.0 would support SpecialFunctions.jl v0.7
and ChainRules_SpecialFunctions_Glue.jl v1.1.0 would support SpecialFunctions.jl v0.8
And ChainRules.jl would support ChainRules_SpecialFunctions_Glue.jl
1.x.y
TL; DR:
you use Requires on the Other package, to load the Glue
and you put the Glue package in your dependencies
The text was updated successfully, but these errors were encountered: