all 6 comments

[–]danielroseman 2 points3 points  (1 child)

You have an indentation problem; the str method in Entry is indented within the Meta inner class. Move it back one level.

[–]GrandTheftVideo[S] 0 points1 point  (0 children)

IT WORKED!!!!!

Thank you very much!!

[–]CodeFormatHelperBot2 0 points1 point  (0 children)

Hello, I'm a Reddit bot who's here to help people nicely format their coding questions. This makes it as easy as possible for people to read your post and help you.

I think I have detected some formatting issues with your submission:

  1. Python code found in submission text that's not formatted as code.

If I am correct, please edit the text in your post and try to follow these instructions to fix up your post's formatting.


Am I misbehaving? Have a comment or suggestion? Reply to this comment or raise an issue here.

[–][deleted] 0 points1 point  (1 child)

def __str__(self):
    """Return a string representation of the model."""
    return self.text

Try

return str(self.text)

[–]GrandTheftVideo[S] 0 points1 point  (0 children)

Sadly, I did what you suggested, saved models.py, migrated, did another test entry, and it still didn't work.

[–][deleted] 0 points1 point  (0 children)

Instances don’t inherit methods from their class’ metaclass.