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.

Deploying on lambda > 'airtable object has no attribute 'get_iter'

See original GitHub issue

Hi,

When deploying on lambda, I get the following error

It would seem there is a conflict between airtable and airtable-python-wrapper but I don’t know how to solve it.

error log:

  "errorMessage": "'Airtable' object has no attribute 'get_iter'",
  "errorType": "AttributeError",

In my lambda_function.py:

from airtable import Airtable 
...
table_output = Airtable(base_key, output_table_name, apikey)
output_pages = table_output.get_iter(view='Grid view')
...
table_output.insert({'abc':x.y})

In my root folder of my lambda:

airtable
airtable-0.4.8.dist-info
...
lambda_function.py
...
requirements.txt

In my requirements.txt:

airtable-python-wrapper
airtable

Note: with lambda, dependencies need to be uploaded in the same .zip as the main function for the app to run with its dependencies.

Thank you for your help

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
vtennerocommented, Jul 28, 2021

thanks, all sorted with the following: In my lambda_function.py:

from airtable import Airtable 

In my root folder of my lambda:

airtable -> folder inside airtable-python-wrapper
...
lambda_function.py
...
requirements.txt

In my requirements.txt:

airtable-python-wrapper
1reaction
k-dalcommented, Jul 27, 2021

It looks like this is happening because you’re including airtable instead of airtable-python-wrapper in your root directory. They’re completely separate libraries (airtable and airtable-python-wrapper) with similar functionality – though I think this one is significantly better. It’s also not clear why both are in your requirements.txt, but only airtable is in your root dir.

Is there a reason you need both of them? Why not stick to airtable-python-wrapper?

Read more comments on GitHub >

github_iconTop Results From Across the Web

'Airtable' object has no attribute 'get_all' · Issue #24 - GitHub
I am receiving the error in the Title when trying to run my Python within a cron job. I have been having trouble...
Read more >
Integrating with AWS Lambda & DynamoDB - Airtable Support
This guide focuses on pushing data into DynamoDB via an AWS Lambda. By changing the Lambda code, you could also use this setup...
Read more >
AWS Lambda ERROR: AttributeError 'list' object has no ...
However, when I trigger the Lambda function (using an IoT Button) I get the following error message. [ERROR] AttributeError: 'list' object has ...
Read more >
DynamoDB Integration - Retool Docs
Retool connects with DynamoDB, allowing you to access your data from your internal tools. Connecting DynamoDB. First, go to IAM and create a...
Read more >
'str' object has no attribute 'get' error with Airtable.py | Solveforum
Ismail Hafeez Asks: AttributeError: 'str' object has no attribute 'get' error with Airtable.py I just installed airtable.py to connect with ...
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