Debugging ScratchJr ProjectsActivities & Teaching Strategies
Children learn debugging best by doing it, not just watching. When Year 2 pupils actively hunt for and fix bugs in ScratchJr, they connect problem-solving to real steps they can see and change. This hands-on practice builds logical thinking and resilience because each small fix makes the program work as intended.
Learning Objectives
- 1Identify the specific block in a ScratchJr script that causes a sprite to behave unexpectedly.
- 2Explain, using precise language, why a sprite did not move as planned in a ScratchJr project.
- 3Demonstrate how to test a ScratchJr script block by block to isolate a programming error.
- 4Modify a ScratchJr script to correct a bug and make a sprite perform the intended action.
Want a complete lesson plan with these objectives? Generate a Mission →
Pair Debug Challenge: Sprite Path Fix
Provide pairs with a ScratchJr project where a sprite takes a wrong path. One pupil predicts the run, the other tests block by block and notes differences. They discuss, fix one block, and retest before swapping roles.
Prepare & details
Identify what went wrong when a sprite does not move as you planned.
Facilitation Tip: During Pair Debug Challenge, move between pairs to listen for clear descriptions of the bug and the fix before they change any blocks.
Setup: Presentation area at front, or multiple teaching stations
Materials: Topic assignment cards, Lesson planning template, Peer feedback form, Visual aid supplies
Bug Hunt Relay: Small Group Edition
Divide class into small groups. Project three buggy scripts; groups race to identify one error per script by testing on tablets. Each pupil records the wrong behaviour and suggested fix on a group sheet.
Prepare & details
Explain why your sprite did not move the way you expected, and describe the step you changed to fix it.
Facilitation Tip: In Bug Hunt Relay, time each small group’s turn so they focus on testing a single block sequence rather than rushing through the whole script.
Setup: Presentation area at front, or multiple teaching stations
Materials: Topic assignment cards, Lesson planning template, Peer feedback form, Visual aid supplies
Step-by-Step Solo Tester: Motion Bugs
Pupils load a personal project with planted errors. They run the full script, then test blocks singly, circling the problem block and writing one sentence on the fix before running again to check.
Prepare & details
Show how to test your ScratchJr script one block at a time to find which block caused the problem.
Facilitation Tip: For Step-by-Step Solo Tester, provide printed block icons so pupils physically move them to retest logic without touching the screen.
Setup: Presentation area at front, or multiple teaching stations
Materials: Topic assignment cards, Lesson planning template, Peer feedback form, Visual aid supplies
Whole Class Debug Demo: Story Fail
Show a class story project that glitches. Pupils call out predictions, vote on problem blocks, then watch step-by-step testing. Class suggests and tests one collective fix.
Prepare & details
Identify what went wrong when a sprite does not move as you planned.
Facilitation Tip: In Whole Class Debug Demo, pause after each fix to ask the class what words they would use to describe the mistake to a friend.
Setup: Presentation area at front, or multiple teaching stations
Materials: Topic assignment cards, Lesson planning template, Peer feedback form, Visual aid supplies
Teaching This Topic
Teachers should model slow, verbal debugging while thinking aloud. Avoid rushing to solutions because that teaches pupils to guess rather than test. Use consistent language like ‘expected behavior’ and ‘actual behavior’ to build a shared vocabulary. Research shows young children debug more effectively when they can physically manipulate blocks and see immediate effects, so pair on-screen testing with off-screen planning.
What to Expect
By the end of these activities, pupils will confidently identify incorrect blocks, explain why they cause errors, and apply targeted fixes. They will explain their debugging steps to peers and self-check their work before sharing finished projects.
These activities are a starting point. A full mission is the experience.
- Complete facilitation script with teacher dialogue
- Printable student materials, ready for class
- Differentiation strategies for every learner
Watch Out for These Misconceptions
Common MisconceptionDuring Pair Debug Challenge, watch for pupils who restart the whole project instead of isolating the error.
What to Teach Instead
Remind pairs to use the printed block reference sheet to mark each tested block with a sticker, showing progress one block at a time.
Common MisconceptionDuring Bug Hunt Relay, watch for pupils who assume the last added block is always the problem.
What to Teach Instead
Have the group physically reorder their tested blocks on the sheet to prove that early blocks can fail too, reinforcing thorough checking.
Common MisconceptionDuring Step-by-Step Solo Tester, watch for pupils who change blocks without explaining why the original block failed.
What to Teach Instead
Ask each pupil to write a one-sentence explanation on a sticky note before they touch the screen, using the words ‘expected’ and ‘actual’.
Assessment Ideas
After Pair Debug Challenge, hand out a half-sheet with a sprite moving in a square. Ask pupils to circle the bug, name the faulty block, and draw the correct path on the sheet.
During Bug Hunt Relay, circulate with a clipboard holding a simple chart. Tally how many pupils correctly identify the bugging block on their first test and how many needed a second try.
After Whole Class Debug Demo, display a new script on the screen. Ask the class to raise hands to share one word describing the bug and one fix, using the language modeled during the activity.
Extensions & Scaffolding
- Challenge: Ask faster finishers to add a second bug to their partner’s project and document the fix steps for the original pair.
- Scaffolding: Provide a checklist with pictures of common blocks and tick boxes for ‘Did you test this block?’ to guide struggling pupils.
- Deeper exploration: Invite pairs to create their own mini-project with exactly three bugs, then swap with another pair to debug.
Key Vocabulary
| Bug | A mistake or error in a computer program that causes it to behave incorrectly. |
| Debugging | The process of finding and fixing errors, or bugs, in a computer program. |
| Script | A sequence of instructions, represented by blocks, that tells a sprite what to do in ScratchJr. |
| Sprite | A character or object in a ScratchJr project that can be programmed to move and interact. |
Suggested Methodologies
More in Creative Programming with ScratchJr
Exploring the ScratchJr Interface
Familiarizing students with the ScratchJr environment, sprites, and backgrounds.
2 methodologies
Sequence and Events in ScratchJr
Learning how to start a program using events like the green flag and connecting blocks in order.
2 methodologies
Motion and Movement Blocks
Using motion blocks to make sprites move, turn, and jump.
2 methodologies
Looks and Sound Blocks
Changing sprite appearance, adding speech bubbles, and incorporating sounds.
2 methodologies
Ready to teach Debugging ScratchJr Projects?
Generate a full mission with everything you need
Generate a Mission