Introduction to Python and Django

30 Ratings

Course Number: DGO-106
Duration: 5 days (32.5 hours)
Format: Live, hands-on

Python and Django Training Overview

Accelebrate's Introduction to Python and Django training course starts by teaching students the basics of Python, then moves on to teach students how to develop Web applications using the Django framework. This class covers the basics of creating basic applications using the MVC (model-view-controller) design pattern, as well as more advanced topics such as administration, session management, authentication, and automated testing.

Note: This course can be taught with Django 4.x or later on compatible versions of Python (as documented in the earliest release notes for your general Django release [1.11, 2.0, etc.]. See the Django Release Notes here.

Location and Pricing

Accelebrate offers instructor-led enterprise training for groups of 3 or more online or at your site. Most Accelebrate classes can be flexibly scheduled for your group, including delivery in half-day segments across a week or set of weeks. To receive a customized proposal and price quote for private corporate training on-site or online, please contact us.

In addition, some courses are available as live, instructor-led training from one of our partners.

Objectives

  • Develop full-stack web sites based on content stored in an RDMS
  • Use python data types appropriately
  • Define data models
  • Understand the architecture of a Django-based web site
  • Create Django templates for easy-to-modify views
  • Map views to URLs
  • Take advantage of the built-in Admin interface
  • Provide HTML form processing

Prerequisites

Students should already be comfortable using the operating system (Linux, Unix, Windows, Solaris, macOS, etc.) on which they will be running Python. While not mandatory, basic skills with at least one other programming language are desirable. All students should have a working knowledge of HTML5 and CSS.

Outline

Expand All | Collapse All

Introduction
The Python Environment
  • Starting Python
  • Using the interpreter
  • Running a Python script
  • Python scripts on Unix/Windows
  • Editors and IDEs
Getting Started
  • Using variables
  • Built-in functions
  • Strings
  • Numbers
  • Converting among types
  • Writing to the screen
  • Command line parameters
Flow Control
  • About flow control
  • White space
  • Conditional expressions
  • Relational and Boolean operators
  • While loops
  • Alternate loop exits
Lists and Tuples
  • About sequences
  • Lists and list methods
  • Tuples
  • Indexing and slicing
  • Iterating through a sequence
  • Sequence functions, keywords, and operators
  • List comprehensions
  • Nested sequences
Working with Files
  • File overview
  • The with statement
  • Opening a text file
  • Reading a text file
  • Writing to a text file
  • Raw (binary) data
Dictionaries and Sets
  • About dictionaries
  • Creating dictionaries
  • Iterating through a dictionary
  • About sets
  • Creating sets
  • Working with sets
Functions
  • About sequences
  • Function parameters
  • Global variables
  • Global scope
  • Returning values
  • Sorting data
Errors and Exception Handling
  • Syntax errors
  • Exceptions
  • Using try/catch/else/finally
  • Handling multiple exceptions
  • Ignoring exceptions
Using Modules
  • The import statement
  • Module search path
  • Zipped libraries
  • Creating Modules
  • Function and Module aliases
Classes
  • About o-o programming
  • Defining classes
  • Constructors
  • Instance methods and data
  • Class/static methods and data
  • Inheritance
Django Architecture
  • Sites and apps
  • Shared configuration
  • Minimal Django layout
  • Built-in flexibility
Configuring a Project
  • Executing manage.py
  • Starting the project
  • Database setup
  • The development server
Adding an Application
  • Generate the application files
  • Defining models
  • Related objects
  • SQL Migration
  • App configuration
  • Accessing models
Login for Nothing and Admin for free
  • Setting up the admin user
  • Running the admin site
  • Tweaking the admin interface
  • Changing the admin index page
Basic Views (AKA Controllers)
  • What is a view
  • HttpResponse
  • URL route configuration
  • Shortcut: get_object_or_404()
Basic Views (AKA Templates)
  • About templates
  • Django template syntax
  • Static files
  • Loading templates
  • The url tag
  • Shortcut: template.render()
Querying the Models
  • QuerySets
  • Field lookups
  • Chaining filters
  • Slicing QuerySets
  • Related fields
  • Q objects
Working with Templates
  • Variable lookups
  • Comments
  • Inheritance
  • Filters
  • Escaping HTML
  • Custom filters
Forms
  • Forms overview
  • GET and POST
  • The Form class
  • Processing the form
  • Widgets
  • Validation
  • Forms in templates
  • Beyond the basics
Automated Testing
  • Why create tests?
  • When to create tests
  • Using Django's test framework
  • Using the test client
  • Running tests
  • Checking code coverage
Conclusion

Training Materials

All attendees receive comprehensive course materials.

Software Requirements

  • Python 3.x installed (Anaconda bundle recommended)
  • Django 4.x or later framework
  • Other Python modules installed
  • A text editor or IDE (PyCharm Community Edition is an excellent free editor if you don’t have a strong preference)


Learn faster

Our live, instructor-led lectures are far more effective than pre-recorded classes

Satisfaction guarantee

If your team is not 100% satisfied with your training, we do what's necessary to make it right

Learn online from anywhere

Whether you are at home or in the office, we make learning interactive and engaging

Multiple Payment Options

We accept check, ACH/EFT, major credit cards, and most purchase orders



Recent Training Locations

Alabama

Birmingham

Huntsville

Montgomery

Alaska

Anchorage

Arizona

Phoenix

Tucson

Arkansas

Fayetteville

Little Rock

California

Los Angeles

Oakland

Orange County

Sacramento

San Diego

San Francisco

San Jose

Colorado

Boulder

Colorado Springs

Denver

Connecticut

Hartford

DC

Washington

Florida

Fort Lauderdale

Jacksonville

Miami

Orlando

Tampa

Georgia

Atlanta

Augusta

Savannah

Hawaii

Honolulu

Idaho

Boise

Illinois

Chicago

Indiana

Indianapolis

Iowa

Cedar Rapids

Des Moines

Kansas

Wichita

Kentucky

Lexington

Louisville

Louisiana

New Orleans

Maine

Portland

Maryland

Annapolis

Baltimore

Frederick

Hagerstown

Massachusetts

Boston

Cambridge

Springfield

Michigan

Ann Arbor

Detroit

Grand Rapids

Minnesota

Minneapolis

Saint Paul

Mississippi

Jackson

Missouri

Kansas City

St. Louis

Nebraska

Lincoln

Omaha

Nevada

Las Vegas

Reno

New Jersey

Princeton

New Mexico

Albuquerque

New York

Albany

Buffalo

New York City

White Plains

North Carolina

Charlotte

Durham

Raleigh

Ohio

Akron

Canton

Cincinnati

Cleveland

Columbus

Dayton

Oklahoma

Oklahoma City

Tulsa

Oregon

Portland

Pennsylvania

Philadelphia

Pittsburgh

Rhode Island

Providence

South Carolina

Charleston

Columbia

Greenville

Tennessee

Knoxville

Memphis

Nashville

Texas

Austin

Dallas

El Paso

Houston

San Antonio

Utah

Salt Lake City

Virginia

Alexandria

Arlington

Norfolk

Richmond

Washington

Seattle

Tacoma

West Virginia

Charleston

Wisconsin

Madison

Milwaukee

Alberta

Calgary

Edmonton

British Columbia

Vancouver

Manitoba

Winnipeg

Nova Scotia

Halifax

Ontario

Ottawa

Toronto

Quebec

Montreal

Puerto Rico

San Juan