Skip to content
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

Not able to use net20 library in net461 project #1779

Closed
simendsjo opened this issue Jul 1, 2016 · 8 comments
Closed

Not able to use net20 library in net461 project #1779

simendsjo opened this issue Jul 1, 2016 · 8 comments

Comments

@simendsjo
Copy link

Description

I'm having a problem after upgrading Paket to 3.4.0. Our project is net461, and we have framework: net461 at the top of our paket.dependencies. However, we use a package which only exists for net20. We used to have the reference to this project in paket.references, but added a reference to the dll manually. The new version of paket breaks this though. It removes our manually added reference, but does not add a reference to the dll, probably as its net20 and not net461. We tried a workaround by removing it from paket.references and adding it manually, but this breaks on our build server as we're using paket.targets which runs restore directly against the paket.references file and, as we removed the reference, won't download the package. Preferable, we would like paket to add this to our project even though a specific version doesn't exist for net461 (which works automatically for libraries >=net40 it seems). Is there a way to force this behavior? Or other workarounds which doesn't involve changing paket.targets or our build server?

Repro steps

Run paket install in repo https://github.com/simendsjo/paket-net20-library-problem

Expected behavior

net20 library is referenced in net461 project

Actual behavior

net20 library is not referenced

Known workarounds

None

Related information

  • Operating system: Windows 10
  • Paket: 3.4.0
  • .NET: 4.6.1
@forki
Copy link
Member

forki commented Jul 1, 2016

Yesterday someone else reported something similar (but closed it again) . But this is such a basic feature, how could we break it and didn't notice in integration tests? This will be first thing after my vacation.

forki added a commit that referenced this issue Jul 1, 2016
@forki
Copy link
Member

forki commented Jul 1, 2016

ok found 5min while packing my stuff for vacation. it seems this case actually never really worked. There is a lot going on (so there is much do to after vacation), but could you please test latest alpha? I think I found the cause and hacked a bit around it.

matthid added a commit to matthid/Paket that referenced this issue Jul 10, 2016
matthid added a commit to matthid/Paket that referenced this issue Jul 10, 2016
@matthid
Copy link
Member

matthid commented Jul 10, 2016

Problem was that EPPlus has a readme.txt file in the lib folder. The penalty for the "empty" lib folder was not high enough...

@forki
Copy link
Member

forki commented Jul 11, 2016

So there is a pr for this?

@matthid
Copy link
Member

matthid commented Jul 11, 2016

Currently it is part of #1785 as I was working on that part of the codebase anyway and it was a good test case. Sorry. I think you could cherry pick the last commit if you want to release this (the fix was the increment of the constant). I try to get the PR to a mergable state next week. Figuring out why the build was red just took way too much time :)

@matthid
Copy link
Member

matthid commented Jul 11, 2016

  • cherry pick the last two commits

forki pushed a commit that referenced this issue Jul 12, 2016
This reverts commit 15256bd.
forki pushed a commit that referenced this issue Jul 12, 2016
# Conflicts:
#	tests/Paket.Tests/InstallModel/Penalty/PenaltySpecs.fs
#	tests/Paket.Tests/InstallModel/ProcessingSpecs.fs
@forki
Copy link
Member

forki commented Jul 12, 2016

done.

@forki forki closed this as completed Jul 12, 2016
@forki
Copy link
Member

forki commented Jul 12, 2016

fixes are in latest alpha. I will create proper release later today

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants