Content-Length: 297736 | pFad | http://github.com/googleapis/google-cloud-python/commit/6fd6f3010d1a72bc52969abbf28c8ae55d03f9cd

E0 fix: moves import six inside of region tags (#83) · googleapis/google-cloud-python@6fd6f30 · GitHub
Skip to content

Commit 6fd6f30

Browse files
authored
fix: moves import six inside of region tags (#83)
1 parent b235d75 commit 6fd6f30

File tree

1 file changed

+2
-2
lines changed
  • packages/google-cloud-translate/samples/snippets

1 file changed

+2
-2
lines changed

packages/google-cloud-translate/samples/snippets/snippets.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,6 @@
2323

2424
import argparse
2525

26-
import six
27-
2826

2927
def detect_language(text):
3028
# [START translate_detect_language]
@@ -84,6 +82,7 @@ def translate_text_with_model(target, text, model="nmt"):
8482
Target must be an ISO 639-1 language code.
8583
See https://g.co/cloud/translate/v2/translate-reference#supported_languages
8684
"""
85+
import six
8786
from google.cloud import translate_v2 as translate
8887

8988
translate_client = translate.Client()
@@ -108,6 +107,7 @@ def translate_text(target, text):
108107
Target must be an ISO 639-1 language code.
109108
See https://g.co/cloud/translate/v2/translate-reference#supported_languages
110109
"""
110+
import six
111111
from google.cloud import translate_v2 as translate
112112

113113
translate_client = translate.Client()

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/googleapis/google-cloud-python/commit/6fd6f3010d1a72bc52969abbf28c8ae55d03f9cd

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy