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

Paket removes System.ComponentModel.Composition reference #376

Closed
JonCanning opened this issue Nov 20, 2014 · 9 comments
Closed

Paket removes System.ComponentModel.Composition reference #376

JonCanning opened this issue Nov 20, 2014 · 9 comments

Comments

@JonCanning
Copy link
Contributor

I'm using Paket to install RavenDB.Client, and a call to:

Raven.Client.Indexes.IndexCreation.CreateIndexes

in my code requires that System.ComponentModel.Composition is manually referenced. However, whenever I run paket update the reference is removed

Create an empty library and replace the class that's created with this

type Class1() = 
  member this.X = Raven.Client.Indexes.IndexCreation.CreateIndexes(System.Reflection.Assembly.GetExecutingAssembly(), null)

and reference System.ComponentModel.Composition

You may have to paket update a couple of times to see the problem

@forki
Copy link
Member

forki commented Nov 20, 2014

Ok this is a new fucked up situation. RavenDB.Client nuspec says

<frameworkAssemblies>
  <frameworkAssembly assemblyName="System.ComponentModel.Composition" targetFramework=".NETFramework4.0" />
</frameworkAssemblies>

So we think it's only for net4.

we need a way to.keep these

@forki
Copy link
Member

forki commented Nov 20, 2014

we could introduce a Paket-keep flag, but this would mean manually editing of csproj file

@forki
Copy link
Member

forki commented Nov 21, 2014

we could also add a syntax to the references file. Like

frameworkAssembly System.ComponentModel.Composition

@JonCanning
Copy link
Contributor Author

Why does paket remove the references?

@forki
Copy link
Member

forki commented Nov 21, 2014

The original idea is to remove duplicates.
The nuspec in question requires the assembly framework reference. So we add
it. Then you have two references. Which is also a bug.

But your question hints to a better strategy. Maybe we should not
remove/replace existing references. Instead we could just update our model.

This may actually work and solve another problem. Sometimes the easy
solutions are hard to see.
On Nov 21, 2014 3:39 PM, "Jon Canning" [email protected] wrote:

Why does paket remove the references?


Reply to this email directly or view it on GitHub
#376 (comment).

@forki
Copy link
Member

forki commented Nov 22, 2014

My local version seems to handle this case now. Will need to make it more robust.

@forki forki closed this as completed in 12b2bac Nov 22, 2014
@forki
Copy link
Member

forki commented Nov 22, 2014

It would be cool if you could test 0.16 alpha version if it works for you.

@JonCanning
Copy link
Contributor Author

Looks good!

forki added a commit that referenced this issue Nov 22, 2014
@JonCanning
Copy link
Contributor Author

Just paket'd (and FAKE'd!) another more complicated project that was losing numerous references. All good now.

isaacabraham pushed a commit to isaacabraham/Paket that referenced this issue Nov 23, 2014
isaacabraham pushed a commit to isaacabraham/Paket that referenced this issue Nov 23, 2014
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

2 participants