Skip to content

How to test locally (macOS, Xcode or command line)? #413

Description

@jpenwith

Expected behavior

I can't see how to test locally on the README?

Some documentation suggests setting LOCAL_LAMBDA_SERVER_ENABLED in ENV, so I tried this

Actual behavior

The process exits with a missingLambdaRuntimeAPIEnvironmentVariable error

Steps to reproduce

  1. Follow the steps in https://github.com/swift-server/swift-aws-lambda-runtime/blob/main/readme.md
  2. Either open in Xcode and set LOCAL_LAMBDA_SERVER_ENABLED to true in the scheme editor, then run
  3. Or do LOCAL_LAMBDA_SERVER_ENABLED=true swift run

If possible, minimal yet complete reproducer code (or URL to code)

No response

What version of this project (swift-aws-lambda-runtime) are you using?

latest main

Swift version

swift-driver version: 1.115 Apple Swift version 6.0 (swiftlang-6.0.0.9.10 clang-1600.0.26.2)
Target: arm64-apple-macosx15.0
Darwin Firebolt 24.0.0 Darwin Kernel Version 24.0.0: Tue Sep 24 23:38:45 PDT 2024; root:xnu-11215.1.12~1/RELEASE_ARM64_T8122 arm64

Amazon Linux 2 docker image version

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions