question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Bug: Import fails due to missing jmespath

See original GitHub issue

Expected Behaviour

Import succeeds

Current Behaviour

Import fails with


import: 'aws_lambda_powertools'
Traceback (most recent call last):
  File "/home/conda/feedstock_root/build_artifacts/aws-lambda-powertools_1667417534136/test_tmp/run_test.py", line 2, in <module>
    import aws_lambda_powertools
  File "/home/conda/feedstock_root/build_artifacts/aws-lambda-powertools_1667417534136/_test_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_plac/lib/python3.11/site-packages/aws_lambda_powertools/__init__.py", line 7, in <module>
    from .logging import Logger
  File "/home/conda/feedstock_root/build_artifacts/aws-lambda-powertools_1667417534136/_test_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_plac/lib/python3.11/site-packages/aws_lambda_powertools/logging/__init__.py", line 3, in <module>
    from .logger import Logger
  File "/home/conda/feedstock_root/build_artifacts/aws-lambda-powertools_1667417534136/_test_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_plac/lib/python3.11/site-packages/aws_lambda_powertools/logging/logger.py", line 23, in <module>
    import jmespath
ModuleNotFoundError: No module named 'jmespath'

Code snippet

import aws_lambda_powertools

Possible Solution

Add jmespath as dependency

Steps to Reproduce

Import aws_lambda_powertools

AWS Lambda Powertools for Python version

latest

AWS Lambda function runtime

3.9

Packaging format used

PyPi

Debugging logs

Logs: https://dev.azure.com/conda-forge/feedstock-builds/_build/results?buildId=603951&view=logs&j=656edd35-690f-5c53-9ba3-09c10d0bea97&t=e5c8ab1d-8ff9-5cae-b332-e15ae582ed2d

Dependencies uses: https://github.com/regro-cf-autotick-bot/aws-lambda-powertools-feedstock/blob/2.1.0_heecba7/recipe/meta.yaml

PR: https://github.com/conda-forge/aws-lambda-powertools-feedstock/pull/54

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
BastianZimcommented, Nov 2, 2022

Yes makes sense, will do that then. Thanks for the help!

0reactions
github-actions[bot]commented, Nov 2, 2022

⚠️COMMENT VISIBILITY WARNING⚠️

This issue is now closed. Please be mindful that future comments are hard for our team to see.

If you need more assistance, please either tag a team member or open a new issue that references this one.

If you wish to keep having a conversation with other community members under this issue feel free to do so.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Package installs not detected for interpreters / environments ...
import jmespath. Correctly observe an error for the missing import. Outside of the editor, install with pip install jmespath .
Read more >
AWS Lambda - Runtime.ImportModuleError: Error: Cannot find ...
I hit the same problem Error: Cannot find module 'jmespath' and solved it. Do you use aws-sdk via node_modules? like follows
Read more >
"You need to install 'jmespath' prior to running json_query filter ...
I am using Ansible on top of Python3 and Enterprise Linux 8 (Rocky Linux 8). When I try to use json_query , I...
Read more >
JMESPath Specification
JMESPath functions are required to type check their input arguments. Specifying an invalid type for a function argument will result in a JMESPath...
Read more >
Filter for Specific Fields (JMESPath) [2022] | API Connector
Hi, how can i filter the array by "image.os" field value and get all records? thanks in advance. [{ "config": { "image.architecture": " ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found