Software Carpentry
Syllabus

Introduction: introduction, self assessment, scientific programming today, comparison with experimental science, comparison with industry, solutions, changes on the horizon, course content, what you will need, open source vs. commercial tools, contributing, recommended reading, typographic conventions, summary.

Shell Basics: introduction, the shell, shell vs. operating system, file system, absolute and relative paths, basic navigation commands, command execution cycle, command flags, creating files and directories, basic tools, summary.

More Shell: introduction, wildcards, input, output, and redirection, pipes, environment variables, configuration, the PATH variable, file ownership and permissions, directory permissions, changing permissions, Windows ownership and permission, some more advanced tools, summary.

Version Control: introduction, collaboration, version control systems, choosing a version control system, basic operations, command line and GUI clients, resolving conflicts, starvation, binary files, reverting, rolling back, creating repositories and checking out working copies, Subversion command reference, reading Subversion output, summary.

Automated Builds: introduction, build tool requirements, introducing Make, basic features, structure of a Makefile, handling multiple targets, defining phony targets, dependencies, updating dependencies, conventions, automatic variables, pattern rules, dependencies once again, macros, getting information from the outside world, functions, pros and cons, alternatives, summary.

Basic Scripting: motivation, Python's Strengths, Python's Weaknesses, why Python?, sturdy vs. nimble execution cycle, running Python, shortcuts, variables, printing, quoting, converting values to strings, escape sequences, numbers, arithmetic, Booleans, short-circuit evaluation, comparisons, conditionals, why indentation?, while loops, break and continue, string formatting, format specifiers, supported formats, summary.

Strings, Lists, and Files: introduction, strings, slicing, bounds checking rules, negative indices, methods, string methods, chaining method calls, membership, lists, modifying lists, concatenation, deletion, list methods, for loops, ranges, list membership, nesting lists, aliasing, tuples, multi-valued assignment, unpacking structures loops, file I/O, file I/O example, looping over files, summary.

Functions and Libraries: introduction, defining functions, returning values, variable scope, aliasing, default parameter values, functions are objects, function attributes, creating modules, module scope, other ways to import, import executes statements, the __name__ variable, system library, command-line arguments, standard I/O, search path, exiting the program, math library, file system programming, file and directory status, The os.path Module, summary.

Style: why read code, cognition, Python style guide, naming, scope and size, example, function length, determining functionality, reading techniques, idioms, style-checking tools, documentation, traceability, embedding documentation, docstrings.

Quality Assurance: introduction, limits to testing, terminology, test results and specifications, structuring tests, simple example, try and except, simple exception example, exceptions, exception hierarchy, exception handler stack, raising exceptions, when and how to use exceptions, handling errors in tests, test-driven design, design by contract, assertions, defensive programming, summary.

Sets, Dictionaries, and Complexity: introduction, sets, set operations, example, implementation and implications, why set elements must be immutable, frozen sets, language design, quantifying efficiency, algorithmic complexity, motivating dictionaries, working with dictionaries, dictionary methods, counting frequency, ordering, inverting, dictionary string formatting, variable-length argument lists, summary.

Debugging: introduction, what's wrong with print statements, symbolic debuggers, debugger features, kinds of debuggers, integrated development environments, command-line debuggers, inspecting values, controlling execution, how debuggers work, implementing breakpoints, advanced operations, logging, logging levels, logging example, Agans' Rules, get it right the first time, what is it supposed to do?, is it plugged in?, make it fail, divide and conquer, change one thing at a time, write it down, be humble, summary.

Object-Oriented Programming: introduction, abstract data types, terminology, a simple class, methods, members, encapsulation, constructors, constructor style, special methods, inheritance, inheritance example, overriding methods, polymorphism, duck typing, Liskov substitution principle, ecosystem example, CRC cards, summary.

More on Objects: introduction, overriding built-in functions, operator overloading, right-hand and left-hand operators, other special methods, sparse vectors, semantics of vector length, vector behavior, dot product, addition, testing, static data members, static methods, design patterns, singleton pattern, visitor pattern, abstract factory pattern, command pattern, other patterns, summary.

Unit Testing: introduction, unit testing frameworks, big picture, implementing checks, simple example, running sum example, cost effectiveness, setup and teardown, testing exceptions, testing I/O, stubs and mock objects, test performance, choosing tests, rectangle overlap example, what to test first, summary.

Regular Expressions: matching constant strings, matching alternatives, precedence, escaping special characters, raw strings, sequences, optional elements, character sets, common abbreviations, special cases, anchors, extracting matches, match objects, match groups, compiled REs, finding all matches, other patterns, summary.

Binary Data: introduction, why use binary, representing numbers, two's complement, bitwise operators, shifting, setting and clearing bits, bit flags, floating point numbers, floating point spacing, floating point roundoff, binary I/O, binary I/O mode, packing data structures, packing, unpacking data, struct module, hexadecimal characters, format specifiers, calculating sizes, endianness, variable-length data, dynamic formats, metadata, metadata file structure, summary.

XML: introduction, history, formatting rules, text, XHTML, critique, attributes, when to use attributes, more XHTML tags, lists and tables, images, links, DOM, basic features of DOM, DOM tree example, creating a DOM tree, converting to text, other ways to create documents, details, finding nodes, walking a DOM tree, modifying a DOM tree.

Relational Databases: history, when to use a database, experimental data example, Using SQL, creating tables, inserting data, simple selection, sorting, selection, joins, ID translation example, keys and constraints, eliminating duplicates, aggregation, grouping, self joins, null, database design, nested queries, nested query example, further examples, application programming, Python database example, concurrency, transactions, transaction example, using transactions, testing, advanced topics, summary.

Spreadsheets: introduction, getting started, entering data, formatting data, formulas, replicating formulas, built-in functions, commonly-used functions, dependencies, conditionals, lookup tables, lookup table example, absolute references, larger data set, creating charts, customizing charts, creating a log-log chart, analysis, programming spreadsheets, summary.

Integration: introduction, running external programs, subprocess module, running in place, running with arguments, capturing output, providing input, deadlock, pros and cons, integrating C into Python, Python object structure, calling conventions, boilerplate, loading and calling, wrapping C++, SWIG, Embedding Python in C, loading modules, plugin frameworks, manual loading, application, namespaces, summary.

Web Client Programming: introduction, component object models, concurrency, partial failure, underlying protocols, sockets, client/server vs. peer-to-peer, socket client example, socket server example, HTTP, HTTP request line, HTTP headers, HTTP body, HTTP response, HTTP example, urllib, urllib example, building a spider, parameterizing requests, URL encoding, encoding example, screen scraping, web services, Amazon example.

Web Server Programming: introduction, motivation for CGI, CGI, passing information to the CGI, passing information back, MIME types, basic CGI, invoking the basic CGI, generating dynamic content, forms, creating forms, example form, parameter names, handling form data, form handling example, development tips, server-side state, maintaining state in files, HTML templating, concurrency, file locking, the problem of state, cookies, creating cookies, cookie example, cookie tips.

Security: introduction, goals, limitations of technical solution, terminology, risk assessment, cataloguing attacks, example attack, leaking information, SQL injection, default settings and denial of service, phishing, attacking data entry, timed attacks, secure HTTP, basic cryptography, public-key cryptography, public-key cryptography in action, digital signatures, securing login, other areas of insecurity.

The Development Process: introduction, design vs. agility, project lifecycle, vision statement, gathering requirements, from requirements to features, waterfall model, spiral model, Extreme Programming, analysis & estimation, time estimates, A&E format, reviews, prioritization, scheduling, science fiction scheduling, development, tracking progress, burn rate, winding up, post mortem, summary.

Teamware: motivation, DrProject architecture, event log, weblogs, repository browser, mailing lists, whitelisting mail addresses, issue tracker, creating and viewing tickets, ticket guidelines, writing useful tickets, updating tickets, roadmap and milestones, priorities and triage, more complex workflows, wiki, wiki syntax, editing wiki pages, wiki links, rules of the road.

Backward, Forward, and Sideways: introduction, classic mistakes, branching, merging, and tagging, creating patches, SCons, SCons example, persistence, pickling example, object-relational mapping, web development frameworks, refactoring, refactoring examples, refactoring tools, code reviews, reading code, code review checklist, UI design, paper prototyping, more reading, rules of programming.