1. Jeff Hardy
  2. django-ipy-patches
  3. Issues
Issue #2 resolved

AssertionError: Cannot call lazy() with both str and unicode return types

spex66
created an issue

I've followed the very first steps and tried to verify my setup with: * django-tutorial\mysite>ipy manage.py runserver This gave me following traceback. Any easy thing I've missed? regards Peter (=PA=) P.S.: IPy 2.7 Beta 1

{{{

!python

<string>:1: DeprecationWarning: object.init() takes no parameters for type KeyedRef Traceback (most recent call last): File "C:\arwa\dev\django.net\django-ironpython\django\core\management__init.py", line 438, in execute_manager File "C:\arwa\dev\django.net\django-ironpython\django\core\management__init.py", line 379, in execute File "C:\arwa\dev\django.net\django-ironpython\django\core\management\commands\runserver.py", line 23, in handle File "C:\arwa\dev\django.net\django-ironpython\django\core\servers\basehttp.py", line 20, in <module> File "C:\arwa\dev\django.net\django-ironpython\django\contrib\staticfiles\handlers.py", line 5, in <module> File "C:\arwa\dev\django.net\django-ironpython\django\core\handlers\wsgi.py", line 9, in <module> File "C:\arwa\dev\django.net\django-ironpython\django\http__init.py", line 24, in <module> File "C:\arwa\dev\django.net\django-ironpython\django\http\multipartparser.py", line 13, in <module> File "C:\arwa\dev\django.net\django-ironpython\django\utils\text.py", line 134, in <module> File "C:\arwa\dev\django.net\django-ironpython\django\utils\functional.py", line 158, in init File "manage.py", line 11, in <module> File "C:\arwa\dev\django.net\django-ironpython\django\core\management\base.py", line 191, in run_from_argv File "C:\arwa\dev\django.net\django-ironpython\django\core\management\base.py", line 220, in execute File "C:\arwa\dev\django.net\django-ironpython\django\utils\functional.py", line 240, in wrapper File "C:\arwa\dev\django.net\django-ironpython\django\utils\functional.py", line 180, in prepare_class__ AssertionError: Cannot call lazy() with both str and unicode return types. }}}

Comments (4)

  1. spex66 reporter

    I know, "Search first" would be the better approach :-/ Just found out that you fixed it (Wiki macro error: Changeset b70eeacda60cb70eeacda60c not found.) 9 month ago. Applying this patch again, lead me to "It worked!" django screen. I'm not a hg or mq expert, so my question: Did this patch get lost? (=PA=)

  2. Jeff Hardy repo owner

    Hi spex66,

    Did you do a hg qpush --all after checking out django-ipy-patches? It's kind of hidden in the instructions, but it's that step that applies all of the ironpyton-specific patches, including a fix for that error.

  3. spex66 reporter

    I did, but I just saw that there was a rollback!

    \hg qpush --all
    applying fix-lazy-with-str-and-unicode
    applying fix-syncdb-management-import-error-handling
    applying ignore-admin-model-sorting
    applying disable-termcolor-ironpython
    applying ReverseSingleRelatedObjectDescriptor-typo
    transaction abort!
    rollback completed
    cleaning up working directory...done
    abort: no username supplied (see "hg help config")
    

    Seems that a username is necessary. Why?!? Added to mercurial.ini section (with my settings):

    [ui]
    username = Firstname Lastname <firstname.lastname@example.net>
    verbose = True
    

    Now it worked! Your patch was applied correct. thank you for your feedback

    It seems to be worth, to mention the need for the "[extensions] mq =" and the [ui] thingy, to make it an easy start for beginners with ipy/django/hg.

    Appreciate your work!

    (=PA=)

  4. Log in to comment