Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tests fail with Django 1.7 c2 #1747

Closed
brianmay opened this issue Aug 9, 2014 · 4 comments
Closed

tests fail with Django 1.7 c2 #1747

brianmay opened this issue Aug 9, 2014 · 4 comments

Comments

@brianmay
Copy link

brianmay commented Aug 9, 2014

Hello,

As Django 1.7 is due to be released very soon now, this is an important issue.

This is tested with the latest release (2.3.14). The version in git appears to be ok, apart from some warnings.

# python ./rest_framework/runtests/runtests.py
Creating test database for alias 'default'...
System check identified some issues:

WARNINGS:
?: (1_6.W001) Some project unittests may not execute as expected.
        HINT: Django 1.6 introduced a new default test runner. It looks like this project was generated using Django 1.5 or earlier. You should ensure your tests are all running & behaving as expected. See https://docs.djangoproject.com/en/dev/releases/1.6/#new-test-runner for more information.
System check identified some issues:

WARNINGS:
?: (1_6.W001) Some project unittests may not execute as expected.
        HINT: Django 1.6 introduced a new default test runner. It looks like this project was generated using Django 1.5 or earlier. You should ensure your tests are all running & behaving as expected. See https://docs.djangoproject.com/en/dev/releases/1.6/#new-test-runner for more information.
System check identified some issues:

WARNINGS:
?: (1_6.W001) Some project unittests may not execute as expected.
        HINT: Django 1.6 introduced a new default test runner. It looks like this project was generated using Django 1.5 or earlier. You should ensure your tests are all running & behaving as expected. See https://docs.djangoproject.com/en/dev/releases/1.6/#new-test-runner for more information.
.................................................................................................................EEF..........................s...............................................sssssssss..............................................ss..............................................ssssssssssssssssssssssssss............................s................................................................ssssssss.................................sssssss.........................................................................................................sssssss...........................................................
======================================================================
ERROR: test_get_caching (rest_framework.tests.test_renderers.CacheRenderTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./rest_framework/runtests/../../rest_framework/tests/test_renderers.py", line 662, in test_get_caching
    cache.set(self.cache_key, resp)
  File "/usr/lib/python2.7/dist-packages/django/core/cache/backends/locmem.py", line 67, in set
    pickled = pickle.dumps(value, pickle.HIGHEST_PROTOCOL)
PicklingError: Can't pickle <type 'function'>: attribute lookup __builtin__.function failed

======================================================================
ERROR: test_head_caching (rest_framework.tests.test_renderers.CacheRenderTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./rest_framework/runtests/../../rest_framework/tests/test_renderers.py", line 652, in test_head_caching
    cache.set(self.cache_key, resp)
  File "/usr/lib/python2.7/dist-packages/django/core/cache/backends/locmem.py", line 67, in set
    pickled = pickle.dumps(value, pickle.HIGHEST_PROTOCOL)
PicklingError: Can't pickle <type 'function'>: attribute lookup __builtin__.function failed

======================================================================
FAIL: test_obj_pickling (rest_framework.tests.test_renderers.CacheRenderTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./rest_framework/runtests/../../rest_framework/tests/test_renderers.py", line 640, in test_obj_pickling
    self.assertEqual(self._get_pickling_errors(resp), {})
AssertionError: {'_closable_objects': None} != {}
- {'_closable_objects': None}
+ {}

----------------------------------------------------------------------
Ran 631 tests in 1.451s

FAILED (failures=1, errors=2, skipped=61)
Destroying test database for alias 'default'...
@xordoquy
Copy link
Collaborator

xordoquy commented Aug 9, 2014

There's already a branch that solves this (https://github.com/tomchristie/django-rest-framework/tree/feature/django_guardian_cleanup). This will be merged this week end.

@xordoquy xordoquy closed this as completed Aug 9, 2014
@brianmay
Copy link
Author

Do you have any plans for a new release with this fix any time soon? If you do, I can fix the Debian package.

Thanks

@xordoquy
Copy link
Collaborator

@brianmay the kickstarter will end this week end. @tomchristie will correct me if I'm wrong but on top of the todo list is a release that is Django 1.7 compatible.

@tomchristie
Copy link
Member

Releasing 2.3.14 is first on the list, yes. As a preparatory step for the real work.
So, assuming I get to start paid work time next week, then end of next week is the currently plan.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants