-
Notifications
You must be signed in to change notification settings - Fork 525
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
paket pack ignores specific-version parameter when inserting dependencies making created packages unusable #1321
Comments
/cc @eiriktsarpalis
|
Hi, are templates you are creating of type project or file? I can't reproduce this error in my projects (which are of the former) |
Hmm... Is your code available on github? Or could your provide a minimal repro? |
The code is available, but anything but minimal :) In the root folder you will find repro-paketpack-bug.ps1 Thanks for the quick response! |
I think, and @forki correct me if I'm wrong in this, that inter-project dependencies need to be specified explicitly in your |
If I don't use specific-version everything works correctly. The documentation has this to say: https://fsprojects.github.io/Paket/template-files.html
Note the last part:
|
I was not aware of this functionality. It might possibly be a later addition. It's clear that the specific-version implementation does not take this functionality into consideration. |
Not easy to take something into account if you did not know it existed :) I'll take this opportunity to give everyone involved with paket a big high five. Everything seems so well thought out. Including specific-version. So far, whenever I think "I would like it to work like this" I just look in the docs and what I want is already there :) After years of tearing my hair out in frustration with NuGet paket is here to save the day. |
Try adding an the I think we need to infer the |
@inosik That did indeed make it work correctly. I newer would have guessed that would be a workaround! That will let me abandon my current workaround until we get a real fix. Thank you :) @eiriktsarpalis Is that a real fix I spy there? |
@mlidbom yeah, it fixes the issue at least in my reproduction of it. |
@eiriktsarpalis thanks for taking care of this |
Hmm, I'm afraid that I still have the problem with 2.38.0. |
Did you try following @inosik's suggestion? |
Yes. My development branch uses the workaround of specifying id manually, so there is no great hurry to fix this on my behalf :) But it is still broken unless you manually specify id. Unless I'm missing something. |
Eventually having this working will be kind of important to me though. The simpler and the more standardized we can keep the template files the better. I would really like it if we can keep them all to a single identical line: |
I'm not sure why this happens. @forki at what stage does the inference of project id occur? |
It seems to occur when there is no I got a repro case here: repro.zip.txt. A and C depend on B.
Note that the |
@inosik I tried to run your example, but don't understand the issue yet. |
The difference is in the unpacked <dependencies>
<dependency id="B" version="4.5.6.0" />
</dependencies> while the file after step nr. 2 and 3 contains <dependencies>
<dependency id="B" version="4.5.6" />
</dependencies> The version of the dependency doesn't come from the After steps nr. 2 and 3 |
Sorry, what I meant was, the version should be 4.5.6 in both cases. |
should be fixed now |
I just tried this again on my repro branch and I can confirm that it seems to be working perfectly now. |
Awesome. |
Say I have a solution with 3 packages that are packed using specific-version for each package.
A (AssemblyVersion: 3.3.0.0, specific-version: 3.3.0-beta01)
B (AssemblyVersion: 3.1.0.0, specific-version: 3.1.0-beta01, DependsOn: A)
C (AssemblyVersion: 3.5.0.0, specific-version: 3.5.0-beta01, DependsOn: A)
In the created packages the dependency on A in B and C are wrong. They both specify the version: 3.3.0.0 for A instead of the correct 3.3.0-beta01
The text was updated successfully, but these errors were encountered: