Skip to content

Commit a219e08

Browse files
committed
revert sample changes
1 parent 9962ecc commit a219e08

File tree

5 files changed

+15
-15
lines changed

5 files changed

+15
-15
lines changed

.github/workflows/test.yaml

+12-10
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ jobs:
2525
runs-on: ubuntu-latest
2626
outputs:
2727
affected: ${{steps.find-affected.outputs.affected}}
28-
defaults:
29-
run:
30-
working-directory: .github/testing
28+
# defaults:
29+
# run:
30+
# working-directory: .github/testing
3131
steps:
3232
# - uses: actions/checkout@v4
3333
# - uses: actions/setup-node@v4
@@ -38,16 +38,18 @@ jobs:
3838
# - id: find-affected
3939
# run: echo "affected=$(npm run --silent affected)" >> "$GITHUB_OUTPUT"
4040
- id: find-affected
41-
run: echo "$MATRIX" >> "$GITHUB_OUTPUT"
41+
run: echo "affected=$MATRIX" >> "$GITHUB_OUTPUT"
4242
env:
43-
MATRIX: '{"python": ["py"], "nodejs": ["js"]}'
43+
MATRIX: '{"python": [{"package": "A", "tests": ["a"]}], "nodejs": [{"package": "B", "tests": ["b"]}]}'
4444

45-
test-python:
45+
Python:
4646
needs: find-tests
4747
runs-on: ubuntu-latest
48-
# strategy:
49-
# matrix: ${{fromJson(needs.find-tests.outputs.affected)}}
48+
strategy:
49+
matrix: ${{fromJson(needs.find-tests.outputs.affected)}}
5050
steps:
5151
# - uses: actions/checkout@v4
52-
# - run: echo ${{matrix}}
53-
- run: echo ${{needs.find-tests.outputs.affected}}
52+
# - run: echo "matrix=${{needs.find-tests.outputs.affected}}"
53+
- run: echo "python=${{matrix.python}}"
54+
- run: echo "package=${{matrix.package}}"
55+
- run: echo "tests=${{matrix.tests}}"

README.md

-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
# Google Cloud Platform Python Samples
22

3-
43
Python samples for [Google Cloud Platform products][cloud].
54

65
[![Build Status][py-2.7-shield]][py-2.7-link] [![Build Status][py-3.8-shield]][py-3.8-link] [![Build Status][py-3.9-shield]][py-3.9-link] [![Build Status][py-3.10-shield]][py-3.10-link] [![Build Status][py-3.11-shield]][py-3.11-link]

language/README.md

-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
11
These samples have been moved.
22

3-
43
https://github.com/googleapis/python-language/tree/main/samples

language/v2/language_classify_text.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -42,14 +42,15 @@ def sample_classify_text(
4242
# Optional. If not specified, the language is automatically detected.
4343
# For list of supported languages:
4444
# https://cloud.google.com/natural-language/docs/languages
45+
language_code = "en"
4546
document = {
4647
"content": text_content,
4748
"type_": document_type_in_plain_text,
48-
"language_code": "en",
49+
"language_code": language_code,
4950
}
5051

5152
response = client.classify_text(request={"document": document})
52-
# Loop through classified categories returned from the API.
53+
# Loop through classified categories returned from the API
5354
for category in response.categories:
5455
# Get the name of the category representing the document.
5556
# See the predefined taxonomy of categories:

language/v2/language_entities_text_test.py

-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@
1919

2020

2121
def test_sample_analyze_entities_text(capsys: ...) -> None:
22-
# TODO: delete this comment
2322
assert os.environ["GOOGLE_CLOUD_PROJECT"] != ""
2423

2524
language_entities_text.sample_analyze_entities()

0 commit comments

Comments
 (0)