I did not have time to go over the implementation of ModelBase class
yet but I tried extend my test cases and want to update the progress.
I apply the Carpenter role (in the earlier post) in setUp of all test
classes in 2 small projects and add the test below in each of them.
---
Good idea! I'll try that and update the post.
I'll be out of town for a week, don't think i can code during that. so
my next post would be around the next weekend.
Have a good day!
Chokchai P.
On Dec 4, 12:19 am, bruno desthuilliers
wrote:
> On 3 déc, 08:00, juacompe wrote:
>
> > Hi Bruno,
>
>
On 3 déc, 08:00, juacompe wrote:
> Hi Bruno,
>
> Thank you very much!! Adding an inner Meta class works like charm.
Cool 8)
Now beware, there _might_ be a couple other dark corners... I strongly
suggest you take a look at ModelBase implementation and possibly
extend your test cases, at least t
Hi Bruno,
Thank you very much!! Adding an inner Meta class works like charm.
Below is the working code with proving testcases
--
models.py
--
from django.db.models import Model, CharField
from django.db.models.base import ModelBase
from roles import
On 2 déc, 06:03, juacompe wrote:
> Hi Bruno,
>
> I have tried to save the roled model and got [AttributeError: 'Person
> +Carpenter' object has no attribute 'person_ptr_id'] as in traceback
> below.
>
Uhu... Very quick anwser, would need more in-depth analyses, but I'm
pretty confident the root o
Hi Bruno,
I have tried to save the roled model and got [AttributeError: 'Person
+Carpenter' object has no attribute 'person_ptr_id'] as in traceback
below.
In [1]: from carpenter.models import Person, Carpenter
In [2]: jack = Person(name='Jack')
In [3]: Carpenter(jack)
Out[3]:
In [4]: jack.chop(
On 23 nov, 13:08, Ben Scherrey wrote:
> We are attempting to apply the concepts of Domain-Context
> Interaction (DCI) to our python/django development. Unfortunately, the
> metaclass mechanism which the main python library supporting this uses
> conflicts with that of Django's metaclass for db
We are attempting to apply the concepts of Domain-Context
Interaction (DCI) to our python/django development. Unfortunately, the
metaclass mechanism which the main python library supporting this uses
conflicts with that of Django's metaclass for db.models. What happens
is that a metaclass and n
8 matches
Mail list logo