Skip to content

Add demo mission requirements - #24

Merged
jamesray merged 1 commit into
mainfrom
demo-requirements
Nov 9, 2026
Merged

jamesray merged 1 commit into
mainfrom
demo-requirements

Conversation

@jamesray

@jamesray jamesray commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds lambda_function/demo-requirements.txt so the processing Lambda image for the new demo mission can be built.

The demo mission's image is built by the build_demo_sdc_aws_processing_lambda CodeBuild project defined in swxsoc/sdc_aws_architecture (swxsoc/sdc_aws_architecture#55). buildspec.yml derives the mission from the project name, selects lambda_function/<mission>-requirements.txt, and exits when that file is missing, so the demo image cannot build until this file exists.

The file follows swxsoc_pipeline-requirements.txt:

  • psycopg2-binary
  • swxsoc and swxsoc[tracker] from git+https://github.com/swxsoc/swxsoc.git@main
  • demo_craft @ git+https://github.com/swxsoc/demo_craft.git@v0.0.1 — the demo mission's single instrument package. It depends only on astropy, numpy and swxsoc, and reads and writes CSV, so no CDF library is needed.

Also:

  • requirements.dev.txt gains a # Demo block with the same demo_craft pin, matching how the other missions' instrument packages are listed for unit testing.
  • AGENTS.md lists the new requirements file in the lambda_function/ tree.

Mission enumeration

Nothing in this repository enumerates missions centrally: buildspec.yml derives the mission from the CodeBuild project name, calibration.yml is hard-coded to padre, and test_processor.py parametrizes individual instrument test files. No demo test case is added because swxsoc's demo mission config does not yet list craft (it still carries the template MyInstrument1/MyInstrument2), so get_instrument_package("craft") cannot resolve under SWXSOC_MISSION=demo; that is a swxsoc config follow-up.

Verification

  • pip install -r lambda_function/demo-requirements.txt succeeds in a clean Python 3.12 venv, and demo_craft.calibration.process_file imports the way the Lambda does at runtime.
  • With requirements.dev.txt installed on top, ruff check / ruff format --check pass and pytest lambda_function/tests passes all 10 tests locally.

🤖 Generated with Claude Code

The demo mission's processing image is built by the
build_demo_sdc_aws_processing_lambda CodeBuild project in
swxsoc/sdc_aws_architecture, whose buildspec selects
lambda_function/<mission>-requirements.txt and exits when it is
missing. Pin the single demo instrument package, demo_craft, at
v0.0.1 alongside swxsoc and psycopg2-binary, list it in the dev
requirements for unit testing, and record the file in AGENTS.md.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings November 9, 2026 19:24

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approval recommended

No active review issues are recorded for the dependency and documentation changes.

No open issues 🎉

What changed in this PR

Adds the dependency file needed for the existing mission-based build pipeline to build the demo mission’s processing Lambda image. Runtime instrument resolution remains a separate swxsoc configuration follow-up.

Changes:

  • Adds demo image dependencies, including demo_craft pinned to v0.0.1.
  • Adds the same instrument package pin to development requirements.
  • Documents the new requirements file in the repository structure.
File Description
requirements.dev.txt Adds the pinned demo instrument package for development.
lambda_function/​demo-requirements.txt Defines dependencies for the demo Lambda image.
AGENTS.md Lists the demo requirements file in the directory tree.

Review effort: Balanced

@jamesray
jamesray merged commit fd33cba into main Nov 9, 2026
13 checks passed
jamesray added a commit to swxsoc/sdc_aws_architecture that referenced this pull request Nov 12, 2026
swxsoc/sdc_aws_processing_lambda#24 added lambda_function/demo-requirements.txt
on 2026-11-09, so the root README no longer lists it as a step to take. The
base image buildspec and swxsoc demo configuration changes are still open.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
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