Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat!: Update Firestore to use Microgeneration #63

Closed
wants to merge 68 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
68 commits
Select commit Hold shift + click to select a range
9638ecb
microgen update - initial
crwilcox Jun 18, 2020
e900f9d
add replacements for rehomed files
crwilcox Jun 18, 2020
3e41207
roll in init.py modifications
crwilcox Jun 18, 2020
5aa21c6
revert some of the synth changes to setup.py
crwilcox Jun 18, 2020
3cfce77
include admin generated surface
crwilcox Jun 18, 2020
d1fdc25
refactor for enums class
crwilcox Jun 23, 2020
d3e72df
small errors
crwilcox Jun 23, 2020
7383799
Import DocumentTransform from original location
crwilcox Jun 23, 2020
92eabf2
modify paths to admin components
crwilcox Jun 23, 2020
7896549
modify import paths for more files
crwilcox Jun 23, 2020
9159253
missing header
crwilcox Jun 23, 2020
18f8a91
run fixup_keywords
crwilcox Jun 23, 2020
6bb7756
move proto references to new types
crwilcox Jun 23, 2020
f7fa550
modify references to structure query type
crwilcox Jun 23, 2020
82a4fe8
bring back test protos, format, some path adjusts
crwilcox Jun 24, 2020
00a8486
further adjustments
crwilcox Jun 24, 2020
be3866d
add flag to templates to specify microgenerator
crwilcox Jun 24, 2020
023d3fc
include script in setup.py
crwilcox Jun 24, 2020
ea3b3c6
manual edits to deal with multiple clients
crwilcox Jun 24, 2020
f58e229
copy admin components
crwilcox Jun 24, 2020
78fea16
copy fixup scripts for each component
crwilcox Jun 24, 2020
b39284b
adjust admin import paths
crwilcox Jun 24, 2020
8d4d2ed
deleted proto pb2
crwilcox Jun 24, 2020
24b38ee
attempt to build descriptors from protoplus bits
crwilcox Jun 24, 2020
047485c
remove cross language test for now
crwilcox Jun 24, 2020
5869d44
rename test files
crwilcox Jun 24, 2020
52223db
regen
crwilcox Jun 25, 2020
4e393f4
run keyword scripts on tests
crwilcox Jun 25, 2020
345613b
Edit Watch Code Paths to Get Test Passing
crwilcox Jun 25, 2020
ff95182
1010 passing
crwilcox Jun 25, 2020
b20453a
1029 use api_core call directly, not on generated class any longer.
crwilcox Jun 25, 2020
e752a27
1040 Transaction Test Expected Calls
crwilcox Jun 25, 2020
8334589
test transaction passes
crwilcox Jun 25, 2020
6ee8c0b
fix modify_write to use pb. 416 failed, 1072 passed
crwilcox Jun 25, 2020
3aac33a
some import paths, 1095
crwilcox Jun 25, 2020
e299de5
Manual Edit Generated to Account for oneof
crwilcox Jun 25, 2020
571af1e
371 failed, 1117 passed
crwilcox Jun 26, 2020
fead994
354 failed, 1134 passed
crwilcox Jun 26, 2020
0bd7d0c
blacken
crwilcox Jun 26, 2020
1713764
proto to types
crwilcox Jun 26, 2020
1b856e3
Manual fixes for googleapis/gapic-generator-python#485
crwilcox Jun 26, 2020
ec3123a
v1 34 failed, 575 passed
crwilcox Jun 27, 2020
e32866d
v1 31 failed, 578 passed
crwilcox Jun 27, 2020
edc34de
v1 25 failed
crwilcox Jun 27, 2020
7700fa3
small fixes towards system tests
crwilcox Jun 27, 2020
e1362e1
v1 18 failed
crwilcox Jun 27, 2020
a830c8e
Add TODO until after we get datetime with nanos
crwilcox Jun 27, 2020
544c044
v1 14 failed
crwilcox Jun 27, 2020
8208461
v1 8 fail. Some tests removed for datetimewithnanos future work
crwilcox Jun 27, 2020
a24c03b
v1 passes
crwilcox Jun 27, 2020
8c698bd
most fixes to v1beta1 unit
crwilcox Jun 27, 2020
377e00a
generate after one of (and other) generator fixes
crwilcox Jul 8, 2020
84c921e
manually add value_type oneof notation back
crwilcox Jul 8, 2020
87ca142
Add oneof for BatchDocumentsResponse
crwilcox Jul 8, 2020
3262ab2
Some generator fixes, test fixes
crwilcox Jul 9, 2020
e2febf1
update pin for api-core to match gen
crwilcox Jul 10, 2020
5e5d464
updates from codegen
crwilcox Jul 10, 2020
2c61345
raw copy of services, types
crwilcox Jul 10, 2020
c133a8b
only 5/36 sys tests fail
crwilcox Jul 10, 2020
1fa292c
test fix
crwilcox Jul 10, 2020
a124532
watch fix
crwilcox Jul 10, 2020
68bce98
lint fixes, system test 100%
crwilcox Jul 10, 2020
5278aa6
unit, 24 failed, 1482 passed
crwilcox Jul 10, 2020
7386a13
regenerate with synt adjustments
crwilcox Jul 10, 2020
add6c50
test fixes
crwilcox Jul 10, 2020
4e6b5b8
synth and gen
crwilcox Jul 10, 2020
62f8bca
tests, imports, and bears oh my
crwilcox Jul 10, 2020
add4c18
green is good :)
crwilcox Jul 10, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 9 additions & 24 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -1,35 +1,20 @@
# -*- coding: utf-8 -*-
#
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# Generated by synthtool. DO NOT EDIT!
[run]
branch = True

[report]
fail_under = 100
show_missing = True
omit =
google/cloud/firestore_v1/__init__.py
google/cloud/firestore_v1beta1/__init__.py
google/cloud/firestore_admin_v1/__init__.py
exclude_lines =
# Re-enable the standard pragma
pragma: NO COVER
# Ignore debug-only repr
def __repr__
# Ignore abstract methods
raise NotImplementedError
omit =
*/gapic/*.py
*/proto/*.py
*/core/*.py
*/site-packages/*.py
# Ignore pkg_resources exceptions.
# This is added at the module level as a safeguard for if someone
# generates the code and tries to run it without pip installing. This
# makes it virtually impossible to test properly.
except pkg_resources.DistributionNotFound
4 changes: 3 additions & 1 deletion .flake8
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,13 @@

# Generated by synthtool. DO NOT EDIT!
[flake8]
ignore = E203, E266, E501, W503
ignore = E203, E231, E266, E501, W503
exclude =
# Exclude generated code.
**/proto/**
**/gapic/**
**/services/**
**/types/**
*_pb2.py

# Standard linting exemptions.
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
dist
build
eggs
.eggs
parts
bin
var
Expand Down Expand Up @@ -49,6 +50,7 @@ bigquery/docs/generated
# Virtual environment
env/
coverage.xml
sponge_log.xml

# System test environment variables.
system_tests/local_test_setup
Expand Down
2 changes: 0 additions & 2 deletions .kokoro/publish-docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.

#!/bin/bash

set -eo pipefail

# Disable buffering, so that the logs stream through.
Expand Down
2 changes: 0 additions & 2 deletions .kokoro/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.

#!/bin/bash

set -eo pipefail

# Start the releasetool reporter
Expand Down
34 changes: 34 additions & 0 deletions .kokoro/samples/lint/common.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Format: //devtools/kokoro/config/proto/build.proto

# Build logs will be here
action {
define_artifacts {
regex: "**/*sponge_log.xml"
}
}

# Specify which tests to run
env_vars: {
key: "RUN_TESTS_SESSION"
value: "lint"
}

env_vars: {
key: "TRAMPOLINE_BUILD_FILE"
value: "github/python-firestore/.kokoro/test-samples.sh"
}

# Configure the docker image for kokoro-trampoline.
env_vars: {
key: "TRAMPOLINE_IMAGE"
value: "gcr.io/cloud-devrel-kokoro-resources/python-samples-testing-docker"
}

# Download secrets for samples
gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/python-docs-samples"

# Download trampoline resources.
gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline"

# Use the trampoline script to run in docker.
build_file: "python-firestore/.kokoro/trampoline.sh"
6 changes: 6 additions & 0 deletions .kokoro/samples/lint/continuous.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "True"
}
6 changes: 6 additions & 0 deletions .kokoro/samples/lint/periodic.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "False"
}
6 changes: 6 additions & 0 deletions .kokoro/samples/lint/presubmit.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "True"
}
34 changes: 34 additions & 0 deletions .kokoro/samples/python3.6/common.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Format: //devtools/kokoro/config/proto/build.proto

# Build logs will be here
action {
define_artifacts {
regex: "**/*sponge_log.xml"
}
}

# Specify which tests to run
env_vars: {
key: "RUN_TESTS_SESSION"
value: "py-3.6"
}

env_vars: {
key: "TRAMPOLINE_BUILD_FILE"
value: "github/python-firestore/.kokoro/test-samples.sh"
}

# Configure the docker image for kokoro-trampoline.
env_vars: {
key: "TRAMPOLINE_IMAGE"
value: "gcr.io/cloud-devrel-kokoro-resources/python-samples-testing-docker"
}

# Download secrets for samples
gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/python-docs-samples"

# Download trampoline resources.
gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline"

# Use the trampoline script to run in docker.
build_file: "python-firestore/.kokoro/trampoline.sh"
7 changes: 7 additions & 0 deletions .kokoro/samples/python3.6/continuous.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "True"
}

6 changes: 6 additions & 0 deletions .kokoro/samples/python3.6/periodic.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "False"
}
6 changes: 6 additions & 0 deletions .kokoro/samples/python3.6/presubmit.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "True"
}
34 changes: 34 additions & 0 deletions .kokoro/samples/python3.7/common.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Format: //devtools/kokoro/config/proto/build.proto

# Build logs will be here
action {
define_artifacts {
regex: "**/*sponge_log.xml"
}
}

# Specify which tests to run
env_vars: {
key: "RUN_TESTS_SESSION"
value: "py-3.7"
}

env_vars: {
key: "TRAMPOLINE_BUILD_FILE"
value: "github/python-firestore/.kokoro/test-samples.sh"
}

# Configure the docker image for kokoro-trampoline.
env_vars: {
key: "TRAMPOLINE_IMAGE"
value: "gcr.io/cloud-devrel-kokoro-resources/python-samples-testing-docker"
}

# Download secrets for samples
gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/python-docs-samples"

# Download trampoline resources.
gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline"

# Use the trampoline script to run in docker.
build_file: "python-firestore/.kokoro/trampoline.sh"
6 changes: 6 additions & 0 deletions .kokoro/samples/python3.7/continuous.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "True"
}
6 changes: 6 additions & 0 deletions .kokoro/samples/python3.7/periodic.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "False"
}
6 changes: 6 additions & 0 deletions .kokoro/samples/python3.7/presubmit.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "True"
}
34 changes: 34 additions & 0 deletions .kokoro/samples/python3.8/common.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Format: //devtools/kokoro/config/proto/build.proto

# Build logs will be here
action {
define_artifacts {
regex: "**/*sponge_log.xml"
}
}

# Specify which tests to run
env_vars: {
key: "RUN_TESTS_SESSION"
value: "py-3.8"
}

env_vars: {
key: "TRAMPOLINE_BUILD_FILE"
value: "github/python-firestore/.kokoro/test-samples.sh"
}

# Configure the docker image for kokoro-trampoline.
env_vars: {
key: "TRAMPOLINE_IMAGE"
value: "gcr.io/cloud-devrel-kokoro-resources/python-samples-testing-docker"
}

# Download secrets for samples
gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/python-docs-samples"

# Download trampoline resources.
gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline"

# Use the trampoline script to run in docker.
build_file: "python-firestore/.kokoro/trampoline.sh"
6 changes: 6 additions & 0 deletions .kokoro/samples/python3.8/continuous.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "True"
}
6 changes: 6 additions & 0 deletions .kokoro/samples/python3.8/periodic.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "False"
}
6 changes: 6 additions & 0 deletions .kokoro/samples/python3.8/presubmit.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Format: //devtools/kokoro/config/proto/build.proto

env_vars: {
key: "INSTALL_LIBRARY_FROM_SOURCE"
value: "True"
}
Loading