Bemutatkozik: 

Prezi AI.

Az Ön új prezentációs asszisztense.

Minden eddiginél gyorsabban finomíthatja, fejlesztheti és szabhatja testre tartalmait, találhat releváns képeket, illetve szerkesztheti vizuális elemeit.

Betöltés...
Átirat

HOWTO

Use Cases

Concepts

Details

Error types

Clone it, run it

Comments on file parser policies

Try it out, tune it and master it!

Take control

over creeping FIXMEs

Pycrastiwhat!?

1) Search code for FIXMEs*

2) Filter >90 and <15 days old

3) Email report to assess severity

Add exclude and send_email modules

Avoid bad practices

breaking Continuous Integration builds

1) Search public API for kwargs*

2) Filter >180 days old

3) Raise `AssertionError`

Add raise_if_present and filter_by_age modules

Code cleanup

remove TODOs from an old stable codebase

1) Search for TODOs, XXXs, HACKs...

2) Filter out those <6 months old*

3) Email reports to committers

with "1-click-distance" links

New pipeline: gather_git_blames_shell,

aggregate_by, and send_aggregated_email modules

Find, act and analyse TODOs & co.

Pipeline

: "chain of processing elements arranged so that the output of each element is the input of the next" - en.wikipedia.org

Find & Extract

file paths

1. Gather files

2. Inspect files

line meta.

4. Filter

3. Extract more metadata

+ addition.

line meta.

Act & Analyse

(subset)

Avoid bad practices

line metadata

5. Trigger actions

6. Aggregate

report

7. Create report

8. Deliver/notify/etc.

config.py

pycrastinate.py

*. Process results

Why I hunt TODOs

Code cleanup

Definition

WTF is a "TODO"?

Analogy: What's a python function?

Modern C++: What You Need to Know - April 3, 2014 - Herb Sutter

source: http://channel9.msdn.com/Events/Build/2014/2-661

(at 10:48)

Why use pycrastinate?

a summary of key arguments

Pycrastinate

TODO less, DO more

by

Isaac Bernat

May 20 - 2014

github.com/isaacbernat

TODO: ask for questions

Bonus slides

Modules

Enclose

gather_git_blames_shell

"one-liner"

Pycrastinate

by

Isaac Bernat

TODO less, DO more

May 20 - 2014

Modules ordered by priority

Initial results

failure to reject a false H0

(false -)

  • Type II
  • Convenience

Use it out of the box. No weird formats.

  • Speed

(django)

<3.5 sec. >240k lines, >1.7k .py, >60 hits

found 2 TODOs from 2006 (!)

Modules called

through enclose

  • No setups

The only dependency is python 2.7/3.3+

(false +)

incorrect rejection of a true H0

  • Type I
  • Modularity

Easily extensible to meet your needs.

(H0)

  • Null hypothesis

no relation found

  • Chosen policy

alpha >= 0, beta = 0

(like bloom filters)

source: http://en.wikipedia.org/wiki/Type_I_and_type_II_errors

TODOs are jobs that the programmer thinks should be done, but for some reason can’t do at the moment. [...]

Whatever else a TODO might be, it is not an excuse to leave bad code in the system.

source: Robert C. Martin, “Clean Code – A Handbook of Agile Software Craftsmanship”

Tudjon meg többet arról, hogyan készíthet dinamikus és magával ragadó prezentációkat a Prezi segítségével