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

chore(containeranalysis): add py2 deprecation warning, add 3.8 tests (via synth) #10065

Merged
merged 1 commit into from
Jan 29, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion containeranalysis/docs/_static/custom.css
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
div#python2-eol {
border-color: red;
border-width: medium;
}
}
1 change: 1 addition & 0 deletions containeranalysis/docs/_templates/layout.html
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

{% extends "!layout.html" %}
{%- block content %}
{%- if theme_fixed_sidebar|lower == 'true' %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,22 @@


from __future__ import absolute_import
import sys
import warnings

from google.cloud.devtools.containeranalysis_v1 import types
from google.cloud.devtools.containeranalysis_v1.gapic import container_analysis_client


if sys.version_info[:2] == (2, 7):
message = (
"A future version of this library will drop support for Python 2.7."
"More details about Python 2 support for Google Cloud Client Libraries"
"can be found at https://cloud.google.com/python/docs/python2-sunset/"
)
warnings.warn(message, DeprecationWarning)


class ContainerAnalysisClient(container_analysis_client.ContainerAnalysisClient):
__doc__ = container_analysis_client.ContainerAnalysisClient.__doc__

Expand Down
2 changes: 1 addition & 1 deletion containeranalysis/noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def default(session):
)


@nox.session(python=["2.7", "3.5", "3.6", "3.7"])
@nox.session(python=["2.7", "3.5", "3.6", "3.7", "3.8"])
def unit(session):
"""Run the unit test suite."""
default(session)
Expand Down
10 changes: 5 additions & 5 deletions containeranalysis/synth.metadata
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
{
"updateTime": "2019-11-05T21:33:52.199324Z",
"updateTime": "2020-01-08T13:15:38.194292Z",
"sources": [
{
"generator": {
"name": "artman",
"version": "0.41.0",
"dockerImage": "googleapis/artman@sha256:75b38a3b073a7b243545f2332463096624c802bb1e56b8cb6f22ba1ecd325fa9"
"version": "0.43.0",
"dockerImage": "googleapis/artman@sha256:264654a37596a44b0668b8ce6ac41082d713f6ee150b3fc6425fa78cc64e4f20"
}
},
{
"git": {
"name": "googleapis",
"remote": "https://github.com/googleapis/googleapis.git",
"sha": "cb542d6f5f1c9431ec4181d9cfd7f8d8c953e60b",
"internalRef": "278688708"
"sha": "08b488e0660c59842a7dee0e3e2b65d9e3a514a9",
"internalRef": "288625007"
}
},
{
Expand Down