Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Python Django Forms More on Models Multi-table Inheritance

Cameron S
Cameron S
20,537 Points

Multitable Inheritance Quiz- Cant Inherit Product model into Digital.

I have played around with the Challenge Task 2 of 2. I have no idea what I could possibly be overlooking in my code. Can anyone see anything wrong with what I am doing?

products/models.py
from django.db import models


class Product(models.Model):
    name = models.CharField(max_length=255)
    description = models.TextField()

    class Meta:
        abstract = True


class Digital(Product)
    url = models.URLField()

1 Answer

Nicholas Ward
Nicholas Ward
5,797 Points

Just add a colon after your Digital class and you should be good to go!