472,791 Members | 1,713 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,791 software developers and data experts.

makepy, ADO and dynamic.py

I'm trying to track down a performance issue in my Windows code, and
hotshot is telling me that the most time and calls are spent in these
methods

ncalls tottime percall cumtime percall filename:lineno(function)
75975 63982.779 0.842 124464.419 1.638
c:\python24\lib\site-packages\win32com\client\dynamic.py:285(_make_meth od_)
71294 47871.424 0.671 50629.224 0.710
c:\python24\lib\site-packages\win32com\client\__init__.py:444(_ApplyTyp es_)

If I understand correctly, running makepy on the appropriate COM class
should get rid of the dynamic stuff and let it be called directly. I
use ADODB to talk to my database server, and I've run makepy for
"Microsoft Active X Data Objects 2.8 Library" [1] and on "Microsoft
ActiveX Data Objects Recordset 2.8 Library", but I'm still seeing the
call to the dynamic.py class.

Am I right that seeing the calls in "dynamic.py" implies that I'm
running "makepy" on the wrong thing? Any idea what I should be running
makepy on?

[1] I seem to have a bunch of versions of "Microsoft ActiveX Data
Objects Library", is there a chance that another ADO library is being
used?

Sep 9 '06 #1
1 1453

"Chris Curvey" <cc*****@gmail.comwrote in message news:11**********************@i42g2000cwa.googlegr oups.com...
I'm trying to track down a performance issue in my Windows code, and
hotshot is telling me that the most time and calls are spent in these
methods

ncalls tottime percall cumtime percall filename:lineno(function)
75975 63982.779 0.842 124464.419 1.638
c:\python24\lib\site-packages\win32com\client\dynamic.py:285(_make_meth od_)
71294 47871.424 0.671 50629.224 0.710
c:\python24\lib\site-packages\win32com\client\__init__.py:444(_ApplyTyp es_)

If I understand correctly, running makepy on the appropriate COM class
should get rid of the dynamic stuff and let it be called directly. I
use ADODB to talk to my database server, and I've run makepy for
"Microsoft Active X Data Objects 2.8 Library" [1] and on "Microsoft
ActiveX Data Objects Recordset 2.8 Library", but I'm still seeing the
call to the dynamic.py class.

Am I right that seeing the calls in "dynamic.py" implies that I'm
running "makepy" on the wrong thing? Any idea what I should be running
makepy on?

[1] I seem to have a bunch of versions of "Microsoft ActiveX Data
Objects Library", is there a chance that another ADO library is being
used?
The most reliable way to make sure the generated support is used is
to call win32com.client.gencache.EnsureDispatch. If a typelib can
be found, the corresponding python module will be created if it doesn't
already exist.

Roger
Sep 10 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Gerson Kurz | last post by:
I have problems getting "COM makepy" working in ActivePython 2.3.2. This is what happens when I start "COM makepy" from the Pythonwin Menu: PythonWin 2.3.2 (#49, Nov 6 2003, 10:18:20) on...
0
by: Jim Kerr | last post by:
Does makepy always respect versioning of interfaces? It appears as though makepy correctly handles versioning of objects you obtain directly, but not for objects you get via a function call. ...
1
by: Steve M | last post by:
When I use the COM Makepy utility on one computer with WindowsXP, ActivePython 2.3 and I select the library Microsoft Word 10.0 Object Library (8.2), things work fine. When I have WindowsXP,...
4
by: suzhi18 | last post by:
Hallo, I've a problem getting makepy running. When I start the tool on my machine with doubleclick everything is fine. But when I try this in my Code: makepy.py -i "Microsoft Excel 11.0...
3
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 2 August 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
by: erikbower65 | last post by:
Using CodiumAI's pr-agent is simple and powerful. Follow these steps: 1. Install CodiumAI CLI: Ensure Node.js is installed, then run 'npm install -g codiumai' in the terminal. 2. Connect to...
0
by: kcodez | last post by:
As a H5 game development enthusiast, I recently wrote a very interesting little game - Toy Claw ((http://claw.kjeek.com/))。Here I will summarize and share the development experience here, and hope it...
0
by: Taofi | last post by:
I try to insert a new record but the error message says the number of query names and destination fields are not the same This are my field names ID, Budgeted, Actual, Status and Differences ...
14
DJRhino1175
by: DJRhino1175 | last post by:
When I run this code I get an error, its Run-time error# 424 Object required...This is my first attempt at doing something like this. I test the entire code and it worked until I added this - If...
0
by: Rina0 | last post by:
I am looking for a Python code to find the longest common subsequence of two strings. I found this blog post that describes the length of longest common subsequence problem and provides a solution in...
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
0
by: Mushico | last post by:
How to calculate date of retirement from date of birth
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.