質問編集履歴
1
不要なコードを削除しました
title
CHANGED
File without changes
|
body
CHANGED
@@ -16,12 +16,12 @@
|
|
16
16
|
|
17
17
|
scopes = ['https://spreadsheets.google.com/feeds',
|
18
18
|
'https://www.googleapis.com/auth/drive']
|
19
|
-
json_file = r'*******
|
19
|
+
json_file = r'C:\Users*******\Downloads\face-id-022a16cbf2d0.json'
|
20
20
|
credentials = ServiceAccountCredentials.from_json_keyfile_name(json_file, scopes=scopes)
|
21
21
|
http_auth = credentials.authorize(Http())
|
22
22
|
|
23
|
-
doc_id = '********'
|
23
|
+
doc_id = '*********'
|
24
|
-
SPREADSHEET_KEY = '*******'
|
24
|
+
SPREADSHEET_KEY = '**********'
|
25
25
|
client = gspread.authorize(credentials)
|
26
26
|
gfile = client.open_by_key(doc_id)
|
27
27
|
gc = gspread.authorize(credentials)
|
@@ -31,12 +31,11 @@
|
|
31
31
|
|
32
32
|
|
33
33
|
|
34
|
-
dt_now = datetime.today()
|
35
|
-
print(dt_now)
|
36
34
|
|
37
35
|
|
38
|
-
img = cv2.imread(r'*********')
|
39
36
|
|
37
|
+
img = cv2.imread(r'C:\Users*******\Pictures\qrcode_testqr.png')
|
38
|
+
|
40
39
|
# データ、検出領域の四隅の座標、QRコードのバージョン情報を取得
|
41
40
|
qr = cv2.QRCodeDetector()
|
42
41
|
data, points, straight_qrcode = qr.detectAndDecode(img)
|
@@ -44,11 +43,6 @@
|
|
44
43
|
print('データ:', data)
|
45
44
|
print("バージョン:", ((straight_qrcode.shape[0] - 21) / 4) + 1)
|
46
45
|
|
47
|
-
cell_value = worksheet.acell('B1').value
|
48
|
-
print(cell_value)
|
49
|
-
|
50
|
-
cell_value2 = worksheet.cell(1,2).value
|
51
|
-
print(cell_value2)
|
52
46
|
worksheet.append_row(data)
|
53
47
|
```
|
54
48
|
```エラーメッセージ
|