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 trialMUZ140057 Dumisani Nyamusa
8,029 Pointsstage1 meet PEEWEE
Now, create a variable named all_challenges. It should select all of the available challenges from the database
from models import Challenge
all_challenges = challenges.select
2 Answers
mrben
8,068 PointsThere are a couple of issues with your code that you need to solve.
First, on line 2 you reference a variable challenges
that doesn't exist. Look at what you imported on line 1 and update line 2 accordingly.
Secondly, if you look at the Teacher's Notes section on http://teamtreehouse.com/library/using-databases-in-python/meet-peewee/queries-are-your-friend you will see the method call you need to use on the class you imported and how to call it.
Kenneth Love
Treehouse Guest TeacherIt's also a method we use in the video itself.
Cristi Sturgill
Courses Plus Student 29,577 Pointsall_challenges = Challenge.select()
luke hammer
25,513 Pointssorry negative point given for just giving away the answer for the quiz when there was already good notes given where to find the answer. Including a comment from the teacher.
Eric Carter
5,066 PointsEric Carter
5,066 PointsYou're missing something there at the end :D