🌐 AI搜索 & 代理 主页
Skip to content

problem loading transitive assembly dependencies from PYTHONPATH #48

@adamklein

Description

@adamklein

Transitive assembly dependencies do not seem to be found in the augmented search path… this became a problem with commit b65fa30, Use Assembly.Load(Byte[]) instead of Assembly.LoadFrom.

Prior to this commit, calling clr.AddReference("X") in python for an assembly X in the PYTHONPATH did not result in invocation of ResolveHandler for its dependencies that lived in the same directory as X.

After this commit, ResolveHandler is invoked and passes to LoadAssemblyPath the args.Name that looks like this (say Y is a dependency of X):

"Y, Version=a.b.c.d, Culture=neutral, PublicKeyToken=null"

So, FindAssembly fails because its temp = path + ".dll' looks like

"C:\\pathtoassembly\\Y, Version=a.b.c.d, Culture=neutral, PublicKeyToken=null.dll"

Any advice on how to fix would be appreciated.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions