-
Notifications
You must be signed in to change notification settings - Fork 2
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
SemVerPS 1.1 on Windows PowerShell ends with Unable to find type [Semver.SemVersion] #8
Comments
Also wonder if compile into .NET Standard 2.0 (so .NET Framework 4.7.2+ and .NET (Core) 3.1) would not be an answer to the JIT *.CS file. Furthermore also noticed you changed you license from MIT to GPLv3... |
Hi @Sarafian ... It could still be that I'm doing something wrong, but it is somewhat funny that |
Hi Dave, I think I had done a quick check for Windows poweshell. To my knowledge and confirmed with the pester tests the functionality didn't change, so you can use the previous version. When I return, I'll take a look. The manifest files need to be more correct. |
Sorry for the late response but you are indeed right. The way the module works is that it uses the I remember well and understand your dependency with Windows PowerShell and I would like the module to maintain backwards compatibility. But the module is actully a cmdlet wrapper around the functionality from @maxhauser's repo and as his code evolves towards core/standard so does the module move towards the core of powershell. So, I'm looking into how this could be possible. I'm considering checking the powershell version and depending on the version add the directive or not. This would probably work. The problem I have is how does the AppVeyor CI make sure it works for Windows Powershell as well. I couldn't find much and therefore there is a new question on stackoverflow. Since you work with the Windows PowerShell maybe you have some insight to share. In any case, I don't expect a fast response. |
Thanks for looking into this @Sarafian! Technically it is already broken in v1.1 but y slightly increasing your platform support to .NET 4.7.2, you get access to NET Standard. So in turn you can offer a compiled version of the Semver.cs ... that is a way out. |
I don't want to do the compiled version. For this I never embedded the nuget package or the dll.
That's where I broke it. 1.0 should be still good for your windows setup. |
@ddemeyer the new c# code won't work with or without the precompile directives. Unfortunately, following up on Max's code and keeping it simple (no compile) make the 1.1 version non-desktop version compatible. The only way to bring powershell desktop support is to load c# version code from when it worked but then the module updates are going to be gimic. Unless you have a better suggestion, I'll create a new version with the manifest declaring the That would mean that you need to update your dependency to |
So summarized, are you thinking along these lines...
Thanks for looking into this :-) |
Can't replace existing versions. Only unlist them. I don't see how in a simple way it works for both editions. When you import a .net type it is not the same as a compiler and pre-compile directives are not defined or considered etc. I tried to fiddle with the code for the desktop edition and didn't import. Since this depends on a 3rt party's code, I don't want to have to troubleshoot it now or the future. Makes sense as the code projects are moving towards .net as well. Functionally they are the same. Only the supported edition changes. |
Closing with
|
Below is Windows PowerShell 5.1 on a recent Windows 10 having .NET Framework 4.8 installed. SemVerPS
1.0
works.Below is a restarted Windows PowerShell 5.1 session on a recent Windows 10 having .NET Framework 4.8 installed. A new PowerShell process to avoid a lingering SemVer class/type loaded. SemVerPS
1.1
throws various errorsFor what it is worth, same machine the later code block works without problems on a PowerShell 7.1.4. But I think you remember why we need Windows PowerShell :-)
If you don't have time to look into it, can you share some highlights/problems on what changed between 1.0 and 1.1?
Thanks
The text was updated successfully, but these errors were encountered: