Comments (7)
I am sorry I don't understand the question. Can you include a code snippet?
url_safe_table_name
is an internal local variable and does need to be touched.
I tested against one of the default bases and it seems to be working fine.
>>> from airtable import Airtable
>>> table = Airtable(base_key='appEioitPbxI72w06', table_name='Editorial', api_key='keyMyKey')
>>> table.get_all()
[{'id': 'rec9B3nlOhIxUVX1e', 'fields': [... TRUNCATED]
>>> table.url_table
'https://api.airtable.com/v0/appEioitPbxI72w06/Editorial'
Note the generate url matches the documentation, minus the api_key
which is added in the request headers instead of url query params
from pyairtable.
Ok, thanks a bunch!
Not to flock this issue with unrelated questions, but I noticed the airtable API doesn't allow for creating and reading comments. You haven't found a way to work around this, have you?
Again, thanks for all the help.
from pyairtable.
I believe I corrected myself, I restored everything back to normal.
Turns out the only weird issue I had was when I used the url_safe_table_name for authentication it returned a 404, but using the table_name allowed me to create the Airtable class.
Is there something wrong with this approach?
from pyairtable.
When the table name includes characters such as % the safe_url changes the string slightly:
>>> airtable = Airtable("appipCCmuh5ixrmxX","Content%20production")
Traceback (most recent call last):
File "<stdin'>", line 1, in <module>
File "C:\Users\theom\AppData\Local\Programs\Python\Python37-32\lib\site-packages\airtable\airtable.py", line 131, in __init__
self.is_authenticated = self.validate_session(self.url_table)
File "C:\Users\theom\AppData\Local\Programs\Python\Python37-32\lib\site-packages\airtable\airtable.py", line 138, in validate_session
raise ValueError('Invalid base or table name: {}'.format(url))
ValueError: Invalid base or table name: https://api.airtable.com/v0/appipCCmuh5ixrmxX/Content%2520production
Am I missing something very obvious? Perhaps using the appropriate escape character?
from pyairtable.
auto url escape was added by a contributor on #10
Did you try using the un-escaped version of the table name?
airtable = Airtable("appipCCmuh5ixrmxX","Content production")
should correctly result in the url below:
https://api.airtable.com/v0/appipCCmuh5ixrmxX/Content%20production
from pyairtable.
Not that I know of. I don't think thats exposed through the api
from pyairtable.
I had the same bug.
Thanks for the help gtalarico.
from pyairtable.
Related Issues (20)
- Loading a base with Base() and name overwrites id HOT 2
- Airtable Insert error code 422 HOT 4
- `Api.all()` not present but indicated in `Api` docstring HOT 2
- Webhook delete method HOT 2
- Importing formulas wont work HOT 2
- to_airtable_value() might not be correct for date and datetime values HOT 2
- Add more formulas HOT 2
- Update does not accept return_fields_by_field_id parameter HOT 8
- Rate limit API requests without forcing retries HOT 4
- get_table_schema fails when the api.table is initialized with the table's ID HOT 2
- Error using sample HOT 2
- Implement missing formulas HOT 2
- 2.2 release missing table.update_field HOT 1
- Can I just replace my API key with Personal Access token in legacy code ? HOT 1
- LookupField referencing a LinkField returns id rather than entity HOT 2
- Dynamic solution to formulas HOT 1
- One to many search difficulties HOT 4
- Error on `base.create_table` HOT 1
- ORM Batch Save Strategy HOT 1
- ORM table `kwargs` wrapping HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyairtable.