NTypewriter icon indicating copy to clipboard operation
NTypewriter copied to clipboard

NTypeWriter Extension 0.5.9 expecting OriginalDefinition for CustomFunction, but NTypeWriter.CodeModel is only 0.5.8

Open ndollesin-prismhr opened this issue 1 year ago • 7 comments

Using the latest version of the extension (installed via visual studio) is causing a rendering failed issue for custom functions that implement IType:

error CS0535: 'CustomFunction.WrappedType' does not implement interface member 'IType.OriginalDefinition'

However, OriginalDefinition is not available on the current 0.5.8 version of NTypeWriter.CodeModel.

There does not seem to be a way to roll back to NTypeWriter 0.5.8, nor is there a newer version of the CodeModel to update the package to.

ndollesin-prismhr avatar Oct 16 '24 21:10 ndollesin-prismhr

That is interesting, are you using the NT source generator in that project too?

NeVeSpl avatar Oct 17 '24 06:10 NeVeSpl

Yes @NeVeSpl, that is correct

ndollesin-prismhr avatar Oct 17 '24 13:10 ndollesin-prismhr

I have released version 0,5.9.1 of VS add-in, could you check if that helps? If not, the NT source generator will be released soon with matching dlls versions.

The problem is that both VS add-in and source generator are loaded and running in the same VS app domain. dlls are strongly signed so it should work even when different versions of the same assembly are loaded in the app domain...

NeVeSpl avatar Oct 17 '24 13:10 NeVeSpl

Appreciate the speedy updates and insight.

Looks like 0.5.9.1 still throws the same error: error CS0535: 'CustomFunction.WrappedType' does not implement interface member 'IType.OriginalDefinition'

And OriginalDefinition is still unavailable.

ndollesin-prismhr avatar Oct 17 '24 13:10 ndollesin-prismhr

Not sure if this has any bearing on this issue but I did notice that the vsix file for 0.5.8 was 17.7MB and the vsix file for 0.5.9 was only 3.9MB. Was something missing from the new version.

rhilton66 avatar Oct 17 '24 22:10 rhilton66

Not sure if this has any bearing on this issue but I did notice that the vsix file for 0.5.8 was 17.7MB and the vsix file for 0.5.9 was only 3.9MB. Was something missing from the new version.

It was caused by updating Microsoft.VSSDK.BuildTools nuget from 17.7.2196 to 17.11.435. Much fewer files are now included in the vsix file, and it looks like DLLs distributed with VS are no longer included in the vsix file after the update.

NeVeSpl avatar Oct 18 '24 05:10 NeVeSpl

The v0.5.9 nuggets and source generator have been published. They should match the ones used by the latest version of the VS add-in, and solve this problem.

NeVeSpl avatar Oct 19 '24 06:10 NeVeSpl