2 - Dev Env Flashcards

1
Q

What are good setting up practises of software engineering?

A

Version Control

Package Manager

Virtual Environment

IDE

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Why use VCS?

A

Access older copies

Simplifies concurrent work

Merge changes

Track different versions and releases

Work is backed up

Exploratory work - branching

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What are advantages to using Virtual Environments?

A

Use different package sets for different projects

Use different python versions for different projects

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Topdown vs bottom up (topdown)

A

Separates the low level work from the higher level abstractions

Leads to a modular design

Development can be self- contained (tiered)

Emphasizes planning and system understanding

Coding is late, and Testing is even later

Skeleton code can show how everything integrates

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Topdown vs bottom up (bottom up)

A

Coding begins early and so Testing can be performed early

Requires really good intuitions to determine functionality of modules

Low level design decisions can have major impact on solutions

Risks integration problems – how do components link together

Often used to add on to existing modules

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is a typical High Level System Architecture diagram?

A

User Client Middlware Database

Must work out what will be built and what tech goes into teach part

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is Django?

A

High level Python web framework for rapid development and clean pragmatic design

For perfectionists with deadlines

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is the focus of Django?

A

Dynamic and database driven websites

Content based websites (e.g. eBay, Guardian, Twitter)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What are some Django modules?

A

Administration Interface (CRUD)

Authentication Systems

Form handling

Session handling

Syndication Frameworks (RSS and Atom)

Caching

Internationalisation and Localisation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

How is Model View Controller used in Django?

A

Models describe the database

Views determine what the user sees

Controlled is handled by Django framework, URL parser maps URLs to views

Templates describe how data is presented - MVCT

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Django Internal Flow

A

Client

Django/Middlware
{
    Template            URLS
    Views
    Models                Wrapper
}

Backend
{
Database Services
}

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Django - Controlling flow

A

Usually in urls.py

Which view should handle which URL (or part of URL) - URL patterns used to find matches and route request to view

Pattern matching means different instantiations can be used by a common pattern

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Django - Defining views

A

Usually in views.py

Views are responsible for handling and processing specific requests, getting data from databases/external services and selecting template to use for response

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Django - Providing templates

A

Templates mean response format (html, xml, etc.) is decoupled from data to be presented

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Django - Building data models

A

Usually in models.py

Models specify entities and relationships in database - these provide Object Relational Mapping (ORM) to actual database tables

Framework constructs the database given the models defined

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Why Django for web dev?

A

Can divide code modules into logical groups
- Gives flexibility and ease to change things

Provides automatically generated web admin, making it easy to manage database

Provides many pre-packages APIs for common tasks

Template system for HTML pages
- Avoids code duplication, follows DRY principle

Define URL for a given view
- Loosely Coupled Principle

Allows separation of business logic from presentation
- Separation of concerns

17
Q

What is the design philosophy of Django?

A

Loose coupling

Less code

Quick development

Don’t Repeat Yourself (DRY)

Explicit is better than implicit (core Python principle)

Consistency