X Tutup
Skip to content

SlackRequestHandler does not work on Lambda #132

@cazziwork

Description

@cazziwork

Problem

I was create app by bolt for python, And deploy on Lambda.
But It's not work correct.

I investigated this issue and found problems in determining the following areas.
https://github.com/slackapi/bolt-python/blob/main/slack_bolt/adapter/aws_lambda/handler.py
line:35
method = event.get("requestContext", {}).get("http", {}).get("method")

On my Lambda environment, it's always return None.

Workaround

I modified it below.
method = event.get("requestContext", {}).get("httpMethod", {})

It's work correct.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      X Tutup