Skip to content

First bunch of fixes to make debug-toolbar work with Python 3 #365

Closed
wants to merge 1 commit into from

2 participants

@bkabrda
bkabrda commented Mar 22, 2013

Hi,
I made these initial fixes to start porting debug-toolbar to Python 3. These are the "easy" ones.
The big problem will be the replace_call decorator from utils.tracking, cause you can no longer get the defining class from method (although you can get its name by qualname). So I'd advise changing the signature of replace_call to replace_call(klass, func), where klass will be the defining class(/module) itself and func will be string name of function. I'll do the work, but I want to make sure you'd accept such a change.

Thanks!

@jezdez
django-debug-toolbar member
jezdez commented Mar 25, 2013

So, yeah. please use six (https://pypi.python.org/pypi/six) as the compatibility layer. Although it's included in Django we can't rely on it since we want to support the last Django versions, too.

@bkabrda
bkabrda commented Mar 27, 2013

Turns out someone was faster than me, see PR #366 (although that one utilizes six from django...). Still, the problem with replace_call isn't solved there. Any objections against my proposal above?

@jezdez
django-debug-toolbar member
jezdez commented Apr 23, 2013

Sorry again, but I'm closing this in favor of #373.

@jezdez jezdez closed this Apr 23, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.