[Bug 56434] New: Error calling COM object WScript.Network to get username, hostname and domainame
https://bugs.winehq.org/show_bug.cgi?id=56434 Bug ID: 56434 Summary: Error calling COM object WScript.Network to get username, hostname and domainame Product: Wine Version: 9.0 Hardware: x86 OS: Linux Status: UNCONFIRMED Severity: blocker Priority: P2 Component: wshom.ocx Assignee: wine-bugs(a)winehq.org Reporter: rbenrax(a)gmail.com Distribution: --- Python pywin32 example to reproduce: import win32com.client def main(): network = win32com.client.Dispatch("WScript.Network") print(network) username = network.UserName hostname = network.ComputerName domain = network.UserDomain print(username) print(hostname) print(domain) if __name__ == "__main__": main() -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56434 --- Comment #1 from Rafa <rbenrax(a)gmail.com> --- Log: 0114:fixme:wshom:WshNetworkFactory_CreateInstance (00000000 {00020400-0000-0000-c000-000000000046} 0040F7FC) 0114:fixme:wshom:WshNetwork2_GetTypeInfo 773FC018, 0, 400, 0040F990. 0114:fixme:wshom:WshNetwork2_GetTypeInfo 773FC018, 0, 400, 0040F860. <COMObject WScript.Network> 0114:fixme:wshom:WshNetwork2_get_ComputerName 0040F880 stub Traceback (most recent call last): File "wscript_network.py", line 15, in <module> main() File "wscript_network.py", line 7, in main hostname = network.ComputerName File "C:\Python27\lib\site-packages\win32com\client\dynamic.py", line 516, in __getattr__ ret = self._oleobj_.Invoke(retEntry.dispid,0,invoke_type,1) pywintypes.com_error: (-2147352567, 'DISP_E_EXCEPTION', (0, None, None, None, 0, -2147467263), None) -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56434 Vijay Kamuju <infyquest(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |infyquest(a)gmail.com --- Comment #2 from Vijay Kamuju <infyquest(a)gmail.com> --- Any real world application that uses it. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56434 Vijay Kamuju <infyquest(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|blocker |normal --- Comment #3 from Vijay Kamuju <infyquest(a)gmail.com> --- And it's not a blocker as it's not affecting a highly used application. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56434 Nikolay Sivov <bunglehead(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever confirmed|0 |1 --- Comment #4 from Nikolay Sivov <bunglehead(a)gmail.com> --- (In reply to Rafa from comment #1)
Log:
0114:fixme:wshom:WshNetworkFactory_CreateInstance (00000000 {00020400-0000-0000-c000-000000000046} 0040F7FC) 0114:fixme:wshom:WshNetwork2_GetTypeInfo 773FC018, 0, 400, 0040F990. 0114:fixme:wshom:WshNetwork2_GetTypeInfo 773FC018, 0, 400, 0040F860. <COMObject WScript.Network> 0114:fixme:wshom:WshNetwork2_get_ComputerName 0040F880 stub Traceback (most recent call last): File "wscript_network.py", line 15, in <module> main() File "wscript_network.py", line 7, in main hostname = network.ComputerName File "C:\Python27\lib\site-packages\win32com\client\dynamic.py", line 516, in __getattr__ ret = self._oleobj_.Invoke(retEntry.dispid,0,invoke_type,1) pywintypes.com_error: (-2147352567, 'DISP_E_EXCEPTION', (0, None, None, None, 0, -2147467263), None)
Thanks. Submitted a fix for get_ComputerName() - https://gitlab.winehq.org/wine/wine/-/merge_requests/5310. Your example will then fail on get_UserDomain(), we'll deal with that next. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56434 --- Comment #5 from Rafa <rbenrax(a)gmail.com> --- Thank you very much for your quick response, in versions of Wine from 5 to 7 it worked correctly, I have not tried it in version 8, but it fails in 9 even from wscript and cscript, we use it from different applications. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56434 --- Comment #6 from Nikolay Sivov <bunglehead(a)gmail.com> --- Second part for the UserDomain property https://gitlab.winehq.org/wine/wine/-/merge_requests/5325. Once it's in, please retest your scripts. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56434 --- Comment #7 from Nikolay Sivov <bunglehead(a)gmail.com> --- UserDomain property is also implemented now, https://source.winehq.org/git/wine.git/commit/9d3e458c55391141971217ec008893.... So this is really needs to be retested. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56434 --- Comment #8 from Rafa <rbenrax(a)gmail.com> --- Compiled winehq from the github repositories. Version wine-9.4-146-g552cc456d18. Example tested correctly from Python(pyein32), wscript, cscript and Powerbuilder. Thank you very much. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56434 Nikolay Sivov <bunglehead(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|NEW |RESOLVED Fixed by SHA1| |9d3e458c55391141971217ec008 | |8931d598236aa --- Comment #9 from Nikolay Sivov <bunglehead(a)gmail.com> --- Thanks, marking fixed. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56434 Nikolay Sivov <bunglehead(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Error calling COM object |WScript.Network does not |WScript.Network to get |implement UserName, |username, hostname and |ComputerName, and |domainame |UserDomain properties -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56434 Alexandre Julliard <julliard(a)winehq.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED --- Comment #10 from Alexandre Julliard <julliard(a)winehq.org> --- Closing bugs fixed in 9.5. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56434 Michael Stefaniuc <mstefani(a)winehq.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Target Milestone|--- |9.0.x -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=56434 Michael Stefaniuc <mstefani(a)winehq.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Target Milestone|9.0.x |--- --- Comment #11 from Michael Stefaniuc <mstefani(a)winehq.org> --- Removing the 9.0.x milestone from bug fixes included in 9.0.1. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
participants (1)
-
WineHQ Bugzilla