I have a python script that takes the generated CSV and loads it into Google Docs. It can load it just fine, put it, I can not get it to replace the data, it returns an error, I can not find the link.
Le Code:
import gdata.auth import gdata.docs import gdata.docs.service import gdata.docs.data import gdata.docs.client email = ' admin@domain.com ' CONSUMER_KEY='domain.com' CONSUMER_SECRET='blah54545blah' ms_client = gdata.docs.client.DocsClient('Domain_Doc_Upload') ms_client.auth_token = gdata.gauth.TwoLeggedOAuthHmacToken(CONSUMER_KEY, CONSUMER_SECRET, email) url = 'http://docs.google.com/feeds/documents/private/full/sd01blahgarbage' ms = gdata.data.MediaSource(file_path="C:\\people.csv", content_type='text/csv') csv_entry2 = ms_client.Update(url, ms)
It returns:
Traceback (most recent call last): File "so_test.py", line 19, in <module> csv_entry2 = ms_client.Update(ms, url) File "build\bdist.win-amd64\egg\gdata\client.py", line 717, in update AttributeError: 'MediaSource' object has no attribute 'to_string'
I canβt find anything about the 'to_string' attribute, so I got lost on the track. Any help is greatly appreciated.
Kevin source share