How to work together on software Andy Green · MacHg SourceTree GUI Client. Tracking Changes Small...

27
How to work together on software Andy Green

Transcript of How to work together on software Andy Green · MacHg SourceTree GUI Client. Tracking Changes Small...

  • How to work together on software

    Andy Green

  • 70 galaxies

    ~50,000 spectra

    ~2500 code lines

    4 years

    1 PhD student

    The Old Paradigm

  • 3400 galaxies

    ~8 million spectra

    5 years

    >80 people

    few terabytes

    spatially resolved datacubes

  • Freely available, open source(can be) Easy to read

    Widely adoptedBenevolent Dictatorship

    Interfaces readily with C/C++

    I’d never used it before

  • Concurrent Versioning System

  • Concurrent Versioning System

  • Concurrent Versioning System

    Centralised Server

  • Concurrent Versioning System

    MacHg SourceTree

    GUI Client

  • Tracking Changes

    Small Large

  • Tracking Changes

    Commit message repository

    Small

    Replaced circ.py with cCirc.py, which is the C version of the same code.

    Approximate speedup is 6-8x. To achieve this, the user must compile the library, which can be done by running "make" in the utils directory. If the library has not been compiled, it falls back to the original version.

    Large

  • Tracking Changes

    Commit message repository

    Design Note

    Small

    Replaced circ.py with cCirc.py, which is the C version of the same code.

    Approximate speedup is 6-8x. To achieve this, the user must compile the library, which can be done by running "make" in the utils directory. If the library has not been compiled, it falls back to the original version.

    Large

  • Maintainers and Code Review

    Gatekeepers to the codebase

    Linus Torvalds

  • Maintainers and Code Review

    Gatekeepers to the codebase

    Linus Torvalds

    Trusted Maint

    Trusted Maint

    Trusted Maint

  • Maintainers and Code Review

    Gatekeepers to the codebase

    Linus Torvalds

    Trusted Maint

    Trusted Maint

    Trusted Maint

    Dev 10

    Dev 11

    Dev 12

    Dev 13

    Dev 14

  • Mai

    n br

    anch

    Maintainers and Code Review

  • Minor Bug Fix (Jane)

    Mai

    n br

    anch

    Maintainers and Code Review

  • New Feature (Tim)

    Minor Bug Fix (Jane)

    Mai

    n br

    anch

    New

    feat

    ure

    bran

    ch

    Maintainers and Code Review

  • New Feature (Tim)

    Minor Bug Fix (Jane)

    Bug Fix (Tim)

    Testing (Tim)

    Mai

    n br

    anch

    New

    feat

    ure

    bran

    ch

    Maintainers and Code Review

  • New Feature (Tim)

    Minor Bug Fix (Jane)

    Bug Fix (Tim)

    Testing (Tim)

    Ready for Review (Tim)M

    ain

    bran

    ch

    New

    feat

    ure

    bran

    ch

    Maintainers and Code Review

  • New Feature (Tim)

    Minor Bug Fix (Jane)

    Bug Fix (Tim)

    Testing (Tim)

    Ready for Review (Tim)M

    ain

    bran

    ch

    New

    feat

    ure

    bran

    ch

    FOR REVIEW

    Maintainers and Code Review

  • New Feature (Tim)

    Minor Bug Fix (Jane)

    Bug Fix (Tim)

    Testing (Tim)

    Ready for Review (Tim)

    Reviewed (John)

    Mai

    n br

    anch

    New

    feat

    ure

    bran

    ch

    FOR REVIEW

    Maintainers and Code Review

  • New Feature (Tim)

    Minor Bug Fix (Jane)

    Bug Fix (Tim)

    Testing (Tim)

    Ready for Review (Tim)

    Reviewed (John)

    Merge (John)

    Mai

    n br

    anch

    New

    feat

    ure

    bran

    ch

    FOR REVIEW

    Maintainers and Code Review

  • New Feature (Tim)

    Minor Bug Fix (Jane)

    Bug Fix (Tim)

    Testing (Tim)

    Ready for Review (Tim)

    Reviewed (John)

    Merge (John)

    Mai

    n br

    anch

    New

    feat

    ure

    bran

    ch

    FOR REVIEW

    Maintainers and Code Review

  • Unit Testing

    A piece of code which tests the validity of an algorithm or

    function.

    Provides random or predetermined inputs and checks outputs match

    expectations.

    Provides evidence that the software works as intended.

  • data-reduction pipeline alone:

    8+ months of work400+ commits

    10,178 lines of codeComment-to-code ratio: 0.41