Skip to content

Add run.py entry point for Chronicle API samples - #1

Open
michaelhughes2501 with Copilot wants to merge 3 commits into
masterfrom
copilot/create-file-for-program
Open

michaelhughes2501 with Copilot wants to merge 3 commits into
masterfrom
copilot/create-file-for-program

Conversation

Copilot AI commented Feb 11, 2026 •

Copy link
Copy Markdown

The repository contains 99+ Chronicle API samples but lacks a unified entry point for discovery and execution. Users must remember full module paths like python3 -m detect.v2.list_rules.

Changes

Added run.py with the following capabilities:

  • Sample discovery: Automatically scans and lists all available samples organized by API category (detect, lists, uppercase, forwarders, etc.)
  • Execution wrapper: Runs any sample by module path with transparent argument forwarding
  • Help delegation: Passes -h and other flags directly to the target sample

Usage

# List all available samples
python3 run.py --list

# Run any sample with full argument support
python3 run.py detect.v2.list_rules -h
python3 run.py uppercase.list_alerts -c ~/.chronicle_credentials.json

The implementation uses runpy.run_module() to execute samples in their original context, preserving all existing functionality while providing a simpler interface.

Original prompt

Create a file so I can run program


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI and others added 2 commits February 11, 2026 13:49
Co-authored-by: michaelhughes2501 <258144740+michaelhughes2501@users.noreply.github.com>
Co-authored-by: michaelhughes2501 <258144740+michaelhughes2501@users.noreply.github.com>
Copilot AI changed the title [WIP] Add file creation for program execution Add run.py entry point for Chronicle API samples Feb 11, 2026
@michaelhughes2501
michaelhughes2501 marked this pull request as ready for review May 17, 2026 07:40
@michaelhughes2501
michaelhughes2501 self-requested a review June 1, 2026 16:43

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@michaelhughes2501
michaelhughes2501 enabled auto-merge (squash) June 3, 2026 01:18

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

goood

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@michaelhughes2501
michaelhughes2501 enabled auto-merge (squash) June 12, 2026 18:17
@michaelhughes2501
michaelhughes2501 self-requested a review June 12, 2026 18:17

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good

@michaelhughes2501
michaelhughes2501 enabled auto-merge (squash) June 20, 2026 12:10

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

review

@michaelhughes2501

Copy link
Copy Markdown
Collaborator

bvhv

@michaelhughes2501
michaelhughes2501 enabled auto-merge (squash) June 20, 2026 13:00

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good

@michaelhughes2501
michaelhughes2501 self-requested a review June 21, 2026 04:56

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok

@michaelhughes2501

Copy link
Copy Markdown
Collaborator

K

@michaelhughes2501
michaelhughes2501 self-requested a review June 22, 2026 13:03

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

God

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok

@michaelhughes2501
michaelhughes2501 enabled auto-merge (squash) July 26, 2026 23:22

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@michaelhughes2501 michaelhughes2501 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good

@michaelhughes2501
michaelhughes2501 enabled auto-merge (rebase) July 26, 2026 23:24
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.

2 participants