anthropics/skills · info · RuntimeError
This module should not be run directly.
Error message
This module should not be run directly.
What it means
pptx.py is a library module of the office validators package; the __main__ guard raises RuntimeError if it is executed directly. Its slide/notes-slide validation logic runs only when imported by the validation driver.
Source
Thrown at skills/xlsx/scripts/office/validators/pptx.py:441
for slide_name, rels_file in references:
errors.append(f" - {rels_file.relative_to(self.unpacked_dir)}")
if errors:
print(
f"FAILED - Found {len([e for e in errors if not e.startswith(' ')])} notes slide reference validation errors:"
)
for error in errors:
print(error)
print("Each slide may optionally have its own slide file.")
return False
else:
if self.verbose:
print("PASSED - All notes slide references are unique")
return True
if __name__ == "__main__":
raise RuntimeError("This module should not be run directly.")
View on GitHub (pinned to f6656c1256)
Solutions
- Use the driver script that imports this validator for command-line validation
- Import the module when you need its classes programmatically
- Mark the validators directory as non-executable in IDE run configurations / CI globs
Example fix
# before python skills/xlsx/scripts/office/validators/pptx.py deck.pptx # after python skills/xlsx/scripts/office/validate.py deck.pptx # driver imports pptx validator
Defensive patterns
Strategy: try-catch
Try / catch
# Usage error, not a runtime failure — call the driver that imports the pptx validator.
Prevention
- Invoke the package's validation entry point for command-line use
- Import, don't execute, validator modules during exploration
When it happens
Trigger: `python skills/xlsx/scripts/office/validators/pptx.py` directly; IDE run action; CI glob-execute harness reaching into the validators directory.
Common situations: Developer opening the validator file and hitting Run; automation that treats all .py files as scripts.
Related errors
- This module should not be run directly.
- This module should not be run directly.
- This module should not be run directly.
AI-assisted analysis of anthropics/skills@f6656c1256 (2026-08-14).
Data as JSON: /api/errors/07c613535b05731b.
Report an issue: GitHub.