Catalog npm
Back to packageRELEASE DETAILS

1.0.0

npm

@-0/build-lambda-py

Node CLI for building Python Lambda packages using Poetry

awsclilambdapoetrypythonjsmodulenodenpm
Published30 Sept 2023
Direct dependencies1
Transitive dependenciesNot calculated

README

Current package documentation

@-0/build-lambda-py

Node CLI for building Python Lambda packages using Poetry

Installation

Add CLI as a file Dependency for NPM Scripts

npm install -D @-0/build-lambda-py

You will see a working example in the example directory.

example/package.json

{
    ...
    "scripts": {
        "build": "lambda build parent"
    },
    "dependencies": {
        "lambda": "file:./node_modules/@-0/build-lambda-py"
    },
    "devDependencies": {
        "@-0/build-lambda-py": "^1.0.2"
    }
    ...
}

In Use

From inside the example directory. Running npm run build will produce the following output:

npm run build

> example-build-lambda-py-cli@1.0.0 build
> lambda build parent

==== Building: ...parent ====

exporting    : requirements.txt...
building     : parent from poetry.lock file...
rolling      : wheels for dependencies...
copying      : handler and src into package root...
touching     : __init__.py into package root...
zipping      : package as: parent.zip

==== Zipped: ...parent/zipped/parent.zip ====

You will then have a nicely zipped Python Lambda package in the zipped directory.

Running the CLI Directly

From inside the example directory

> npx @-0/build-lambda-py build parent

Help

> npx @-0/build-lambda-py help build
Usage: build-lambda-py build [options] <parent>

Builds a Python Lambda package using Poetry

Arguments:
  parent                [relative to script] Source directory containing all dependencies...

  Suggested parent structure:

      parent
      ├── src
      │   ├── __init__.py
      │   └── local_dep.py
      ├── handler.py
      ├── pyproject.toml
      └── poetry.lock


Options:
  -h, --handler <file>  [relative to parent] Lambda handler file (default: "handler.py")
  -t, --target <dir>    [relative to parent] Target director containing code to bundle (default: "src")
  -o, --out-dir <dir>   [relative to parent] DEDICATED zip file output directory (default: "zipped")
  -d, --dev-deps        Include Poetry `group.dev` dependencies (default: false)
  --help                display help for command

Dependencies

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Declared dependencies 1

Native requirements
1 direct targetsNot calculated transitive count
Package / targetRequirementRelationship
commander
Environment
{
  "local_name": "commander",
  "alias": false,
  "peer_metadata": null
}
^11.0.0runtime

Distribution files

1 collected
Distribution 1

Source distribution

Source file
Checksums from source
{
  "integrity": "sha512-htyF8IReRzQ8JFkn6ytCAIHtGEFdQGsHWCgeTQWpY6FWGp2YJ7XbjEx3LHs+y0ArPCuHj5YX17hXdGhJXVdeTA==",
  "shasum": "45a8f969d6a975ee551448ae3b4ea6526bedb6a2",
  "tarball": "https://registry.npmjs.org/@-0/build-lambda-py/-/build-lambda-py-1.0.0.tgz",
  "fileCount": 3,
  "unpackedSize": 8491,
  "signatures": [
    {
      "keyid": "SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA",
      "sig": "MEUCIQDdZLaUhDCUpaTKk8JscNtepjBLVVH1NKmXwn1qTWR1KAIgLmcsNloZ9wh5pmNUQoCgC6RESFn70UCICnFekHFSb+A="
    }
  ]
}

Repository

PENDING
subs0/build-lambda-py

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 20 Oct, 21:47 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package_version:e6b90b120fd5ee3ece1fc9401d31914052912a16e9cb79ec4bfbb5a419c0441d

Other collected versions

1.0.430 Sept1.0.330 Sept1.0.230 Sept1.0.130 SeptView all collected versions →