Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Mar 15, 2025. It is now read-only.

Commitb86ac3a

Browse files
chore: update templates (#16)
* chore(py_library): add some excludes in docs/conf.pyThis should fix build failures in python-bigquery.Example:googleapis/python-bigquery#205* also add a commentSource-Author: Takashi Matsuo <tmatsuo@google.com>Source-Date: Mon Aug 3 15:08:00 2020 -0700Source-Repo: googleapis/synthtoolSource-Sha: 4f8f5dc24af79694887385015294e4dbb214c352Source-Link:googleapis/synthtool@4f8f5dc* chore(py-library): enable snippet-botCo-authored-by: Benjamin E. Coe <bencoe@google.com>Source-Author: Takashi Matsuo <tmatsuo@google.com>Source-Date: Tue Sep 1 17:14:08 2020 +0000Source-Repo: googleapis/synthtoolSource-Sha: d91dd8aac77f7a9c5506c238038a26fa4f9e361eSource-Link:googleapis/synthtool@d91dd8a* chore(py-library): update decrypt secrets file* chore(py-library): update decrypt secrets fileFromhttps://github.com/GoogleCloudPlatform/python-docs-samples/blob/master/scripts/decrypt-secrets.sh* docs: explain conditionalCo-authored-by: Jeffrey Rennie <rennie@google.com>Source-Author: Bu Sun Kim <8822365+busunkim96@users.noreply.github.com>Source-Date: Tue Sep 8 11:35:59 2020 -0600Source-Repo: googleapis/synthtoolSource-Sha: d302f93d7f47e2852e585ac35ab2d15585717ec0Source-Link:googleapis/synthtool@d302f93* chore(python-library): use sphinx 1.5.5 for the docfx jobOriginally tested at:googleapis/python-texttospeech#89This change will fix the missing docstring in the yaml files.Source-Author: Takashi Matsuo <tmatsuo@google.com>Source-Date: Thu Sep 10 04:12:14 2020 +0000Source-Repo: googleapis/synthtoolSource-Sha: ffcee7952b74f647cbb3ef021d95422f10816fcaSource-Link:googleapis/synthtool@ffcee79* build(python): use release-publish app for notifying GitHub of releas…* build(python): use release-publish app for notifying GitHub of release status* fix: re-add pypi passwordSource-Author: Bu Sun Kim <8822365+busunkim96@users.noreply.github.com>Source-Date: Wed Sep 16 08:46:42 2020 -0600Source-Repo: googleapis/synthtoolSource-Sha: 257fda18168bedb76985024bd198ed1725485488Source-Link:googleapis/synthtool@257fda1* build(python): add secret manager in kokoroSource-Author: Bu Sun Kim <8822365+busunkim96@users.noreply.github.com>Source-Date: Wed Sep 16 10:24:40 2020 -0600Source-Repo: googleapis/synthtoolSource-Sha: dba48bb9bc6959c232bec9150ac6313b608fe7bdSource-Link:googleapis/synthtool@dba48bb* chore(python): add sphinx doctest extensionSource-Author: Bu Sun Kim <8822365+busunkim96@users.noreply.github.com>Source-Date: Mon Sep 21 13:09:57 2020 -0600Source-Repo: googleapis/synthtoolSource-Sha: 27f4406999b1eee29e04b09b2423a8e4646c7e24Source-Link:googleapis/synthtool@27f4406* chore(python): remove note about editable installs`pip install -e .` is supported and is how we install the library for tests.Source-Author: Bu Sun Kim <8822365+busunkim96@users.noreply.github.com>Source-Date: Tue Sep 22 12:06:12 2020 -0600Source-Repo: googleapis/synthtoolSource-Sha: a651c5fb763c69a921aecdd3e1d8dc51dbf20f8dSource-Link:googleapis/synthtool@a651c5f* chore(python): use BUILD_SPECIFIC_GCLOUD_PROJECT for sampleshttps://github.com/googleapis/python-talent/blob/ef045e8eb348db36d7a2a611e6f26b11530d273b/samples/snippets/noxfile_config.py#L27-L32`BUILD_SPECIFIC_GCLOUD_PROJECT` is an alternate project used for sample tests that do poorly with concurrent runs on the same project.Source-Author: Bu Sun Kim <8822365+busunkim96@users.noreply.github.com>Source-Date: Wed Sep 30 13:06:03 2020 -0600Source-Repo: googleapis/synthtoolSource-Sha: 9b0da5204ab90bcc36f8cd4e5689eff1a54cc3e4Source-Link:googleapis/synthtool@9b0da52* build(python): samples tests should pass if no samples existSource-Author: Daniel Sanche <d.sanche14@gmail.com>Source-Date: Wed Oct 14 08:00:06 2020 -0700Source-Repo: googleapis/synthtoolSource-Sha: 477764cc4ee6db346d3febef2bb1ea0abf27de52Source-Link:googleapis/synthtool@477764c* chore(python_library): change the docs bucket nameSource-Author: Takashi Matsuo <tmatsuo@google.com>Source-Date: Fri Oct 16 09:58:05 2020 -0700Source-Repo: googleapis/synthtoolSource-Sha: da5c6050d13b4950c82666a81d8acd25157664aeSource-Link:googleapis/synthtool@da5c605* chore(docs): update code of conduct of synthtool and templatesSource-Author: Christopher Wilcox <crwilcox@google.com>Source-Date: Thu Oct 22 14:22:01 2020 -0700Source-Repo: googleapis/synthtoolSource-Sha: 5f6ef0ec5501d33c4667885b37a7685a30d41a76Source-Link:googleapis/synthtool@5f6ef0e* docs: add proto-plus to intersphinx mappingSource-Author: Tim Swast <swast@google.com>Source-Date: Tue Oct 27 12:01:14 2020 -0500Source-Repo: googleapis/synthtoolSource-Sha: ea52b8a0bd560f72f376efcf45197fb7c8869120Source-Link:googleapis/synthtool@ea52b8a* docs(python): update intersphinx for grpc and auth* docs(python): update intersphinx for grpc and auth* use https for python intersphinxCo-authored-by: Tim Swast <swast@google.com>Source-Author: Bu Sun Kim <8822365+busunkim96@users.noreply.github.com>Source-Date: Wed Nov 18 14:37:25 2020 -0700Source-Repo: googleapis/synthtoolSource-Sha: 9a7d9fbb7045c34c9d3d22c1ff766eeae51f04c9Source-Link:googleapis/synthtool@9a7d9fb* docs(python): fix intersphinx link for google-authSource-Author: Bu Sun Kim <8822365+busunkim96@users.noreply.github.com>Source-Date: Thu Nov 19 10:16:05 2020 -0700Source-Repo: googleapis/synthtoolSource-Sha: a073c873f3928c561bdf87fdfbf1d081d1998984Source-Link:googleapis/synthtool@a073c87* chore: add config / docs for 'pre-commit' supportSource-Author: Tres Seaver <tseaver@palladion.com>Source-Date: Tue Dec 1 16:01:20 2020 -0500Source-Repo: googleapis/synthtoolSource-Sha: 32af6da519a6b042e3da62008e2a75e991efb6b4Source-Link:googleapis/synthtool@32af6da* chore(deps): update precommit hook pre-commit/pre-commit-hooks to v3.3.0Source-Author: WhiteSource Renovate <bot@renovateapp.com>Source-Date: Wed Dec 2 17:18:24 2020 +0100Source-Repo: googleapis/synthtoolSource-Sha: 69629b64b83c6421d616be2b8e11795738ec8a6cSource-Link:googleapis/synthtool@69629b6* chore(deps): update precommit hook pre-commit/pre-commit-hooks to v3.4.0Co-authored-by: Tres Seaver <tseaver@palladion.com>Source-Author: WhiteSource Renovate <bot@renovateapp.com>Source-Date: Wed Dec 16 18:13:24 2020 +0100Source-Repo: googleapis/synthtoolSource-Sha: aa255b15d52b6d8950cca48cfdf58f7d27a60c8aSource-Link:googleapis/synthtool@aa255b1* docs(python): document adding Python 3.9 support, dropping 3.5 supportCloses #787Source-Author: Tres Seaver <tseaver@palladion.com>Source-Date: Thu Dec 17 16:08:02 2020 -0500Source-Repo: googleapis/synthtoolSource-Sha: b670a77a454f415d247907908e8ee7943e06d718Source-Link:googleapis/synthtool@b670a77* chore: exclude `.nox` directories from lintingThe samples tests create `.nox` directorieswith all dependencies installed. These directoriesshould be excluded from linting.I've tested this change locally, and it significantlyspeeds up linting on my machine.Source-Author: Tim Swast <swast@google.com>Source-Date: Tue Dec 22 13:04:04 2020 -0600Source-Repo: googleapis/synthtoolSource-Sha: 373861061648b5fe5e0ac4f8a38b32d639ee93e4Source-Link:googleapis/synthtool@3738610
1 parentb98739c commitb86ac3a

File tree

16 files changed

+306
-114
lines changed

16 files changed

+306
-114
lines changed

‎.flake8‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ exclude =
2626
*_pb2.py
2727

2828
# Standard linting exemptions.
29+
**/.nox/**
2930
__pycache__,
3031
.git,
3132
*.pyc,

‎.github/snippet-bot.yml‎

Whitespace-only changes.

‎.kokoro/docs/common.cfg‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ env_vars: {
3030

3131
env_vars: {
3232
key:"V2_STAGING_BUCKET"
33-
value:"docs-staging-v2-staging"
33+
value:"docs-staging-v2"
3434
}
3535

3636
# It will upload the docker image after successful builds.

‎.kokoro/populate-secrets.sh‎

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
#!/bin/bash
2+
# Copyright 2020 Google LLC.
3+
#
4+
# Licensed under the Apache License, Version 2.0 (the "License");
5+
# you may not use this file except in compliance with the License.
6+
# You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
16+
set -eo pipefail
17+
18+
functionnow { date +"%Y-%m-%d %H:%M:%S"| tr -d'\n';}
19+
functionmsg { println"$*">&2;}
20+
functionprintln {printf'%s\n'"$(now)$*";}
21+
22+
23+
# Populates requested secrets set in SECRET_MANAGER_KEYS from service account:
24+
# kokoro-trampoline@cloud-devrel-kokoro-resources.iam.gserviceaccount.com
25+
SECRET_LOCATION="${KOKORO_GFILE_DIR}/secret_manager"
26+
msg"Creating folder on disk for secrets:${SECRET_LOCATION}"
27+
mkdir -p${SECRET_LOCATION}
28+
forkeyin$(echo${SECRET_MANAGER_KEYS}| sed"s/,/ /g")
29+
do
30+
msg"Retrieving secret${key}"
31+
docker run --entrypoint=gcloud \
32+
--volume=${KOKORO_GFILE_DIR}:${KOKORO_GFILE_DIR} \
33+
gcr.io/google.com/cloudsdktool/cloud-sdk \
34+
secrets versions access latest \
35+
--project cloud-devrel-kokoro-resources \
36+
--secret${key}> \
37+
"${SECRET_LOCATION}/${key}"
38+
if [[$?== 0 ]];then
39+
msg"Secret written to${SECRET_LOCATION}/${key}"
40+
else
41+
msg"Error retrieving secret${key}"
42+
fi
43+
done

‎.kokoro/release/common.cfg‎

Lines changed: 13 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -23,42 +23,18 @@ env_vars: {
2323
value:"github/python-org-policy/.kokoro/release.sh"
2424
}
2525

26-
# Fetch the token needed for reporting release status to GitHub
27-
before_action {
28-
fetch_keystore {
29-
keystore_resource {
30-
keystore_config_id: 73713
31-
keyname:"yoshi-automation-github-key"
32-
}
33-
}
34-
}
35-
36-
# Fetch PyPI password
37-
before_action {
38-
fetch_keystore {
39-
keystore_resource {
40-
keystore_config_id: 73713
41-
keyname:"google_cloud_pypi_password"
42-
}
43-
}
44-
}
45-
46-
# Fetch magictoken to use with Magic Github Proxy
47-
before_action {
48-
fetch_keystore {
49-
keystore_resource {
50-
keystore_config_id: 73713
51-
keyname:"releasetool-magictoken"
52-
}
53-
}
26+
# Fetch PyPI password
27+
before_action {
28+
fetch_keystore {
29+
keystore_resource {
30+
keystore_config_id: 73713
31+
keyname:"google_cloud_pypi_password"
32+
}
33+
}
5434
}
5535

56-
# Fetch api key to use with Magic Github Proxy
57-
before_action {
58-
fetch_keystore {
59-
keystore_resource {
60-
keystore_config_id: 73713
61-
keyname:"magic-github-proxy-api-key"
62-
}
63-
}
64-
}
36+
# Tokens needed to report release status back to GitHub
37+
env_vars: {
38+
key:"SECRET_MANAGER_KEYS"
39+
value:"releasetool-publish-reporter-app,releasetool-publish-reporter-googleapis-installation,releasetool-publish-reporter-pem"
40+
}

‎.kokoro/samples/python3.6/common.cfg‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,12 @@ env_vars: {
1313
value:"py-3.6"
1414
}
1515

16+
# Declare build specific Cloud project.
17+
env_vars: {
18+
key:"BUILD_SPECIFIC_GCLOUD_PROJECT"
19+
value:"python-docs-samples-tests-py36"
20+
}
21+
1622
env_vars: {
1723
key:"TRAMPOLINE_BUILD_FILE"
1824
value:"github/python-org-policy/.kokoro/test-samples.sh"

‎.kokoro/samples/python3.7/common.cfg‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,12 @@ env_vars: {
1313
value:"py-3.7"
1414
}
1515

16+
# Declare build specific Cloud project.
17+
env_vars: {
18+
key:"BUILD_SPECIFIC_GCLOUD_PROJECT"
19+
value:"python-docs-samples-tests-py37"
20+
}
21+
1622
env_vars: {
1723
key:"TRAMPOLINE_BUILD_FILE"
1824
value:"github/python-org-policy/.kokoro/test-samples.sh"

‎.kokoro/samples/python3.8/common.cfg‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,12 @@ env_vars: {
1313
value:"py-3.8"
1414
}
1515

16+
# Declare build specific Cloud project.
17+
env_vars: {
18+
key:"BUILD_SPECIFIC_GCLOUD_PROJECT"
19+
value:"python-docs-samples-tests-py38"
20+
}
21+
1622
env_vars: {
1723
key:"TRAMPOLINE_BUILD_FILE"
1824
value:"github/python-org-policy/.kokoro/test-samples.sh"

‎.kokoro/test-samples.sh‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,12 @@ if [[ $KOKORO_BUILD_ARTIFACTS_SUBDIR = *"periodic"* ]]; then
2828
git checkout$LATEST_RELEASE
2929
fi
3030

31+
# Exit early if samples directory doesn't exist
32+
if [!-d"./samples" ];then
33+
echo"No tests run.`./samples` not found"
34+
exit 0
35+
fi
36+
3137
# Disable buffering, so that the logs stream through.
3238
export PYTHONUNBUFFERED=1
3339

@@ -101,4 +107,4 @@ cd "$ROOT"
101107
# Workaround for Kokoro permissions issue: delete secrets
102108
rm testing/{test-env.sh,client-secrets.json,service-account.json}
103109

104-
exit"$RTN"
110+
exit"$RTN"

‎.kokoro/trampoline.sh‎

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,14 @@
1515

1616
set -eo pipefail
1717

18-
python3"${KOKORO_GFILE_DIR}/trampoline_v1.py"|| ret_code=$?
18+
# Always run the cleanup script, regardless of the success of bouncing into
19+
# the container.
20+
functioncleanup() {
21+
chmod +x${KOKORO_GFILE_DIR}/trampoline_cleanup.sh
22+
${KOKORO_GFILE_DIR}/trampoline_cleanup.sh
23+
echo"cleanup";
24+
}
25+
trap cleanup EXIT
1926

20-
chmod +x${KOKORO_GFILE_DIR}/trampoline_cleanup.sh
21-
${KOKORO_GFILE_DIR}/trampoline_cleanup.sh||true
22-
23-
exit${ret_code}
27+
$(dirname$0)/populate-secrets.sh# Secret Manager secrets.
28+
python3"${KOKORO_GFILE_DIR}/trampoline_v1.py"

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp