iterative / iterative/PyDrive2

After one hour get INFO:oauth2client.client:access_token is expired, but requests keep working

オープン
#72 コメント 7 件 リアクション 2 件 担当者 0 名 GitHub で見る
triage
主要言語
Python
スター
670
フォーク
75
PR マージ指標
30日以内にマージされた PR はありません

説明

I'm doing a large job to download approx 50k files from google drive.

After exactly an hour I start to see this message:

INFO:oauth2client.client:access_token is expired. Now: 2020-12-17 23:39:39.355448, token_expiry: 2020-12-17 23:06:32.235919
INFO:oauth2client.client:Updated access_token read from Storage

I have a single instance of GoogleDrive which I pass to all processes.

It seems like there must be a valid token as subsequent requests work fine, even though they continue to display this message.

What's the correct way to deal with this?

I'm using Python's multiprocessing to run many processes in parallel, and pass the GoogleDrive object to each worker process.

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

No repository file or test is named. Start by tracing the GoogleDrive object's access-token refresh behavior and how that object is passed to multiprocessing workers, then reproduce the one-hour download scenario. Done means the token-expiry messages and multiprocessing behavior have a verified explanation or a documented correction.

索引モデルが issue の本文から書いたものです。

評価

技術スタック
python
領域
api, authentication
issue の種類
バグ
難易度
4/5
見積もり時間
3〜5日
活発さ
停滞
明瞭さ
説明が足りない
初心者へのやさしさ
25/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。