pywin32-bugs Mailing List for Python for Windows Extensions (Page 57)
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
(24) |
May
(19) |
Jun
(15) |
Jul
(43) |
Aug
(39) |
Sep
(25) |
Oct
(43) |
Nov
(19) |
Dec
(4) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(21) |
Feb
(18) |
Mar
(14) |
Apr
(80) |
May
(56) |
Jun
(24) |
Jul
(30) |
Aug
(17) |
Sep
(36) |
Oct
(106) |
Nov
(38) |
Dec
(30) |
2005 |
Jan
(14) |
Feb
(14) |
Mar
(48) |
Apr
(28) |
May
(49) |
Jun
(23) |
Jul
(9) |
Aug
(13) |
Sep
(28) |
Oct
(21) |
Nov
(8) |
Dec
(26) |
2006 |
Jan
(56) |
Feb
(33) |
Mar
(33) |
Apr
(18) |
May
(16) |
Jun
(9) |
Jul
(24) |
Aug
(16) |
Sep
(14) |
Oct
(37) |
Nov
(38) |
Dec
(22) |
2007 |
Jan
(7) |
Feb
(16) |
Mar
(11) |
Apr
(15) |
May
(15) |
Jun
(8) |
Jul
(24) |
Aug
(26) |
Sep
(18) |
Oct
(11) |
Nov
(20) |
Dec
(1) |
2008 |
Jan
(19) |
Feb
(55) |
Mar
(7) |
Apr
(35) |
May
(66) |
Jun
(38) |
Jul
(26) |
Aug
(5) |
Sep
(25) |
Oct
(25) |
Nov
(18) |
Dec
(18) |
2009 |
Jan
(25) |
Feb
(38) |
Mar
(29) |
Apr
(25) |
May
(5) |
Jun
(11) |
Jul
(16) |
Aug
(16) |
Sep
(16) |
Oct
(1) |
Nov
(15) |
Dec
(33) |
2010 |
Jan
(13) |
Feb
(11) |
Mar
(1) |
Apr
(24) |
May
(26) |
Jun
(19) |
Jul
(22) |
Aug
(51) |
Sep
(38) |
Oct
(39) |
Nov
(25) |
Dec
(27) |
2011 |
Jan
(40) |
Feb
(31) |
Mar
(21) |
Apr
(42) |
May
(11) |
Jun
(16) |
Jul
(20) |
Aug
(14) |
Sep
(6) |
Oct
(8) |
Nov
(34) |
Dec
(7) |
2012 |
Jan
(60) |
Feb
(24) |
Mar
(6) |
Apr
(28) |
May
(41) |
Jun
(15) |
Jul
(14) |
Aug
(25) |
Sep
(30) |
Oct
(18) |
Nov
(30) |
Dec
(9) |
2013 |
Jan
(3) |
Feb
(8) |
Mar
(17) |
Apr
(23) |
May
(34) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2015 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
2017 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
|
Dec
|
From: SourceForge.net <no...@so...> - 2008-04-10 01:38:23
|
Bugs item #950376, was opened at 2004-05-08 06:32 Message generated for change (Comment added) made by rupole You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=950376&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: pythonwin Group: None >Status: Closed >Resolution: Fixed Priority: 5 Private: No Submitted By: bob gailer (ramrom) Assigned to: Nobody/Anonymous (nobody) Summary: Autocomplete popup closes after backspace Initial Comment: Type a name followed by a period. If the autocomplete popup appears, type a letter, then a backspace. The popup closes. It should stay open, so I can try a different initial letter. ---------------------------------------------------------------------- >Comment By: Roger Upole (rupole) Date: 2008-04-09 20:38 Message: Logged In: YES user_id=771074 Originator: NO This no longer occurs, not sure when it was fixed. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=950376&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-10 00:21:33
|
Bugs item #1888859, was opened at 2008-02-07 10:43 Message generated for change (Comment added) made by rupole You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1888859&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: win32 Group: None >Status: Closed >Resolution: Works For Me Priority: 5 Private: No Submitted By: bimal (bimalbiswal123) Assigned to: Roger Upole (rupole) Summary: win32pdh.EnumObjects fails on windows server 2003 R2 Initial Comment: The following code works ok on any windows version except windows server 2003 R2. import win32pdh >>> win32pdh.EnumObjects(None, None, 0, 1) Here is the traceback Traceback (most recent call last): File "<pyshell#1>", line 1, in <module> win32pdh.EnumObjects(None, None, 0, 1) error: (-2147481648, 'EnumObjects for buffer size', 'No error message is available') ---------------------------------------------------------------------- >Comment By: Roger Upole (rupole) Date: 2008-04-09 19:21 Message: Logged In: YES user_id=771074 Originator: NO Closing this since it's due to a difference in platform behaviour. ---------------------------------------------------------------------- Comment By: Roger Upole (rupole) Date: 2008-02-07 18:02 Message: Logged In: YES user_id=771074 Originator: NO This is probably due to permissions. Try it from an elevated process. The next build will also have better support for PDH error messages: error: (-2147481648, 'EnumObjects for buffer size', 'Unable to connect to the specified computer or the computer is offline.') ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1888859&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-10 00:15:02
|
Bugs item #1380832, was opened at 2005-12-14 16:13 Message generated for change (Comment added) made by rupole You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1380832&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: win32 Group: None >Status: Closed >Resolution: Fixed Priority: 5 Private: No Submitted By: Siggi (sigurasg) Assigned to: Nobody/Anonymous (nobody) Summary: win32file.DeviceIoControl can't do OVERLAPPED with output Initial Comment: In the case where win32file.DeviceIoControl is called on an async IOCTL with output, and an OVERLAPPED structure is called, it'll do the wrong thing. In this case win32 function will return FALSE, and ::GetLastError will return ERROR_IO_PENDING. In this case it's the caller's responsibility to keep the output buffer (readData) around until the IO completes or is cancelled, but the code below deallocates it. ok = DeviceIoControl(hDevice, dwIoControlCode, writeData, writeSize, readData, readSize, &numRead, pOverlapped); Py_END_ALLOW_THREADS if (!ok) { free(readData); return PyWin_SetAPIError("DeviceIoControl"); } Also, given the current interface, there's no way to retrieve the output of an overlapped IOCTL. This'd require much the same output convention as win32file.ReadFile. ---------------------------------------------------------------------- >Comment By: Roger Upole (rupole) Date: 2008-04-09 19:15 Message: Logged In: YES user_id=771074 Originator: NO Fixed in win32file.i rev 1.89 ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2005-12-14 17:12 Message: Logged In: YES user_id=14198 That sounds correct. Patches gratefully accepted (or even just something I could add to the test suite!) ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1380832&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-09 10:03:33
|
Patches item #1894593, was opened at 2008-02-16 05:45 Message generated for change (Settings changed) made by mhammond You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551956&aid=1894593&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None >Status: Closed >Resolution: Fixed Priority: 5 Private: No Submitted By: Alexandr Zamaraev (shura_zam) Assigned to: Nobody/Anonymous (nobody) Summary: Convert regex to re in makegwparse.py Initial Comment: In makegwparse.diff 1) Convert old regex to re. 2) Adopt to parse new midl output 3) All interface from parsed file added to AllConverters dict as interface. ---------------------------------------------------------------------- >Comment By: Mark Hammond (mhammond) Date: 2008-04-09 20:03 Message: Logged In: YES user_id=14198 Originator: NO Thanks! Checking in com/win32com/makegw/makegwparse.py; new revision: 1.12; previous revision: 1.11 ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551956&aid=1894593&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-09 09:50:45
|
Bugs item #1472941, was opened at 2006-04-19 22:32 Message generated for change (Settings changed) made by mhammond You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1472941&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None >Status: Closed >Resolution: Works For Me Priority: 5 Private: No Submitted By: Ludvig Strigeus (strigeus) Assigned to: Nobody/Anonymous (nobody) Summary: Build 208 - MAPI COM property doesn't work Initial Comment: I'm trying to change the subject of an email with the MAPI com interface to Outlook: from win32com.client import Dispatch s = Dispatch("Mapi.Session") s.Logon("Outlook") for folder in s.Inbox.Folders: if folder.Name == 'Test': for msg in folder.Messages: print "Changing subject of %s" % msg.Subject msg.Subject = 'Blabla' print "New subject = %s" % msg.Subject msg.Update() But the code does not work. The subject is not changed. It seems like msg.Subject = 'Blabla' has no effect. The same code logic works with Matlab or Visual Basic. ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2006-04-20 09:50 Message: Logged In: YES user_id=14198 I'm afraid I don't have the time right now to look into this, but Python and MAPI have been working together well, by many different people for many years. Nothing jumps out at me from the code though... ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1472941&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-09 09:49:00
|
Bugs item #1707248, was opened at 2007-04-25 19:37 Message generated for change (Comment added) made by mhammond You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1707248&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: win32 Group: None >Status: Closed >Resolution: Wont Fix Priority: 3 Private: No Submitted By: Antoine LECA (antoinel) Assigned to: Nobody/Anonymous (nobody) Summary: unguarded import for win32timezone Initial Comment: PyWin32 build 210. Here comes the traceback: PythonWin 2.2.3 (#42, May 30 2003, 18:12:08) [MSC 32 bit (Intel)] on win32. Portions Copyright 1994-2006 Mark Hammond - see 'Help/About PythonWin' for further copyright information. >>> import win32timezone Traceback (most recent call last): File "<interactive input>", line 1, in ? File "C:\Python22\Lib\site-packages\win32\lib\win32timezone.py", line 78, in ? import os, _winreg, struct, datetime ImportError: No module named datetime >>> A quick search at google did not return useful hints on this particular one. I am quite confident this bug only shows because of my version (which one I use because of dependency reasons); indeed, http://docs.python.org/lib/module-datetime.html says "New in version 2.3." I spotted a possible replacement for datetime.py{d,c} on 2.2 on pythonweb.org, but this site is currently brocken (HTTP Status:403). At any rate, since this module depends from a feature which is not included in Python 2.2, the 2.2 build of pywin32 should not include the win32timezone module. Alternatively, it could detect the import exception and displays some useful message (like "On Python 2.2, bring the datetime module from <http://some/tested/package>.") I am willingful to test here... as soon as I can put my hands on a suitable datetime.py* module! ---------------------------------------------------------------------- >Comment By: Mark Hammond (mhammond) Date: 2008-04-09 19:49 Message: Logged In: YES user_id=14198 Originator: NO thanks ---------------------------------------------------------------------- Comment By: Antoine LECA (antoinel) Date: 2008-01-12 04:13 Message: Logged In: YES user_id=66891 Originator: YES I doubt nobody will ever solve the problem... Nevertheless, I did solve it the following way: I installed an old copy of the pure-Python development of the datetime module that was done some years ago as part of the Zope project. Precisely, I grabbed http://cvs.zope.org/*checkout*/Zope3/src/datetime/Attic/_datetime.py?rev=1.36&hideattic=0 I put the file directly into the win32/lib directory, where win32timezone.py normaly resides. Then I modified win32timezone.py in the following way (also attached): --- win32timezone.py.org Tue Jan 03 10:12:38 2006 +++ win32timezone.py Fri Jan 11 14:02:12 2008 @@ -75,7 +75,12 @@ __vssauthor__ = '$Author: mhammond $'[9:-2] __date__ = '$Modtime: 04-04-14 10:52 $'[10:-2] -import os, _winreg, struct, datetime +import os, _winreg, struct +try: + import datetime +except ImportError: + # Pure Python local version for 2.2- version + import _datetime as datetime class TimeZoneInfo( datetime.tzinfo ): """ I tested it hastily on two installations I have at hand (one is 2.2 and the other is 2.5), and did not detect any problem (besides having to modify the "import datetime" statements, but that is becuase of my low knowledge of Pythn, surely one can make better when you know the lookup rules.) I lowered the status, since I have a working workaround (which is not going to the other station, as it previsouly was...) Now some admin should clean up all this, and close the case. File Added: win32timezone.py.diff ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1707248&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-08 21:20:49
|
Bugs item #1799934, was opened at 2007-09-22 06:29 Message generated for change (Comment added) made by mhammond You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1799934&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: installation Group: None >Status: Pending Resolution: None Priority: 5 Private: No Submitted By: Zooko O'Whielacronx (zooko) Assigned to: Nobody/Anonymous (nobody) Summary: easy_install silently fails Initial Comment: If I install pywin32 by executing pywin32-210.win32-py2.5.exe , it works. If I run "easy_install pywin32" then it claims that it is downloading and installing pywin32-210.win32-py2.5.exe , and after a while it claims that it has successfully installed it, but an attempt to use pywin32 yields errors like this: $ python -c 'import win32process' Traceback (most recent call last): File "<string>", line 1, in <module> ImportError: DLL load failed: The specified module could not be found. I'm not sure whether this should be considered a bug in pywin32 or in easy_install, or both. Regards, Zooko ---------------------------------------------------------------------- >Comment By: Mark Hammond (mhammond) Date: 2008-04-09 07:20 Message: Logged In: YES user_id=14198 Originator: NO I believe PJE recently fixed a bug in setuptools that was causing problems with pywin32 as an egg. Please try again after build 211 is released. ---------------------------------------------------------------------- Comment By: Zooko O'Whielacronx (zooko) Date: 2008-01-26 01:17 Message: Logged In: YES user_id=52562 Originator: YES See also: http://mail.python.org/pipermail/distutils-sig/2007-July/007823.html ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2007-10-01 09:33 Message: Logged In: YES user_id=14198 Originator: NO I've no idea - that too is an easy_install question. I've never used easy_install to install pywin32, and I've never recommended anyone else do it either. ---------------------------------------------------------------------- Comment By: Zooko O'Whielacronx (zooko) Date: 2007-10-01 08:57 Message: Logged In: YES user_id=52562 Originator: YES I will see if I can make the pywin32_postinstall.py stuff get done automatically upon easy_install. In the meantime, is there some way to make this failure loud instead of silent? How do you tell easy_install: yes, there is a package in the expected format (.zip) in the expected place (pypi), but it isn't actually going to work? ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2007-09-22 09:57 Message: Logged In: YES user_id=14198 Originator: NO After install, pywin32_postinstall.py needs to be run, but ezsetup apparently does not provide a facility to do that. You may like to ask them for such a facility. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1799934&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-08 21:19:10
|
Bugs item #1935488, was opened at 2008-04-06 02:49 Message generated for change (Comment added) made by mhammond You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: com Group: None >Status: Closed >Resolution: Fixed Priority: 5 Private: No Submitted By: Santi Wangkerkoon (santiwk) Assigned to: Nobody/Anonymous (nobody) Summary: gencache and Delphi Currency Initial Comment: Delphi snippet: procedure Setprice(PriceLevel: Smallint; pVal: Currency); As pywin32-210's makepy and gencache comes: def Setprice(self, PriceLevel=defaultNamedNotOptArg, arg1=defaultUnnamedArg): return self._oleobj_.InvokeTypes(4, LCID, 4, (24, 0), ((2, 0), (6, 1)),PriceLevel, arg1) Calling Setprice() causes Variant exception! I had to change the above python from (6, 1) to (4, 1) The effect is to change (pVal: Currency) to (pVal: Single) Is there any other way around ? ---------------------------------------------------------------------- >Comment By: Mark Hammond (mhammond) Date: 2008-04-09 07:19 Message: Logged In: YES user_id=14198 Originator: NO Thanks for testing this so quickly! I believe there is no auto conversion as it is impossible to convert between floats and decimals without losing precision (ie, one of the main reasons decimal/currency exists is because it is so much more accurate than floats - and losing this extra accuracy silently would be bad. ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-09 02:20 Message: Logged In: YES user_id=1445373 Originator: YES pywin32-210.9.win32-py2.5 works great! I just wonder why there is no implicit conversion between float/double and Decimal. But that is python story, not pywin32's. Thank you Mr Hammond, for your promptly fix. >>> from win32com.client import Dispatch >>> from decimal import Decimal >>> Ax = Dispatch('Pycurr.PyCurrency') >>> Ax.SetpriceCurr(Decimal('100.0')) >>> Ax.SetpriceCurr(100.0) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "<COMObject Pycurr.PyCurrency>", line 2, in SetpriceCurr TypeError: Currency object must be either a tuple of 2 longs or a Decimal instance (got float). ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2008-04-08 21:55 Message: Logged In: YES user_id=14198 Originator: NO I think I just checked in a fix for this. Would it be possible for you to test starship.python.net/crew/mhammond/pywin32-210.9.win32-py2.5.exe ? Checking in TestSources/PyCOMTest/PyCOMImpl.cpp; new revision: 1.18; previous revision: 1.17 Checking in TestSources/PyCOMTest/PyCOMImpl.h; new revision: 1.16; previous revision: 1.15 Checking in TestSources/PyCOMTest/PyCOMTest.idl; new revision: 1.17; previous revision: 1.16 Checking in win32com/src/oleargs.cpp; new revision: 1.41; previous revision: 1.40 Checking in win32com/src/include/PythonCOM.h; new revision: 1.27; previous revision: 1.26 Checking in win32com/test/testPyComTest.py; new revision: 1.30; previous revision: 1.29 ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-08 00:06 Message: Logged In: YES user_id=1445373 Originator: YES Delete psrvr.zip (Typelib and TRegSvr). TRegSvr is not required, just run PyCurr.exe for register. ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-07 06:05 Message: Logged In: YES user_id=1445373 Originator: YES psrvr.exe source code is not available, so I write a small PyCurr.exe for your testing. Here is the screen shot: c:\>tregsvr PyCurr.exe >>> from win32com.client import Dispatch >>> Ax = Dispatch('PyCurr.PyCurrency') >>> Ax.SetpriceFloat(100.0) >>> Ax.SetpriceDouble(100.0) >>> Ax.SetpriceCurr(100.0) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "<COMObject PyCurr.PyCurrency>", line 2, in SetpriceCurr TypeError: The VARIANT type is unknown (00000006) File Added: PyCurr.zip ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-06 17:12 Message: Logged In: YES user_id=1445373 Originator: YES The typelib is in .exe file. So I send it with register tool. (regsvr32 won't work.) The steps I test :- ...tregsvr psrvr.exe ...makepy.py: psrvr 1.0 File Added: psrvr.zip ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2008-04-06 09:08 Message: Logged In: YES user_id=14198 Originator: NO I can't think if why this would have changed. Is it possible the COM object itself changed? Can you send me the typelib? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-08 16:20:39
|
Bugs item #1935488, was opened at 2008-04-05 23:49 Message generated for change (Comment added) made by santiwk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: com Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Santi Wangkerkoon (santiwk) Assigned to: Nobody/Anonymous (nobody) Summary: gencache and Delphi Currency Initial Comment: Delphi snippet: procedure Setprice(PriceLevel: Smallint; pVal: Currency); As pywin32-210's makepy and gencache comes: def Setprice(self, PriceLevel=defaultNamedNotOptArg, arg1=defaultUnnamedArg): return self._oleobj_.InvokeTypes(4, LCID, 4, (24, 0), ((2, 0), (6, 1)),PriceLevel, arg1) Calling Setprice() causes Variant exception! I had to change the above python from (6, 1) to (4, 1) The effect is to change (pVal: Currency) to (pVal: Single) Is there any other way around ? ---------------------------------------------------------------------- >Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-08 23:20 Message: Logged In: YES user_id=1445373 Originator: YES pywin32-210.9.win32-py2.5 works great! I just wonder why there is no implicit conversion between float/double and Decimal. But that is python story, not pywin32's. Thank you Mr Hammond, for your promptly fix. >>> from win32com.client import Dispatch >>> from decimal import Decimal >>> Ax = Dispatch('Pycurr.PyCurrency') >>> Ax.SetpriceCurr(Decimal('100.0')) >>> Ax.SetpriceCurr(100.0) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "<COMObject Pycurr.PyCurrency>", line 2, in SetpriceCurr TypeError: Currency object must be either a tuple of 2 longs or a Decimal instance (got float). ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2008-04-08 18:55 Message: Logged In: YES user_id=14198 Originator: NO I think I just checked in a fix for this. Would it be possible for you to test starship.python.net/crew/mhammond/pywin32-210.9.win32-py2.5.exe ? Checking in TestSources/PyCOMTest/PyCOMImpl.cpp; new revision: 1.18; previous revision: 1.17 Checking in TestSources/PyCOMTest/PyCOMImpl.h; new revision: 1.16; previous revision: 1.15 Checking in TestSources/PyCOMTest/PyCOMTest.idl; new revision: 1.17; previous revision: 1.16 Checking in win32com/src/oleargs.cpp; new revision: 1.41; previous revision: 1.40 Checking in win32com/src/include/PythonCOM.h; new revision: 1.27; previous revision: 1.26 Checking in win32com/test/testPyComTest.py; new revision: 1.30; previous revision: 1.29 ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-07 21:06 Message: Logged In: YES user_id=1445373 Originator: YES Delete psrvr.zip (Typelib and TRegSvr). TRegSvr is not required, just run PyCurr.exe for register. ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-07 03:05 Message: Logged In: YES user_id=1445373 Originator: YES psrvr.exe source code is not available, so I write a small PyCurr.exe for your testing. Here is the screen shot: c:\>tregsvr PyCurr.exe >>> from win32com.client import Dispatch >>> Ax = Dispatch('PyCurr.PyCurrency') >>> Ax.SetpriceFloat(100.0) >>> Ax.SetpriceDouble(100.0) >>> Ax.SetpriceCurr(100.0) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "<COMObject PyCurr.PyCurrency>", line 2, in SetpriceCurr TypeError: The VARIANT type is unknown (00000006) File Added: PyCurr.zip ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-06 14:12 Message: Logged In: YES user_id=1445373 Originator: YES The typelib is in .exe file. So I send it with register tool. (regsvr32 won't work.) The steps I test :- ...tregsvr psrvr.exe ...makepy.py: psrvr 1.0 File Added: psrvr.zip ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2008-04-06 06:08 Message: Logged In: YES user_id=14198 Originator: NO I can't think if why this would have changed. Is it possible the COM object itself changed? Can you send me the typelib? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-08 11:54:56
|
Bugs item #1935488, was opened at 2008-04-06 02:49 Message generated for change (Comment added) made by mhammond You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: com Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Santi Wangkerkoon (santiwk) Assigned to: Nobody/Anonymous (nobody) Summary: gencache and Delphi Currency Initial Comment: Delphi snippet: procedure Setprice(PriceLevel: Smallint; pVal: Currency); As pywin32-210's makepy and gencache comes: def Setprice(self, PriceLevel=defaultNamedNotOptArg, arg1=defaultUnnamedArg): return self._oleobj_.InvokeTypes(4, LCID, 4, (24, 0), ((2, 0), (6, 1)),PriceLevel, arg1) Calling Setprice() causes Variant exception! I had to change the above python from (6, 1) to (4, 1) The effect is to change (pVal: Currency) to (pVal: Single) Is there any other way around ? ---------------------------------------------------------------------- >Comment By: Mark Hammond (mhammond) Date: 2008-04-08 21:55 Message: Logged In: YES user_id=14198 Originator: NO I think I just checked in a fix for this. Would it be possible for you to test starship.python.net/crew/mhammond/pywin32-210.9.win32-py2.5.exe ? Checking in TestSources/PyCOMTest/PyCOMImpl.cpp; new revision: 1.18; previous revision: 1.17 Checking in TestSources/PyCOMTest/PyCOMImpl.h; new revision: 1.16; previous revision: 1.15 Checking in TestSources/PyCOMTest/PyCOMTest.idl; new revision: 1.17; previous revision: 1.16 Checking in win32com/src/oleargs.cpp; new revision: 1.41; previous revision: 1.40 Checking in win32com/src/include/PythonCOM.h; new revision: 1.27; previous revision: 1.26 Checking in win32com/test/testPyComTest.py; new revision: 1.30; previous revision: 1.29 ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-08 00:06 Message: Logged In: YES user_id=1445373 Originator: YES Delete psrvr.zip (Typelib and TRegSvr). TRegSvr is not required, just run PyCurr.exe for register. ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-07 06:05 Message: Logged In: YES user_id=1445373 Originator: YES psrvr.exe source code is not available, so I write a small PyCurr.exe for your testing. Here is the screen shot: c:\>tregsvr PyCurr.exe >>> from win32com.client import Dispatch >>> Ax = Dispatch('PyCurr.PyCurrency') >>> Ax.SetpriceFloat(100.0) >>> Ax.SetpriceDouble(100.0) >>> Ax.SetpriceCurr(100.0) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "<COMObject PyCurr.PyCurrency>", line 2, in SetpriceCurr TypeError: The VARIANT type is unknown (00000006) File Added: PyCurr.zip ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-06 17:12 Message: Logged In: YES user_id=1445373 Originator: YES The typelib is in .exe file. So I send it with register tool. (regsvr32 won't work.) The steps I test :- ...tregsvr psrvr.exe ...makepy.py: psrvr 1.0 File Added: psrvr.zip ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2008-04-06 09:08 Message: Logged In: YES user_id=14198 Originator: NO I can't think if why this would have changed. Is it possible the COM object itself changed? Can you send me the typelib? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-08 11:46:43
|
Bugs item #1927604, was opened at 2008-03-28 11:05 Message generated for change (Comment added) made by mhammond You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1927604&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: com Group: None >Status: Closed >Resolution: Invalid Priority: 5 Private: No Submitted By: Brad Johnson (urban_dk) Assigned to: Nobody/Anonymous (nobody) Summary: PyCom_PyObjectFromVariant won't convert VT_VARIANT Initial Comment: Any attempts to use the function PyCom_PyObjectFromVariant with an input variant of type VT_VARIANT will fail with "E_OUTOFMEMORY." Should this function recurse until it finds a different variant type underneath? IDispEventSimpleImpl clients from ATL will handle this case correctly, does that mean this is a bug :-)? ---------------------------------------------------------------------- >Comment By: Mark Hammond (mhammond) Date: 2008-04-08 21:46 Message: Logged In: YES user_id=14198 Originator: NO I'm afraid this appears invalid. I made a patch to the test suite, which does work correctly for in-process clients - but fails with E_INVALID_PARAM when executed as a LocalServer (ie, as an external process). It appears the COM marshaller is raising this error, implying it doesn't know how to move such a variant between processes. If anyone can find evidence to the contrary, please re-open. File Added: variant_in_variant.patch ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1927604&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-08 09:31:55
|
Patches item #1937527, was opened at 2008-04-08 12:32 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551956&aid=1937527&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: ionel (ionel_mc) Assigned to: Nobody/Anonymous (nobody) Summary: win32file.ConnectEx patch Initial Comment: A patch for ConnectEx. called as follows: win32file.ConnectEx(sock, (host, port), overlappedobj [, bufferobj]) here's an example: import socket, win32file, pywintypes s = socket.socket() ol = pywintypes.OVERLAPPED() s.bind(('0.0.0.0', 0)) # connectex requires the socket be bound beforehand print win32file.ConnectEx(s, ("google.com", 80), ol, "GET / HTTP/1.1\r\n\r\n") print win32file.GetOverlappedResult(s.fileno(), ol, 1) ol = pywintypes.OVERLAPPED() buff = win32file.AllocateReadBuffer(20480) print win32file.WSARecv(s, buff, ol, 0) print win32file.GetOverlappedResult(s.fileno(), ol, 1) print buff I've tested this on win xp. I use getaddrinfo to process the (host, port) tuple. Please review. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551956&aid=1937527&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-07 14:06:21
|
Bugs item #1935488, was opened at 2008-04-05 23:49 Message generated for change (Comment added) made by santiwk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: com Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Santi Wangkerkoon (santiwk) Assigned to: Nobody/Anonymous (nobody) Summary: gencache and Delphi Currency Initial Comment: Delphi snippet: procedure Setprice(PriceLevel: Smallint; pVal: Currency); As pywin32-210's makepy and gencache comes: def Setprice(self, PriceLevel=defaultNamedNotOptArg, arg1=defaultUnnamedArg): return self._oleobj_.InvokeTypes(4, LCID, 4, (24, 0), ((2, 0), (6, 1)),PriceLevel, arg1) Calling Setprice() causes Variant exception! I had to change the above python from (6, 1) to (4, 1) The effect is to change (pVal: Currency) to (pVal: Single) Is there any other way around ? ---------------------------------------------------------------------- >Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-07 21:06 Message: Logged In: YES user_id=1445373 Originator: YES Delete psrvr.zip (Typelib and TRegSvr). TRegSvr is not required, just run PyCurr.exe for register. ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-07 03:05 Message: Logged In: YES user_id=1445373 Originator: YES psrvr.exe source code is not available, so I write a small PyCurr.exe for your testing. Here is the screen shot: c:\>tregsvr PyCurr.exe >>> from win32com.client import Dispatch >>> Ax = Dispatch('PyCurr.PyCurrency') >>> Ax.SetpriceFloat(100.0) >>> Ax.SetpriceDouble(100.0) >>> Ax.SetpriceCurr(100.0) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "<COMObject PyCurr.PyCurrency>", line 2, in SetpriceCurr TypeError: The VARIANT type is unknown (00000006) File Added: PyCurr.zip ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-06 14:12 Message: Logged In: YES user_id=1445373 Originator: YES The typelib is in .exe file. So I send it with register tool. (regsvr32 won't work.) The steps I test :- ...tregsvr psrvr.exe ...makepy.py: psrvr 1.0 File Added: psrvr.zip ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2008-04-06 06:08 Message: Logged In: YES user_id=14198 Originator: NO I can't think if why this would have changed. Is it possible the COM object itself changed? Can you send me the typelib? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-06 20:05:46
|
Bugs item #1935488, was opened at 2008-04-05 23:49 Message generated for change (Comment added) made by santiwk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: com Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Santi Wangkerkoon (santiwk) Assigned to: Nobody/Anonymous (nobody) Summary: gencache and Delphi Currency Initial Comment: Delphi snippet: procedure Setprice(PriceLevel: Smallint; pVal: Currency); As pywin32-210's makepy and gencache comes: def Setprice(self, PriceLevel=defaultNamedNotOptArg, arg1=defaultUnnamedArg): return self._oleobj_.InvokeTypes(4, LCID, 4, (24, 0), ((2, 0), (6, 1)),PriceLevel, arg1) Calling Setprice() causes Variant exception! I had to change the above python from (6, 1) to (4, 1) The effect is to change (pVal: Currency) to (pVal: Single) Is there any other way around ? ---------------------------------------------------------------------- >Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-07 03:05 Message: Logged In: YES user_id=1445373 Originator: YES psrvr.exe source code is not available, so I write a small PyCurr.exe for your testing. Here is the screen shot: c:\>tregsvr PyCurr.exe >>> from win32com.client import Dispatch >>> Ax = Dispatch('PyCurr.PyCurrency') >>> Ax.SetpriceFloat(100.0) >>> Ax.SetpriceDouble(100.0) >>> Ax.SetpriceCurr(100.0) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "<COMObject PyCurr.PyCurrency>", line 2, in SetpriceCurr TypeError: The VARIANT type is unknown (00000006) File Added: PyCurr.zip ---------------------------------------------------------------------- Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-06 14:12 Message: Logged In: YES user_id=1445373 Originator: YES The typelib is in .exe file. So I send it with register tool. (regsvr32 won't work.) The steps I test :- ...tregsvr psrvr.exe ...makepy.py: psrvr 1.0 File Added: psrvr.zip ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2008-04-06 06:08 Message: Logged In: YES user_id=14198 Originator: NO I can't think if why this would have changed. Is it possible the COM object itself changed? Can you send me the typelib? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-06 07:12:26
|
Bugs item #1935488, was opened at 2008-04-05 23:49 Message generated for change (Comment added) made by santiwk You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: com Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Santi Wangkerkoon (santiwk) Assigned to: Nobody/Anonymous (nobody) Summary: gencache and Delphi Currency Initial Comment: Delphi snippet: procedure Setprice(PriceLevel: Smallint; pVal: Currency); As pywin32-210's makepy and gencache comes: def Setprice(self, PriceLevel=defaultNamedNotOptArg, arg1=defaultUnnamedArg): return self._oleobj_.InvokeTypes(4, LCID, 4, (24, 0), ((2, 0), (6, 1)),PriceLevel, arg1) Calling Setprice() causes Variant exception! I had to change the above python from (6, 1) to (4, 1) The effect is to change (pVal: Currency) to (pVal: Single) Is there any other way around ? ---------------------------------------------------------------------- >Comment By: Santi Wangkerkoon (santiwk) Date: 2008-04-06 14:12 Message: Logged In: YES user_id=1445373 Originator: YES The typelib is in .exe file. So I send it with register tool. (regsvr32 won't work.) The steps I test :- ...tregsvr psrvr.exe ...makepy.py: psrvr 1.0 File Added: psrvr.zip ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2008-04-06 06:08 Message: Logged In: YES user_id=14198 Originator: NO I can't think if why this would have changed. Is it possible the COM object itself changed? Can you send me the typelib? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-06 02:03:12
|
Bugs item #1820151, was opened at 2007-10-26 03:29 Message generated for change (Settings changed) made by mhammond You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1820151&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: pythonwin Group: None >Status: Closed >Resolution: Wont Fix Priority: 5 Private: No Submitted By: Joe Foley (foley) Assigned to: Nobody/Anonymous (nobody) Summary: Solidworks API pass-by-reference Initial Comment: When you run makepy on the SolidWorks api, it gets confused on any of the methods that use pass-by reference. In particular, to anyone trying to do automation using OpenDoc6 runs into the problem of the errors and warnings arguments which are pass-by reference being considered non-optional, even though they are return values. A fairly in-depth discussion and possible workarounds can be found at: http://ephemeralvalue.com/?p=16 and http://mail.python.org/pipermail/python-list/2002-December/175880.html Is there a way to make makepy not get confused on these methods, or is this just a function of the SolidWorks API? ---------------------------------------------------------------------- >Comment By: Mark Hammond (mhammond) Date: 2008-04-06 11:59 Message: Logged In: YES user_id=14198 Originator: NO The solution would seem to be to call the function like: model, errors, warnings = sw.OpenDoc6( 'cube.sldprt', constants.swDocPART, constants.swOpenDocOptions_Silent, '', pythoncom.Missing, pythoncom.Missing ) ? Please reopen this if I'm missing something. Sadly, I can't change the defaults as that would cause many other things to break... ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1820151&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-05 23:08:26
|
Bugs item #1935488, was opened at 2008-04-06 02:49 Message generated for change (Comment added) made by mhammond You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: com Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Santi Wangkerkoon (santiwk) Assigned to: Nobody/Anonymous (nobody) Summary: gencache and Delphi Currency Initial Comment: Delphi snippet: procedure Setprice(PriceLevel: Smallint; pVal: Currency); As pywin32-210's makepy and gencache comes: def Setprice(self, PriceLevel=defaultNamedNotOptArg, arg1=defaultUnnamedArg): return self._oleobj_.InvokeTypes(4, LCID, 4, (24, 0), ((2, 0), (6, 1)),PriceLevel, arg1) Calling Setprice() causes Variant exception! I had to change the above python from (6, 1) to (4, 1) The effect is to change (pVal: Currency) to (pVal: Single) Is there any other way around ? ---------------------------------------------------------------------- >Comment By: Mark Hammond (mhammond) Date: 2008-04-06 09:08 Message: Logged In: YES user_id=14198 Originator: NO I can't think if why this would have changed. Is it possible the COM object itself changed? Can you send me the typelib? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-05 16:49:04
|
Bugs item #1935488, was opened at 2008-04-05 23:49 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: com Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Santi Wangkerkoon (santiwk) Assigned to: Nobody/Anonymous (nobody) Summary: gencache and Delphi Currency Initial Comment: Delphi snippet: procedure Setprice(PriceLevel: Smallint; pVal: Currency); As pywin32-210's makepy and gencache comes: def Setprice(self, PriceLevel=defaultNamedNotOptArg, arg1=defaultUnnamedArg): return self._oleobj_.InvokeTypes(4, LCID, 4, (24, 0), ((2, 0), (6, 1)),PriceLevel, arg1) Calling Setprice() causes Variant exception! I had to change the above python from (6, 1) to (4, 1) The effect is to change (pVal: Currency) to (pVal: Single) Is there any other way around ? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1935488&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-04 05:11:54
|
Bugs item #1934089, was opened at 2008-04-04 15:12 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1934089&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Mark Hammond (mhammond) Assigned to: Mark Hammond (mhammond) Summary: swig arg converters leak on error converting args Initial Comment: Roger noticed that in the generated SWIG code, most converters return NULL, even if other args required cleanup. This can be fixed but (a) it relies on args being initialized and (b) it may cause bloat. Re a), Roger also notes in win32gui will need some work, though. The freearg section for STRING_OR_ATOM_CW checks the result, but HWND doesn't have in initializer. b) can somewhat be mitigated by using "optimize for size" for these files. Both these combined cause too much risk for build 211, so adding the patch here. Note the patch does most of pywintypes.i, but we need to check the others. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1934089&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-04-02 04:34:40
|
Bugs item #1931877, was opened at 2008-04-01 21:34 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1931877&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: installation Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Adam Getchell (acgetchell) Assigned to: Nobody/Anonymous (nobody) Summary: Vista 64-bit install Initial Comment: Fails with: Can't load Python for pre-install script ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1931877&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-03-31 01:19:24
|
Bugs item #1709340, was opened at 2007-04-28 13:26 Message generated for change (Comment added) made by wyrock You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1709340&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: win32 Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: wyrock (wyrock) Assigned to: Mark Hammond (mhammond) Summary: ByRef 2D arrays of 1 Byte improperly handled Initial Comment: If a COM module passes a 2D array where one each dimension is only one byte, then win32com only returns a buffer. The buffer prevents access from the other dimension of the array. It is expected to get an array of buffers. The bug lies in oleargs.cpp. I've attached an updated version of oleargs.cpp and also some modified versions of the com_testing code to show the problem. Could someone please review the proposed fix and commit the change? Thanks, ---------------------------------------------------------------------- >Comment By: wyrock (wyrock) Date: 2008-03-30 20:19 Message: Logged In: YES user_id=1681725 Originator: YES I just wanted to add some follow up here and get some advice....First off, I now see why my original patch was busted. I think someone else tried to warn me but, the data in the SAFEARRAY is not stored in the same order you think of for a traditional C array. A couple of ideas: instead of leaving it broken, how about just not special casing the multi-dimensional VT_UI1 BYREF array? I'm not asking for a change in the VT_U1 BYREF for a single dimension, just multiple. OR: #2 Return a new object (like Mark was suggestion) something with the following attributes: dimensions = a list, where each entry in the list is (upperbound-lowerbound) for each dimension bufferdata = the massive buffer of the multi-dimensional array I like #1 b/c its easy and the buffer is #2 is going to be a bit of pain to convert back in to a multi-dimensional array that makes since to python code. However, #2 may be the preferred method for others. I'm pretty new to the C side of Python, but I'm guessing I could use the ctypes Structure class or the PyRecord class to implement this. Just thought I'd ask to see if I could get away with #1 or if there was any comments suggestions behind #2. ---------------------------------------------------------------------- Comment By: wyrock (wyrock) Date: 2007-07-27 07:26 Message: Logged In: YES user_id=1681725 Originator: YES I'm sorry the patch I submitted didn't work. Not sure what went wrong there. The patch you proposed would also need handle the Set2dByteArrayVariantByRef...Being able to pass in a multi-dimensional array is important also. ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2007-07-26 03:31 Message: Logged In: YES user_id=14198 Originator: NO I'm adding a new patch that doesn't attempt to return multiple buffers - I couldn't make the old patch return the correct data, and http://mail.python.org/pipermail/python-win32/2007-July/006096.html convinces me that the right thing to do may well be to return a single buffer in this case, so long as the caller can get the dimensions - that way, if the data is destined for PIL etc, its very efficient, but still simple for someone to slice up if they really do need it as a multi-dim array. The patch works, but I'm reluctant to check it in until we do return the dimensions. This might mean creating a new buffer-like object. File Added: 2d_ui1.patch ---------------------------------------------------------------------- Comment By: wyrock (wyrock) Date: 2007-07-23 06:59 Message: Logged In: YES user_id=1681725 Originator: YES Mark, I was just curious if you had been able to review this change and add it to the current source tree? Thanks, Kevin ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2007-05-15 17:31 Message: Logged In: YES user_id=14198 Originator: NO Thanks - I'll look at this when I get time. You can build an executable by running: setup.py bdist_wininst ---------------------------------------------------------------------- Comment By: wyrock (wyrock) Date: 2007-05-15 08:00 Message: Logged In: YES user_id=1681725 Originator: YES Now that I've built the source with the fix. I know i can do setup.py -q install, but is there an existing script for making the win32 .exe that gets distributed? Also, the diff is fairly short, so I'll just post directly here: ? diff.out ? com/TestSources/PyCOMTest/PyCOMTest.plg ? com/win32com/src/oleargs.orig.cpp ? win32/src/_winxpthememodule.backup.cpp Index: com/TestSources/PyCOMTest/PyCOMImpl.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/com/TestSources/PyCOMTest/PyCOMImpl.cpp,v retrieving revision 1.15 diff -r1.15 PyCOMImpl.cpp 312a313,347 > STDMETHODIMP CPyCOMTest::GetComplexVariantByRef(VARIANT *out) > { > VariantClear(out); // necessary? > // Creating a safe array with two dimensions to make sure > // an array of buffers can be returned > SAFEARRAYBOUND sabBound[2]={ {5,0}, {8,0}}; > SAFEARRAY *psaDataBuffer = SafeArrayCreate(VT_UI1,2,sabBound); > VariantInit(out); > out->vt = VT_ARRAY | VT_UI1; > out->parray = psaDataBuffer; > long indicies[2] = {0,0}; > for(int i=0;i<5;i++){ > indicies[0]=i; > for(int j=0;j<8;j++){ > indicies[1] = j; > SafeArrayPutElement(psaDataBuffer,indicies,&j); > > } > } > return S_OK; > } > > > STDMETHODIMP CPyCOMTest::SetComplexVariantByRef(VARIANT *v) > { > > if( v->parray->cDims == 2 && v->parray->rgsabound[1].cElements==5 && > v->parray->rgsabound[0].cElements==8){ > return S_OK; > } > return -1; > } > > > Index: com/TestSources/PyCOMTest/PyCOMImpl.h =================================================================== RCS file: /cvsroot/pywin32/pywin32/com/TestSources/PyCOMTest/PyCOMImpl.h,v retrieving revision 1.14 diff -r1.14 PyCOMImpl.h 81a82,84 > STDMETHOD(GetComplexVariantByRef)(VARIANT *out); > STDMETHOD(SetComplexVariantByRef)(VARIANT *v); > Index: com/TestSources/PyCOMTest/PyCOMTest.dsp =================================================================== RCS file: /cvsroot/pywin32/pywin32/com/TestSources/PyCOMTest/PyCOMTest.idl,v retrieving revision 1.15 diff -r1.15 PyCOMTest.idl 198a199,200 > HRESULT GetComplexVariantByRef([out, retval] VARIANT *vout); > HRESULT SetComplexVariantByRef([out] VARIANT *v); Index: com/win32com/src/oleargs.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/com/win32com/src/oleargs.cpp,v retrieving revision 1.37 diff -r1.37 oleargs.cpp 398c398 < if (dimNo==nDims && vt==VT_UI1 && obj->ob_type->tp_as_buffer) { --- > if (dimNo==nDims && obj->ob_type->tp_as_buffer) { 831c831 < if (vt==VT_UI1) { --- > if (vt==VT_UI1 && dimNo==nDims) { ---------------------------------------------------------------------- Comment By: wyrock (wyrock) Date: 2007-05-12 07:14 Message: Logged In: YES user_id=1681725 Originator: YES File Added: test2dByRef.py ---------------------------------------------------------------------- Comment By: wyrock (wyrock) Date: 2007-05-12 07:13 Message: Logged In: YES user_id=1681725 Originator: YES Attaching the cvs diff with the fix (in oleargs.cpp) and some modifications to the test bench that test for the issue. File Added: diff.out ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2007-05-06 06:00 Message: Logged In: YES user_id=14198 Originator: NO Thanks! I haven't looked yet, but I can believe what you say is true. I'll (try to) get to this before the next release (but a .diff against the test suite instead of the .zip with a complete copy would help even more!) If you have the c compiler handy, then 'setup.py install' from CVS is quite an easy way to get a build from sources (but I digress... :) ---------------------------------------------------------------------- Comment By: wyrock (wyrock) Date: 2007-05-05 17:10 Message: Logged In: YES user_id=1681725 Originator: YES File Added: oleargs.new.cpp ---------------------------------------------------------------------- Comment By: wyrock (wyrock) Date: 2007-04-28 13:35 Message: Logged In: YES user_id=1681725 Originator: YES File Added: testSmaller.py ---------------------------------------------------------------------- Comment By: wyrock (wyrock) Date: 2007-04-28 13:34 Message: Logged In: YES user_id=1681725 Originator: YES File Added: com_testing2.zip ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1709340&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-03-28 00:05:08
|
Bugs item #1927604, was opened at 2008-03-27 17:05 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1927604&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: com Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Brad Johnson (urban_dk) Assigned to: Nobody/Anonymous (nobody) Summary: PyCom_PyObjectFromVariant won't convert VT_VARIANT Initial Comment: Any attempts to use the function PyCom_PyObjectFromVariant with an input variant of type VT_VARIANT will fail with "E_OUTOFMEMORY." Should this function recurse until it finds a different variant type underneath? IDispEventSimpleImpl clients from ATL will handle this case correctly, does that mean this is a bug :-)? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1927604&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-03-24 13:58:07
|
Bugs item #1920299, was opened at 2008-03-19 22:45 Message generated for change (Comment added) made by goermezer You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1920299&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None >Status: Open Resolution: None Priority: 5 Private: No Submitted By: Mustafa (goermezer) Assigned to: Nobody/Anonymous (nobody) Summary: arrayOfVariantOfBSTR in Python Initial Comment: Hi, I have problem with an application which I try to automate with win32com. My problem is now, that a GetListOfDependantFile expects a arrayOfVariantOfBSTR byreference. I think this must be a list of strings. The VB Code is this: Set Send1 = CATIA.CreateSendTo() Call Send.SetInitialFile(myfile) ReDim arrayOfVariantOfBSTR(500) Call Send1.GetListOfDependantFile(arrayOfVariantOfBSTR) How can I write this in Python for win32com ? best regards Mustafa Görmezer ---------------------------------------------------------------------- >Comment By: Mustafa (goermezer) Date: 2008-03-24 13:58 Message: Logged In: YES user_id=1525528 Originator: YES Hi marc, this is my code: import win32com.client app=win32com.client.Dispatch('Catia.Application') sendto=app.CreateSendTo() sendto.SetInitialFile('c:\\...igteil.CATPart') refs=sendto.GetListOfDependantFile() print refs When I use no params I get a type error or type conflict (with makepy): Traceback (most recent call last): File "C:\Python25\Lib\site-packages\pythonwin\pywin\framework\scriptutils.py", line 310, in RunScript exec codeObject in __main__.__dict__ File "C:\Dokumente und Einstellungen\mgo\Desktop\px1.py", line 9, in <module> refs=sendto.GetListOfDependantFile() File "C:\DOKUME~1\mgo\LOKALE~1\Temp\gen_py\2.5\14F197B2-0771-11D1-A5B1-00A0C9575177x0x0x0\SendToService.py", line 49, in GetListOfDependantFile return self._ApplyTypes_(1610940417, 1, (24, 0), ((8204, 3),), 'GetListOfDependantFile', None,oDependant File "C:\Python25\Lib\site-packages\win32com\client\__init__.py", line 448, in _ApplyTypes_ dispid, 0, wFlags, retType, argTypes, *args), com_error: (-2147352571, 'Typkonflikt.', None, 1) When I give a list as the param, the function returns the param as a tuple: GetListOfDependantFile([]) returns () GetListOfDependantFile(['hello']) returns (u'hello',) Here is the traceback without makepy: Traceback (most recent call last): File "C:\Dokumente und Einstellungen\mgo\Desktop\px1.py", line 6, in <module> refs=sendto.GetListOfDependantFile() File "<COMObject CreateSendTo>", line 2, in GetListOfDependantFile File "C:\Python25\Lib\site-packages\win32com\client\dynamic.py", line 258, in _ApplyTypes_ result = self._oleobj_.InvokeTypes(*(dispid, LCID, wFlags, retType, argTypes ) + args) pywintypes.com_error: (-2147352567, 'Ausnahmefehler aufgetreten.', (0, 'CATIASen dToService', 'Das Verfahren GetListOfDependantFile ist fehlgeschlagen', None, 0, -2147024809), None) ---------------------------------------------------------------------- Comment By: Mark Hammond (mhammond) Date: 2008-03-24 07:49 Message: Logged In: YES user_id=14198 Originator: NO If you run makepy, you should be able to pass no params - the strings will be returned. Please show the code you use and the exception you see. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1920299&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-03-24 07:49:39
|
Bugs item #1920299, was opened at 2008-03-20 09:45 Message generated for change (Settings changed) made by mhammond You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1920299&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None >Status: Pending Resolution: None Priority: 5 Private: No Submitted By: Mustafa (goermezer) Assigned to: Nobody/Anonymous (nobody) Summary: arrayOfVariantOfBSTR in Python Initial Comment: Hi, I have problem with an application which I try to automate with win32com. My problem is now, that a GetListOfDependantFile expects a arrayOfVariantOfBSTR byreference. I think this must be a list of strings. The VB Code is this: Set Send1 = CATIA.CreateSendTo() Call Send.SetInitialFile(myfile) ReDim arrayOfVariantOfBSTR(500) Call Send1.GetListOfDependantFile(arrayOfVariantOfBSTR) How can I write this in Python for win32com ? best regards Mustafa Görmezer ---------------------------------------------------------------------- >Comment By: Mark Hammond (mhammond) Date: 2008-03-24 18:49 Message: Logged In: YES user_id=14198 Originator: NO If you run makepy, you should be able to pass no params - the strings will be returned. Please show the code you use and the exception you see. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1920299&group_id=78018 |
From: SourceForge.net <no...@so...> - 2008-03-19 22:45:44
|
Bugs item #1920299, was opened at 2008-03-19 22:45 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1920299&group_id=78018 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Mustafa (goermezer) Assigned to: Nobody/Anonymous (nobody) Summary: arrayOfVariantOfBSTR in Python Initial Comment: Hi, I have problem with an application which I try to automate with win32com. My problem is now, that a GetListOfDependantFile expects a arrayOfVariantOfBSTR byreference. I think this must be a list of strings. The VB Code is this: Set Send1 = CATIA.CreateSendTo() Call Send.SetInitialFile(myfile) ReDim arrayOfVariantOfBSTR(500) Call Send1.GetListOfDependantFile(arrayOfVariantOfBSTR) How can I write this in Python for win32com ? best regards Mustafa Görmezer ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=551954&aid=1920299&group_id=78018 |