- Instances vs. classes
- Initializers
- Data and methods
- Practice time
- Continue class overview
- Discuss encapsulation of state and behavior
- Work on Vehicle class both as a class and individually
- Vehicle class
- Takes mpg and gasoline gallons in tank
- Methods are drive and fill-up. Both alter how much gas there's in the tank.
- Practice: add odometer
- Homework: Driving more than you can raises an exception
- Discuss a class we've used before, such as
Flaskordict
- Start of Classes unit (Nephi)
- Types we already know
- Making custum types
- Data and methods
- Syntax of classes
- Instances vs. classes
- Review of Ceaser Cipher assignment (Marcos)
- Remind students of Caesar Cipher assignment, show stubbing example
- Continue Error handling unit (Brady)
- Call stacks
- Stack traces
- Debugging
- Structuring and desinging code
- Throw
- KeyError, IndexError
- Start of Error handling unit (Nephi)
- Exceptions, try/catch
- Continue review of execution model (Marcos)
- Project walkthrough (Nephi)
- Finish File IO and encoding practice (Brady)
- Review of execution model (Marcos)
- Remind students of assignments
- File IO and encoding review
- Continue File IO unit
- Reading, writing, closing Files with Python
- Python File operations
- Serializing data with Python
- File open modes (read, write, append, truncate)
- Beginning of File IO unit
- What is a file?
- Why store data in files
- Encoding/serialization, JSON
- Reading data from disk, hexdump
- Reading, writing, closing Files with Python
- HTTP request basics, request methods, request body
- Specifying request method in Flask routes
- Using request body data in Flask routes
- Making HTTP requests with Python and
curl
- Project day, menu building website, we'll provide students with the function they'll need to read/write menu data from a file
- Review of URL's and query parameters
- Review of HTTP focusing on GET requests
- The request Class and how it maps over to http fields
- Query parameters and
request.args - Forms/user input and
request.form
- Install Live Share plugin
- Personal Website and Rock Paper Scissors Flask application due by next Thursday for those who have not submitted the assignment they worked on.
- Formatted strings
- Templates and merge fields
- Full HTML responses
- Homework: convert Personal Website or RPS to use templates
- Remind students about reading assignment
- Show and tell: have students present their code from Monday
- URLs, domain routing and Flask routing
- Links, absolute and relative URLs
- Practice day. Work on either Personal Page or Rock Paper Scissors Flask application.
- Build countries website with at least two pages (routes), and full HTML
responses. Use breakout rooms of 2 or 3 people.
- Pick country
- Homepage will be a overview of the country, with images to the flag and a map
- Second page will be about anything you'd like but must be linked to from the homepage.
- Assign Personal Page assignment.
- Stretch goal: discuss and/or assign Flask templates reading
- Build a simple app (reintroduce flask, show working example)
- Get a server running the app (ngrok/render)
- Show ability to pass functions into functions (decorators)
- Show 404 error (no routes)
- We use their ip addresses that everyone can connect to show their website
- If network doesn't work, use hotspot
- Explain URLs
- Show how URLs and ip addresses relate
- URL gets you to the machine, other parts get you to the code
- Show them how routes work
- They build jokes app
- Create Simple route
- (Stretch) use url parsing to select joke in list
- (Stretch) Return some html
- (Filler) Roadmap.sh
- Review previous assignments, calculate total and print comma separated list
- Show https://roadmap.sh/
- Show https://exercism.org
- URLs and routing/routes
- Parsing a URL into parts,
from urllib.parse import urlparse - Talk about how the internet routes a URL
- Finish dictionaries lesson
- Iterating dictionaries example: drivers high score search
- Intro to Flask, web programming, The Internet
- Show sample Flask application
- Continue dictionaries lesson
- Show RPS example
- Go over how a line of code is evaluated
- Start dictionaries lesson
- We made it to right before the "Dictionary operations" slide
- Continue review
- Follow up on RPS homework, class coding practice
- Instructor intros (5min)
- Student intros (20min)
- Go over syllabus (20min)
- Review, remainer of the class (~45min)
- Assign RPS homework