UAT 104 Computer Programming

Worksheet 5 A team mini-project with Git

Lab 6 hAssesses CLO3, CLO1

Objective

Translate a block program into tested Python and combine the team's work in a repository with GitHub flow

Equipment and materials

  • Computer with Python and Git
  • Students' GitHub accounts
  • Hula block reference and five-level examples
  • Hula drone and an indoor flying area (if available)

Safety

  • Never commit passwords, tokens or secrets; add .gitignore in the first commit
  • Fly the Hula drone only in a safe area under the instructor's supervision; keep people clear
  • Check batteries before flight and disconnect them when not in use

Steps

  1. Choose one Hula example from levels 2–4
  2. Translate it to Python with SimDrone
  3. Write tests confirming the route closes or turns fully as intended
  4. Create the group repository with .gitignore and bring in files from modules 2 to 4
  5. Each member branches, opens a pull request and reviews at least one teammate's work
  6. If a Hula drone is available, fly the original block program and compare with simulation

Record of results

Table 1 Block program translated to Python
Hula blockPython statementValue usedNote
Table 2 Simulated and real flight results
Shape {n/k}Turn (deg)Total distance (cm)Total turn (deg)Back at start?Real flight (if done)
Table 3 Team work in the repository
MemberBranch nameCommit messagePull request reviewed

Questions

  1. How does your group's test confirm that the route closes or turns fully? If the shape changed from {5/2} to {6/2}, would the same test pass, and why?

  2. If the real drone does not return exactly to its start as in the simulation, what could cause it, and what does SimDrone not model?

  3. Which commit message in Table 3 best says what changed, and which should be rewritten following Conventional Commits?

  4. If a member accidentally commits a .env file holding an API key, what must the team do, in order, and why is deleting the file in the next commit not enough?

Check before you hand in

What to hand in

  • Repository link with every member's commits
  • Python code and passing tests
  • Pull requests and reviews
  • Notes comparing real flight with simulation (if done)

CLO3 Use Git and collaborative coding practices. CLO1 Write structured Python programs to solve technology problems. (CLOs are a web-team draft; the course owner sets the final ones.)

Instructors: answers and teaching notes for this worksheet are in the teaching pack