[Mono-bugs] [Bug 75116][Maj] New - System.Environment.Version returns a fake .NET Framework based version number instead of the real Mono runtime version number

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Thu Jun 2 03:05:15 EDT 2005


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by kornelpal at hotmail.com.

http://bugzilla.ximian.com/show_bug.cgi?id=75116

--- shadow/75116	2005-06-02 03:05:15.000000000 -0400
+++ shadow/75116.tmp.6723	2005-06-02 03:05:15.000000000 -0400
@@ -0,0 +1,67 @@
+Bug#: 75116
+Product: Mono: Class Libraries
+Version: unspecified
+OS: All
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Major
+Component: CORLIB
+AssignedTo: mono-bugs at ximian.com                            
+ReportedBy: kornelpal at hotmail.com               
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: System.Environment.Version returns a fake .NET Framework based version number instead of the real Mono runtime version number
+
+Environment.Version is documented in the .NET Framework SDK Documentation 
+as the following:
+"Gets a Version object that describes the major, minor, build, and 
+revision numbers of the common language runtime."
+
+This means that it should return the real version number of the runtime.
+
+.NET Framework returns the version of it's own runtime.
+Portable.NET returns it's own version as well.
+
+Mono returns version numbers taken from .NET Framework version 1.0 RTM, 
+1.1 RTM, 2.0 Beta 2.
+
+The only way to obtain the version number of the runtime is to 
+execute "mono --version". There is no way to get it programmatically 
+either using umanaged or managed code.
+
+There is no use to return fake version numbers to provide .NET Framework 
+compatibility as it cannot be provided.
+
+If someone uses this number to determine the feature set of the runtime 
+or class library he will only be able to rely on the features of .NET 
+Framework as Mono has a different feature set.
+
+This propery is useful to display or log the version number of the 
+runtime.
+
+Altough it is not recommented if someone wants to use this version number 
+to determine the feature set of the runtime instead try to use the 
+features it's better if he can use the real version number.
+
+System.Runtime.InteropServices.RuntimeEnvironment.GetSystemVersion() uses 
+this number but it shouldn't be changed as the version returned by 
+GetSystemVersion has no meaning on Mono it is for the umnanaged API of 
+mscoree.dll.
+
+This property is used by remoting in:
+System.Runtime.Remoting.Channels.Http.HttpClientChannel
+System.Runtime.Remoting.Channels.Http.HttpServer
+System.Runtime.Remoting.Channels.Http.HttpServerChannel
+And by web services:
+System.Web.Services.Protocols.HttpWebClientProtocol
+And by some utilities to display version number.
+
+It should be evaluated whether the version number of .NET Framework is 
+required it the above situations.
+
+But generally I think this propery should return the version of Mono 
+runtime.


More information about the mono-bugs mailing list