On 2017-02-06 00:08, Deborah Swanson wrote:
Hi David,

Well, I really don't know the first thing about Macs, but it looks like
you got the download and environment variable right, at least it's not
complaining about that.

Looks like the current problem is with the parameters you're passing to
the build() function. I don't have the apiclient module installed, so I
can't look at it for myself, but here is the critical error:

build() takes at most 2 positional arguments (3 given)

This means that you've given too many parameters to build(). I'm a bit
confused because your youtube_search()code is calling build() with:

youtube = build(YOUTUBE_API_SERVICE_NAME, YOUTUBE_API_VERSION,
developerKey=DEVELOPER_KEY),

which is passing 3 arguments,

That's 2 positional arguments and 1 keyword argument.

> and you're using

youtube = build(YOUTUBE_API_SERVICE_NAME,
GOOGLE_APPLICATION_CREDENTIALS, YOUTUBE_API_VERSION,
developerKey=DEVELOPER_KEY),

which is passing 4 arguments.

That's 3 positional arguments and 1 keyword argument.

> In either case the error you're getting is
complaining that build() only takes 2 arguments, so it's not matching up
with either youtube_search's code or your call to build().


It's expecting at most 2 positional arguments. Any additional arguments would have to be keyword arguments.

[snip]

--
https://mail.python.org/mailman/listinfo/python-list

Reply via email to