Skip to content

add example to collaborative github chapter #40

@jhidding

Description

@jhidding

The example is about implementing a temperature conversion library in Python. I think this example was by Barbara in the code refinery lesson.

Create a git[hub|lab] repository with a README and a LICENSE explaining shortly what those files are about. Add the opponent as a collaborator on the project.

Start by Googling the correct conversion. Write a Python code that works but is obviously faulty.

# file: temperature.py
def convert(t):
    return (t - 32) * 5/9

Have the opponent write an issue. There are several things that could be raised:

  • No docstring
  • Not clear which direction we're converting

Solve the issue by creating a branch and editing the temperature.py file. However, leave some obvious flaw, as to create some dialogue in the PR.

Create a feature request for the inverse conversion (Celcius to Fahrenheit), assign the opponent. Meanwhile, add a function for converting between celcius and kelvin in the main branch. This will create a merge conflict that we can resolve before merging.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions