Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Python: Dev

What should we do with cProfile?

 

 

Python dev RSS feed   Index | Next | Previous | View Threaded


avassalotti at gmail

May 29, 2012, 2:19 AM

Post #1 of 5 (263 views)
Permalink
What should we do with cProfile?

Hello,

As per PEP 3108, we were supposed to merge profile/cProfile into one
unified module. I initially championed the change, but other things got in
the way and I have never got to the point of a useful patch. I posted some
code and outlined an approach how the merge could be done. However, there
still a lot of details to be worked out.

So I wondering whether we should abandon the change all together or attempt
it for the next release. Personally, I slightly leaning on the former
option since the two modules are actually fairly different underneath even
though they are used similarly. And also, because it is getting late to
make such backward incompatible changes.

I am willing to volunteer to push the change though if it is still desired
by the community.

Cheers!

http://bugs.python.org/issue2919


steve at pearwood

May 29, 2012, 4:58 PM

Post #2 of 5 (251 views)
Permalink
Re: What should we do with cProfile? [In reply to]

Alexandre Vassalotti wrote:
> Hello,
>
> As per PEP 3108, we were supposed to merge profile/cProfile into one
> unified module. I initially championed the change, but other things got in
> the way and I have never got to the point of a useful patch. I posted some
> code and outlined an approach how the merge could be done. However, there
> still a lot of details to be worked out.
>
> So I wondering whether we should abandon the change all together or attempt
> it for the next release. Personally, I slightly leaning on the former
> option since the two modules are actually fairly different underneath even
> though they are used similarly. And also, because it is getting late to
> make such backward incompatible changes.
>
> I am willing to volunteer to push the change though if it is still desired
> by the community.


I don't have a strong opinion either way, but if it was worth merging them for
3.3, then it's worth merging them for 3.4. Don't let "I won't be finished in
time for 3.3" stop you.


--
Steven
_______________________________________________
Python-Dev mailing list
Python-Dev [at] python
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: http://mail.python.org/mailman/options/python-dev/list-python-dev%40lists.gossamer-threads.com


eliben at gmail

May 29, 2012, 8:01 PM

Post #3 of 5 (250 views)
Permalink
Re: What should we do with cProfile? [In reply to]

>> As per PEP 3108, we were supposed to merge profile/cProfile into one
>> unified module. I initially championed the change, but other things got in
>> the way and I have never got to the point of a useful patch. I posted some
>> code and outlined an approach how the merge could be done. However, there
>> still a lot of details to be worked out.
>>
>> So I wondering whether we should abandon the change all together or
>> attempt
>> it for the next release. Personally, I slightly leaning on the former
>> option since the two modules are actually fairly different underneath even
>> though they are used similarly. And also, because it is getting late to
>> make such backward incompatible changes.
>>
>> I am willing to volunteer to push the change though if it is still desired
>> by the community.
>
>
>
> I don't have a strong opinion either way, but if it was worth merging them
> for 3.3, then it's worth merging them for 3.4. Don't let "I won't be
> finished in time for 3.3" stop you.
>

+1
IMHO merging modules with their C accelerators is a worthy goal,
because having two modules in the stdlib doing the same is confusing.
At worst, the merged module can do everything it can in C and defer
the things it can't do to Python (or defer *everything* on platforms
where the C extension can't be built for some reason).

And as Steven said, the 3.3 timeline doesn't have anything really
special about it. Although there's still time until the beta release,
even if this is done for 3.4 it will be great.

Eli
_______________________________________________
Python-Dev mailing list
Python-Dev [at] python
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: http://mail.python.org/mailman/options/python-dev/list-python-dev%40lists.gossamer-threads.com


ncoghlan at gmail

May 29, 2012, 8:30 PM

Post #4 of 5 (248 views)
Permalink
Re: What should we do with cProfile? [In reply to]

On Wed, May 30, 2012 at 1:01 PM, Eli Bendersky <eliben [at] gmail> wrote:
> And as Steven said, the 3.3 timeline doesn't have anything really
> special about it. Although there's still time until the beta release,
> even if this is done for 3.4 it will be great.

Yep - there's a reason the 3.4 target gets added to the tracker even
before 3.3 is out. It's precisely so we can bump things as soon as we
reach a point where we're comparing the effort we think is needed to
get them agreed on and/or bedded down properly and the time remaining
before the first beta and officially say "not going to happen".

I've already done that for Eugene Toder's proposed compiler
enhancements. It's a promising approach, but it's *way* too late in
the 3.3 cycle to be contemplating that kind of change.

Cheers,
Nick.

--
Nick Coghlan   |   ncoghlan [at] gmail   |   Brisbane, Australia
_______________________________________________
Python-Dev mailing list
Python-Dev [at] python
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: http://mail.python.org/mailman/options/python-dev/list-python-dev%40lists.gossamer-threads.com


martin at v

Jun 4, 2012, 3:27 AM

Post #5 of 5 (235 views)
Permalink
Re: What should we do with cProfile? [In reply to]

> So I wondering whether we should abandon the change all together or
> attempt it for the next release. Personally, I slightly leaning on
> the former option since the two modules are actually fairly different
> underneath even though they are used similarly. And also, because it
> is getting late to make such backward incompatible changes.

I agree that this change is not worthwhile for Python 3. I suggest to
close the issue as "won't fix".

I'm not sure whether anybody uses the profile module at all, so
recycling the name might have been appropriate for Python 3.0. But
now that would be a backwards-incompatible change, and I agree it's
doubtful whether a backwards-compatible change can be achieved.

Even if profile could somehow stay compatible, nothing is gained if
cProfile also stays - but it would have to, for backwards compatibility
reasons.

I predict that at some point, somebody contributes yet another profiling
tool which may well supersede both profile and cProfile. If you are
interested in profiling in general, I suggest that you could rather work
on such code, and release it to PyPI.

Regards,
Martin
_______________________________________________
Python-Dev mailing list
Python-Dev [at] python
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: http://mail.python.org/mailman/options/python-dev/list-python-dev%40lists.gossamer-threads.com

Python dev RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.