From d286a6b516be166d7e900f32ffa63367ec5f921c Mon Sep 17 00:00:00 2001 From: Danny Hermes Date: Tue, 20 Sep 2016 16:01:39 -0700 Subject: [PATCH] Making all license headers uniform. Also adding license headers where they are missing. Also had to tweak the max lines allowed in a test module due to added license header. Used: https://gist.github.com/dhermes/17177b603e2b22902334947d9871529c --- docs/conf.py | 14 +++++++++++++- google/cloud/monitoring/_dataframe.py | 2 +- google/cloud/monitoring/label.py | 2 +- google/cloud/monitoring/metric.py | 2 +- google/cloud/monitoring/query.py | 2 +- google/cloud/monitoring/resource.py | 2 +- google/cloud/monitoring/timeseries.py | 2 +- google/cloud/streaming/transfer.py | 3 +-- scripts/run_pylint.py | 2 +- setup.py | 14 ++++++++++++++ system_tests/retry.py | 14 ++++++++++++++ unit_tests/monitoring/test__dataframe.py | 2 +- unit_tests/monitoring/test_client.py | 2 +- unit_tests/monitoring/test_connection.py | 2 +- unit_tests/monitoring/test_group.py | 2 +- unit_tests/monitoring/test_label.py | 2 +- unit_tests/monitoring/test_metric.py | 2 +- unit_tests/monitoring/test_query.py | 2 +- unit_tests/monitoring/test_resource.py | 2 +- unit_tests/monitoring/test_timeseries.py | 2 +- unit_tests/streaming/test_buffered_stream.py | 14 ++++++++++++++ unit_tests/streaming/test_exceptions.py | 14 ++++++++++++++ unit_tests/streaming/test_http_wrapper.py | 14 ++++++++++++++ unit_tests/streaming/test_stream_slice.py | 14 ++++++++++++++ unit_tests/streaming/test_transfer.py | 14 ++++++++++++++ unit_tests/streaming/test_util.py | 14 ++++++++++++++ unit_tests/vision/_fixtures.py | 14 ++++++++++++++ 27 files changed, 156 insertions(+), 19 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index d27668cea964..d9914daa2bc8 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -1,4 +1,16 @@ -# -*- coding: utf-8 -*- +# Copyright 2016 Google Inc. All rights reserved. +# +# 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 +# +# http://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. # # google-cloud documentation build configuration file, created by # sphinx-quickstart on Tue Jan 21 22:24:47 2014. diff --git a/google/cloud/monitoring/_dataframe.py b/google/cloud/monitoring/_dataframe.py index 6a0d933935e5..9accbab5db33 100644 --- a/google/cloud/monitoring/_dataframe.py +++ b/google/cloud/monitoring/_dataframe.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/google/cloud/monitoring/label.py b/google/cloud/monitoring/label.py index 9579e768ac0e..e5636a6a98ce 100644 --- a/google/cloud/monitoring/label.py +++ b/google/cloud/monitoring/label.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/google/cloud/monitoring/metric.py b/google/cloud/monitoring/metric.py index 5bec97f7c4eb..26ccfa363911 100644 --- a/google/cloud/monitoring/metric.py +++ b/google/cloud/monitoring/metric.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/google/cloud/monitoring/query.py b/google/cloud/monitoring/query.py index d9176b15f562..85055c24bae0 100644 --- a/google/cloud/monitoring/query.py +++ b/google/cloud/monitoring/query.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/google/cloud/monitoring/resource.py b/google/cloud/monitoring/resource.py index b49ecc864f97..6338f47921c5 100644 --- a/google/cloud/monitoring/resource.py +++ b/google/cloud/monitoring/resource.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/google/cloud/monitoring/timeseries.py b/google/cloud/monitoring/timeseries.py index 39d5f8ad873b..41c01d7e7d76 100644 --- a/google/cloud/monitoring/timeseries.py +++ b/google/cloud/monitoring/timeseries.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/google/cloud/streaming/transfer.py b/google/cloud/streaming/transfer.py index 8738bb349d8b..84bfb5a90308 100644 --- a/google/cloud/streaming/transfer.py +++ b/google/cloud/streaming/transfer.py @@ -1,5 +1,3 @@ -# pylint: disable=too-many-lines - # Copyright 2016 Google Inc. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,6 +11,7 @@ # 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. +# pylint: disable=too-many-lines """Upload and download support for apitools.""" diff --git a/scripts/run_pylint.py b/scripts/run_pylint.py index 7774b68a7765..d3ab161dedae 100644 --- a/scripts/run_pylint.py +++ b/scripts/run_pylint.py @@ -66,7 +66,7 @@ } TEST_RC_REPLACEMENTS = { 'FORMAT': { - 'max-module-lines': 1950, + 'max-module-lines': 1960, }, } diff --git a/setup.py b/setup.py index f1e9a2eac826..c47cc1370f98 100644 --- a/setup.py +++ b/setup.py @@ -1,3 +1,17 @@ +# Copyright 2016 Google Inc. All rights reserved. +# +# 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 +# +# http://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. + import os import sys diff --git a/system_tests/retry.py b/system_tests/retry.py index 34e2bf93e015..b414d946e25b 100644 --- a/system_tests/retry.py +++ b/system_tests/retry.py @@ -1,3 +1,17 @@ +# Copyright 2016 Google Inc. All rights reserved. +# +# 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 +# +# http://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. + import time from functools import wraps diff --git a/unit_tests/monitoring/test__dataframe.py b/unit_tests/monitoring/test__dataframe.py index 3e9fd31d111e..b52de9780e69 100644 --- a/unit_tests/monitoring/test__dataframe.py +++ b/unit_tests/monitoring/test__dataframe.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/unit_tests/monitoring/test_client.py b/unit_tests/monitoring/test_client.py index 202b76f2f24e..adea532060d0 100644 --- a/unit_tests/monitoring/test_client.py +++ b/unit_tests/monitoring/test_client.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/unit_tests/monitoring/test_connection.py b/unit_tests/monitoring/test_connection.py index 3001f997b2c1..67c23d4eb48a 100644 --- a/unit_tests/monitoring/test_connection.py +++ b/unit_tests/monitoring/test_connection.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/unit_tests/monitoring/test_group.py b/unit_tests/monitoring/test_group.py index aa02adf75ee1..e90e7494bee4 100644 --- a/unit_tests/monitoring/test_group.py +++ b/unit_tests/monitoring/test_group.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/unit_tests/monitoring/test_label.py b/unit_tests/monitoring/test_label.py index 8bfe6e8c4e49..cd80959029e4 100644 --- a/unit_tests/monitoring/test_label.py +++ b/unit_tests/monitoring/test_label.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/unit_tests/monitoring/test_metric.py b/unit_tests/monitoring/test_metric.py index c6e6a5d8bfd6..3cf711ef74e1 100644 --- a/unit_tests/monitoring/test_metric.py +++ b/unit_tests/monitoring/test_metric.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/unit_tests/monitoring/test_query.py b/unit_tests/monitoring/test_query.py index 0b1a44370baa..82605f96de23 100644 --- a/unit_tests/monitoring/test_query.py +++ b/unit_tests/monitoring/test_query.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/unit_tests/monitoring/test_resource.py b/unit_tests/monitoring/test_resource.py index 5e3cac503b01..ea9ec214a238 100644 --- a/unit_tests/monitoring/test_resource.py +++ b/unit_tests/monitoring/test_resource.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/unit_tests/monitoring/test_timeseries.py b/unit_tests/monitoring/test_timeseries.py index ca724b6b197e..d2ac225dc061 100644 --- a/unit_tests/monitoring/test_timeseries.py +++ b/unit_tests/monitoring/test_timeseries.py @@ -4,7 +4,7 @@ # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://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, diff --git a/unit_tests/streaming/test_buffered_stream.py b/unit_tests/streaming/test_buffered_stream.py index c56ce7a31faf..03cae5b43908 100644 --- a/unit_tests/streaming/test_buffered_stream.py +++ b/unit_tests/streaming/test_buffered_stream.py @@ -1,3 +1,17 @@ +# Copyright 2016 Google Inc. All rights reserved. +# +# 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 +# +# http://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. + import unittest diff --git a/unit_tests/streaming/test_exceptions.py b/unit_tests/streaming/test_exceptions.py index a0e17447042f..ffe5602e3d37 100644 --- a/unit_tests/streaming/test_exceptions.py +++ b/unit_tests/streaming/test_exceptions.py @@ -1,3 +1,17 @@ +# Copyright 2016 Google Inc. All rights reserved. +# +# 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 +# +# http://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. + import unittest diff --git a/unit_tests/streaming/test_http_wrapper.py b/unit_tests/streaming/test_http_wrapper.py index fc971cbdf387..d421bd40ea2f 100644 --- a/unit_tests/streaming/test_http_wrapper.py +++ b/unit_tests/streaming/test_http_wrapper.py @@ -1,3 +1,17 @@ +# Copyright 2016 Google Inc. All rights reserved. +# +# 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 +# +# http://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. + import unittest diff --git a/unit_tests/streaming/test_stream_slice.py b/unit_tests/streaming/test_stream_slice.py index 8bbef61d5d15..2d9d0c198fa5 100644 --- a/unit_tests/streaming/test_stream_slice.py +++ b/unit_tests/streaming/test_stream_slice.py @@ -1,3 +1,17 @@ +# Copyright 2016 Google Inc. All rights reserved. +# +# 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 +# +# http://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. + import unittest diff --git a/unit_tests/streaming/test_transfer.py b/unit_tests/streaming/test_transfer.py index 96426404b2c5..2ba715cac3fc 100644 --- a/unit_tests/streaming/test_transfer.py +++ b/unit_tests/streaming/test_transfer.py @@ -1,3 +1,17 @@ +# Copyright 2016 Google Inc. All rights reserved. +# +# 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 +# +# http://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. + import unittest diff --git a/unit_tests/streaming/test_util.py b/unit_tests/streaming/test_util.py index 6e72cfae07d2..c2f0f1501e77 100644 --- a/unit_tests/streaming/test_util.py +++ b/unit_tests/streaming/test_util.py @@ -1,3 +1,17 @@ +# Copyright 2016 Google Inc. All rights reserved. +# +# 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 +# +# http://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. + import unittest diff --git a/unit_tests/vision/_fixtures.py b/unit_tests/vision/_fixtures.py index f30b69a18a63..788564979e0e 100644 --- a/unit_tests/vision/_fixtures.py +++ b/unit_tests/vision/_fixtures.py @@ -1,3 +1,17 @@ +# Copyright 2016 Google Inc. All rights reserved. +# +# 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 +# +# http://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. + IMAGE_PROPERTIES_RESPONSE = { 'responses': [ {