Skip to content

Add usage message when script is run without arguments#1

Open
sauravkeshrii wants to merge 1 commit intoblackcoffeerobotics:masterfrom
sauravkeshrii:fix-usage-message
Open

Add usage message when script is run without arguments#1
sauravkeshrii wants to merge 1 commit intoblackcoffeerobotics:masterfrom
sauravkeshrii:fix-usage-message

Conversation

@sauravkeshrii
Copy link

@sauravkeshrii sauravkeshrii commented Feb 12, 2026

Status

READY

Migrations

NO

Description

Added argument validation and a usage message to world_create.py. Previously, running the script without any arguments would crash with an IndexError. Now it prints instructions and exits cleanly.

Todos

  • Tests
  • Documentation

Deploy Notes

No special deployment steps. This change only affects the script's command-line interface.

Steps to Test or Reproduce

  1. Run the script with no arguments: python scripts/world_create.py
    Expected output: usage message and exit.

  2. Run the script with a world name: python scripts/world_create.py
    Expected: world file created as normal.

  3. Run with world name and invert flag: python scripts/world_create.py test.world invert
    Expected: world created with inverted heightmap.

Impacted Areas in Application

  • scripts/world_create.py – argument handling and user feedback.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant