Gustavo Picon is sharing code with you

Bitbucket is a code hosting site. Unlimited public and private repositories. Free for small teams.

Don't show this again

tabo / django-treebeard

Efficient tree implementations for Django 1.0+ :: https://tabo.pe/projects/django-treebeard/

Clone this repository (size: 602.0 KB): HTTPS / SSH
hg clone https://bitbucket.org/tabo/django-treebeard
hg clone ssh://hg@bitbucket.org/tabo/django-treebeard

Issues

#20 dump_bulk fails when used in proxy models

Reported by Gustavo Picon (last edited )

As explained in 81fa32fd2e26 :

  • test_al_proxy_dump_bulk_all (treebeard.tests.TestClassMethods)
  • test_al_proxy_dump_bulk_node (treebeard.tests.TestClassMethods)
  • test_al_proxy_load_and_dump_bulk_keeping_ids (treebeard.tests.TestClassMethods)
  • test_mp_proxy_dump_bulk_all (treebeard.tests.TestClassMethods)
  • test_mp_proxy_dump_bulk_node (treebeard.tests.TestClassMethods)
  • test_mp_proxy_load_and_dump_bulk_keeping_ids (treebeard.tests.TestClassMethods)
  • test_ns_proxy_dump_bulk_all (treebeard.tests.TestClassMethods)
  • test_ns_proxy_dump_bulk_node (treebeard.tests.TestClassMethods)
  • test_ns_proxy_load_and_dump_bulk_keeping_ids (treebeard.tests.TestClassMethods)

The error is in... "the dump_bulk method, because for some reason the django object serializer is returning an empty dict in fields."

Status: resolved Responsible: Gustavo Picon Type: bug Priority: major
Milestone: none Component: none Version: none

Attachments

No attachments added for this issue yet.

Comments and changes

  1. #1 Gustavo Picon

    written

    • Changed status from new to open.
  2. #2 Gustavo Picon

    written

    • Changed status from open to resolved.

    Solved in fa65d397e67f :

    Fixed dump_bulk with proxied models.
    
    This is actually a workaround for a bug in django: a proxied object is NOT
    serializable. dump_bulk now uses calls to the original non-proxied class when
    using proxies.
    

    (And bitbucket's automatic ticket closing is still failing. *github envy* )

Add comment / attachment

Show/hide preview

Verification: Please write the text from the image in the box (letters only)

captcha

Is that you, Humanoid? Is this me?