Skip to content

Conversation

@Jim8y
Copy link

@Jim8y Jim8y commented Dec 26, 2025

Summary

  • copy plugin dependencies to output for per-plugin AssemblyLoadContext loading

Testing

  • not run (not requested)

@github-actions github-actions bot added the N4 label Dec 26, 2025
@cschuchardt88
Copy link
Member

This mess with alot of other things. I do not like this way.

@shargon
Copy link
Member

shargon commented Dec 29, 2025

I understand that this is not required after neo-project/neo#4397, isn't it?

@ajara87
Copy link
Member

ajara87 commented Dec 29, 2025

I understand that this is not required after neo-project/neo#4397, isn't it?

I think it's different. In this case when CopyLocalLockFileAssemblies is set up to true then NuGet package dependencies are copied to the output directory

@shargon
Copy link
Member

shargon commented Dec 29, 2025

I understand that this is not required after neo-project/neo#4397, isn't it?

I think it's different. In this case when CopyLocalLockFileAssemblies is set up to true then NuGet package dependencies are copied to the output directory

But plugins are not mandatory, how can it helps?

@erikzhang
Copy link
Member

But plugins are not mandatory, how can it helps?

If one plugin references another plugin, we need to copy the dependencies of the referenced plugin to the local directory. I think this is necessary.

erikzhang
erikzhang previously approved these changes Jan 7, 2026
@cschuchardt88
Copy link
Member

This isn't the right the way to do this. neo-project/neo#4181 is the correct the way to do it. Ill be adding this PR to this repo, when i get some time.

@erikzhang
Copy link
Member

This isn't the right the way to do this.

Could you explain in more detail?

@cschuchardt88
Copy link
Member

This isn't the right the way to do this.

Could you explain in more detail?

CopyLocalLockFileAssemblies is only for transitive NuGet package dependencies. This will include other dependencies like neo.dll, akka.dll and etc from neo repo with all the other libraries from that repo. Which will add extra dll that are un-needed.

The proper way to add these dependencies is to add an attribute called PrivateAssets="all" to the PackageReference. Which will not include them when you add reference to the plugin or to neo repo libraries.

@erikzhang
Copy link
Member

CopyLocalLockFileAssemblies is only for transitive NuGet package dependencies. This will include other dependencies like neo.dll, akka.dll and etc from neo repo with all the other libraries from that repo. Which will add extra dll that are un-needed.

I got it.

The proper way to add these dependencies is to add an attribute called PrivateAssets="all" to the PackageReference. Which will not include them when you add reference to the plugin or to neo repo libraries.

However, this would require too many changes to the Neo project. I think there should be a way to reference Neo in a plugin project without copying Neo's dependencies to the local directory.

@cschuchardt88
Copy link
Member

cschuchardt88 commented Jan 7, 2026

However, this would require too many changes to the Neo project. I think there should be a way to reference Neo in a plugin project without copying Neo's dependencies to the local directory.

<ProjectReference Include="Neo" PrivateAssets="runtime" /> - This will only add neo.dll and not all the other dll libraries like

image

Also we can put this in Directory.Build.props file

Like this https://github.com/cschuchardt88/neo/blob/a5bf67b181966e7d2d9205c28d95761ec5ec4fa0/src/Plugins/Directory.Build.props

@erikzhang
Copy link
Member

- This will only add neo.dll and not all the other dll libraries like

Then we only need to modify the Directory.Build.props file in the plugin directory.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants