Skip to content

Added code samples for stored infoTypes. #1934

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

Closed
wants to merge 6 commits into from

Conversation

mwdaub
Copy link
Contributor

@mwdaub mwdaub commented Dec 14, 2018

The DLP team is in the process of expanding code samples to include features that we have launched since the initial samples were written.

This pull request adds code samples for the recently launched stored infoTypes feature. The samples were modeled after triggers.py and adapted to stored infoTypes. Note that this does not include code samples for actually using them - those will be added later.

mwdaub added 4 commits June 13, 2018 11:15
The samples were modeled after triggers.py and adapted to stored infoTypes. Note that this does not include code samples for actually using them - those will be added later.
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Dec 14, 2018
@mwdaub
Copy link
Contributor Author

mwdaub commented Dec 20, 2018

Please take a look.

Copy link
Contributor

@gguuss gguuss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the PR, looks like this PR is a bit stale, a few nits, consider making changes to restart the CI.

'field': {'name': bq_input_table_field},
}
}
create_stored_info_type(project, dictionary_config,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As alternative formatting, you could avoid the hanging indent:

    create_stored_info_type(
        project, dictionary_config, stored_info_type_id=stored_info_type_id,
        display_name=display_name, description=description)

@@ -0,0 +1,99 @@
# Copyright 2017 Google Inc.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this is a new file, add this as 2019 instead of 2017

bucket.delete()


def test_create_list_and_delete_stored_info_type(bucket, capsys):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably fine as-is but consider separating the create/delete and create/list/delete tests.

@andrewferlitsch
Copy link
Contributor

from mcdaub: Hi Andrew, I originally submitted that PR in 2018 and then changed teams in early 2019. Because nobody responded to my PR request for over a month, I stopped working on it and no longer have the bandwidth to work on it since my new team is not associated with the code. You can either close the PR or ask my old team to open a new one with the same changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants