GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — migrate code from googleapis/nodejs-containeranalysis by NimJay · Pull Request #2834 · GoogleCloudPlatform/nodejs-docs-samples

Conversation

@NimJay

@NimJay NimJay commented Nov 11, 2022 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

This is a redo of #2833 which is a redo of #2816 (comment).
Do not use a merge commit to update this pull-request with main.


  • added directory structure
  • npm init
  • moved over samples
  • passing tests for create, get, delete note and create occurrence
  • passing get occurrence test
  • passing delete occurrence
  • passing test for occurrences for note, flaky
  • passing occurrences for image
  • samples
  • passing get Discovery Info
  • passing find vulnerabilities for image
  • passing high severity vulnerability test
  • pass all vulnerabilities for image
  • failing pubsub
  • passing pubsub tests
  • passing polling test
  • updated imageUrl to https://gcr.io/my-project/my-image:123 for more realistic use case
  • removed escape slashes from filter strings, not needed
  • updated description of occurrenceId
  • added comment to explain second filter statement, needed for testing
  • explicity state length greater than zero
  • removed system-test, moved tests into test directory
  • removed async functions from tests without await
  • removed unused exec
  • removed explicit project id from pub sub
  • ran fix
  • replaced promise/timeout with p-retry
  • changed all samples to be wrapped with an outer main function, added params as comments for user
  • added after step to delete occurrences and notes
  • updated polling sample and test
  • ran fix, dangling errs for symlink and polling
  • updated comment on occurrenceId
  • fixed typo in discovery test
  • grabs projectId from client, update projectId and vars the refer to it in before hooks, added uuid to test resourceUrl
  • removed commented code from polling sample
  • move end region tag to inside main function
  • removed symlinks from test script, removed commented test from polling block
  • deleted unused import from pub sub sample
  • changed grafeas to container analysis v1beta1 client
  • fixed typo in client, removed comment
  • added retry logic to get occurrence test
  • changed assert match to assert include
  • added create topic logic to fix ci test error
  • removed regexp from assert include
  • changed tests to include arrow functions
  • moved containeranalysis and pubsub into prod deps
  • added retry logic for all occs of note, check if topic exists and fixed typo on delete occ test
  • added sample-metadata
  • fixed occurrence typo
  • added params to sample-metadata usage
  • added p-retry to prod deps, updated poll sample
  • working poll discovery occurrence finished sample
  • updated default value of retries and timeoutSeconds to be more readable
  • refactor: changes formatting of various statements
  • chore: release 1.0.0 (Added back datastore v1beta3 samples. #33)
  • fix(deps): update dependency @google-cloud/pubsub to ^0.29.0 (Upgrade to latest nodejs LTS release #36)
  • chore: release 1.0.1 (Pin engines to Node 4.2. Closes #36. #37)
  • chore: release 1.0.2 (Simplify app.yaml files, reduce # of e2e tests, and cleanup for webpa… #40)
  • chore: release 1.1.0 (Skip node_modules for better deployments. #44)
  • feat: adds getGrafeasClient() method on ContainerAnalysisClient instance (Change 'sampletask' to 'sampleTask' for consistency #46)
  • chore: release 1.2.0 (Add property query filtering snippet. #47)
  • chore: update samples to reflect v1 Grafeas API (Datastore: Use new Key object to easily reference parts of a key path #48)
  • chore: release 1.2.1 (Added instructions for running the tests. Fixes #49. #50)
  • chore: release 1.2.2 (Add Prediction API sample. #52)
  • docs(samples): Update Topic ID in PubSub sample (Added Pub/Sub samples. #55)
  • chore: release 1.3.0 (Move back to container-based Travis builds and removed some redundant tests. #58)
  • fix(deps): update dependency @google-cloud/pubsub to ^0.30.0 (Add logging example and link to instructions for Compute Engine as well #59)
  • chore: release 1.3.1 (Datastore / CloudSQL samples should only store first two octtets of IP #61)
  • chore: release 1.3.2 (Changes for Datastore v1beta3. #68)
  • fix(deps): update dependency @google-cloud/pubsub to ^0.31.0 (memcache env vars #71)
  • chore: release 1.3.3 (Add sample for brunch #72)
  • fix(deps): update dependency @google-cloud/pubsub to ^0.32.0 (Samples/gulp #81)
  • chore: release 1.4.0 (Provided comment about done() #78)
  • fix(deps): update dependency @google-cloud/pubsub to v1 (Fix metric filter call #84)
  • chore: release 1.5.1 (I can commit directly to master #97)
  • chore: add license headers for samples (Remove skip_files from app.yaml files #106)
  • chore: release 1.6.0 (Add Cloud Speech sample. #110)
  • chore: release 1.6.1 (Add Cloud Vision text detection sample. #113)
  • refactor: use explicit mocha imports (Remove skip_files from app.yaml files, as it's no longer needed. #119)
  • chore: release 1.7.0 (gcloud-node datastore no longer supports "autoPaginate" option #115)
  • chore(deps): update dependency mocha to v7 (getApplicationDefault is undefined.  #121)
  • chore: release 1.7.1 (Add HTTP Cloud Function. #131)
  • feat: move API to typescript code generation (Changed helloworld to camel case #135)
  • chore: release 1.8.0 (Add missing sample that got inlined into the docs. #137)
  • chore(deps): update dependency uuid to v7
  • chore: release 1.9.0 (Add Speech API streaming sample. #144)
  • chore: release 1.10.0 (Switch CloudSQL sample to 2nd gen. Added unit tests. #153)
  • feat!: drop node8 support, support for async iterators (Update CI settings. #167)
  • test: there's a race condition emptying queue (Logging API samples #175)
  • test: retry pubsub test, as it relies on many moving parts (Export data from BigQuery samples #186)
  • test: retry queue deletion (Update all dependencies 🌴 #191)
  • build: adopt CI changes and generator formatting (Add remaining Translate samples. #197)
  • test: make tests idempotent (Add browsing data sample #201)
  • fix(samples): should use effective_severity field (Fix typo #200)
  • chore: release 2.0.0 (Remove output only fields #170)
  • build: modified export in protos.js
  • chore(deps): update dependency uuid to v8 (Fix asserts and related stubs. #206)
  • fix(deps): update dependency @google-cloud/pubsub to v2 (Add quickstart tests #215)
  • chore(deps): update dependency mocha to v8 (Fix pagination #222)
  • test: attempt retry on note delete (Upgrade tests and samples to ES2015 #224)
  • chore: release 2.1.0 (Convert tasks.js to yargs #210)
  • chore: release 2.1.1 (Error: Audio 'content' cannot be longer than 1 min. For long audio, use the 'uri' parameter to specify a file. #232)
  • docs(samples): update sample to illustrate AR style urls
  • chore: release 3.0.0 (Update app.yaml to use instance connection name #264)
  • chore: release 3.0.1 (Updating additional swagger API references #268)
  • chore: release 3.1.0 (Recognize stream freezes (from example) #278)
  • build: update gapic-generator-typescript to v1.2.10. (AssertionError: undefined deepEqual 1 when porting functions/datastore to local setup #284)
  • chore: release 3.1.1 (Vision snippets. #294)
  • chore: release 3.1.2 (New cloud functions example #299)
  • chore: new owl bot post processor docker image (Google Cloud Functions - Private Github repo in package.json #300)
  • chore: release 3.1.3 (Sample command's response take too long time #303)
  • chore: release 3.1.4 (Removed deprecated flag from app.yaml #309)
  • chore: release 3.1.5 (Video samples #319)
  • chore: release 3.1.6 (Fix issue with read-only transaction #325)
  • chore: release 3.1.7 (speech FLAC encoding not work #327)
  • chore: release 3.1.8 (Parallelize DLP tests #337)
  • chore: release 3.2.0 (Update translate dependency #340)
  • chore: release 3.3.0 (Semantic Text Matching like quora using Google NLP API (question) #353)
  • chore(main): release 3.4.0 (Fix CONTRIBUTING.md links not rendering correctly #389)
  • fix: Flaky pubsub test (Initial commit of sample #394)
  • build!: update library to use Node 12 (Error reporting #408)
  • chore(main): release 4.0.0 (Stackdriver samples #407)
  • fix(deps): update dependency @google-cloud/pubsub to v3 (Remove "entire video" detection from faces #410)
  • chore(main): release 4.1.0 (sendgrid example memory potential leaks #416)
  • fix(issue-417): adding additional asserts to track flaky error (Fix bigquery samples #421)
  • chore(main): release 4.2.0 (New changes added #MAKE CODE GREAT AGAIN! #422)
  • chore(deps): update dependency uuid to v9 (Upgrades language samples to semi-gapic client #435)
  • test(samples): disable samples tests for this repository (Added enableWordTimeOffsets: true to async (file) #440)
  • chore(main): release 4.3.0 (Fix iot document link #429)
  • chore(main): release 4.4.0 ([Speech] README needs autogen update (new Words CLI options are not shown in the README) #444)
  • chore(main): release 4.4.1 (unable to do translate image and place text on data bucket #449)

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
murog and others added 30 commits May 7, 2019 19:17
@murog
added directory structure
a67a8b8
@murog
npm init
d70d099
@murog
moved over samples
9f781ff
@murog
passing tests for create, get, delete note and create occurrence
397455b
@murog
passing get occurrence test
4cdd1ef
@murog
passing delete occurrence
7353725
@murog
passing test for occurrences for note, flaky
e27ca26
@murog
passing occurrences for image
1ffccce
@JustinBeckwith
samples
5739d98
@murog
passing get Discovery Info
c0aab11
@murog
passing find vulnerabilities for image
12b9c64
@murog
passing high severity vulnerability test
0483c04
@murog
pass all vulnerabilities for image
4cc415f
@murog
failing pubsub
4499e31
@murog
passing pubsub tests
b1b2e61
@murog
passing polling test
7c665a2
@murog
Merge branch 'master' of https://github.com/googleapis/nodejs-contain…
60e9be6
…eranalysis into ga-samples
@murog
updated imageUrl to https://gcr.io/my-project/my-image:123 for more r…
0595e4a
…ealistic use case
@murog
removed escape slashes from filter strings, not needed
c1f354e
@murog
updated description of occurrenceId
a17a296
@murog
added comment to explain second filter statement, needed for testing
68c04d3
@murog
explicity state length greater than zero
14ec8e4
@murog
removed system-test, moved tests into test directory
1435323
@murog
removed async functions from tests without await
5de0336
@murog
removed unused exec
d030bb1
@murog
removed explicit project id from pub sub
3032fb3
@murog
ran fix
3af92d1
@murog
replaced promise/timeout with p-retry
e9b5ba4
@murog
changed all samples to be wrapped with an outer main function, added
21be877
params as comments for user
@murog
added after step to delete occurrences and notes
3d470ca
alexander-fenster and others added 5 commits September 20, 2022 20:22
@alexander-fenster
test(samples): disable samples tests for this repository (#440)
10aeaaa
Fixes #430.
@release-please @gcf-owl-bot
chore(main): release 4.3.0 (#429)
58e0824
* chore(main): release 4.3.0

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
@release-please
chore(main): release 4.4.0 (#444)
2cdca7c
🤖 I have created a release *beep* *boop*
---


## [4.4.0](https://togithub.com/googleapis/nodejs-containeranalysis/compare/v4.3.0...v4.4.0) (2022-10-06)


### Features

* Add new analysis status and cvss version fields ([#443](https://togithub.com/googleapis/nodejs-containeranalysis/issues/443)) ([2b4db8e](https://togithub.com/googleapis/nodejs-containeranalysis/commit/2b4db8ee9859823e32de8256853429adf88cf207))

---
This PR was generated with [Release Please](https://togithub.com/googleapis/release-please). See [documentation](https://togithub.com/googleapis/release-please#release-please).
@release-please
chore(main): release 4.4.1 (#449)
8967a8d
🤖 I have created a release *beep* *boop*
---


## [4.4.1](https://togithub.com/googleapis/nodejs-containeranalysis/compare/v4.4.0...v4.4.1) (2022-11-10)


### Bug Fixes

* **deps:** Use google-gax v3.5.2 ([#447](https://togithub.com/googleapis/nodejs-containeranalysis/issues/447)) ([c0631d5](https://togithub.com/googleapis/nodejs-containeranalysis/commit/c0631d54928b9fe6df493f79883341e66d19f0ca))
* Regenerated protos JS and TS definitions ([#451](https://togithub.com/googleapis/nodejs-containeranalysis/issues/451)) ([9710e71](https://togithub.com/googleapis/nodejs-containeranalysis/commit/9710e715ef10471e536b5329e1e71ffe8b7265ec))

---
This PR was generated with [Release Please](https://togithub.com/googleapis/release-please). See [documentation](https://togithub.com/googleapis/release-please#release-please).
@NimJay
Merge remote-tracking branch 'migration/main' into nodejs-containeran…
52c34a0
…alysis-migration
@product-auto-label product-auto-label Bot added the samples Issues that are directly related to samples. label Nov 11, 2022
@google-cla

google-cla Bot commented Nov 11, 2022

Copy link
Copy Markdown

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@NimJay

NimJay commented Nov 11, 2022

Copy link
Copy Markdown
Contributor Author

Reminder: do not use a merge commit to update this pull-request (source branch) with main.
Use rebase instead.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

NimJay added 2 commits November 11, 2022 11:43
@NimJay
Generate container-analysis-snippets.yaml
db5d54c
@NimJay
Change Google Inc. to Google LLC
f65d8dc
NimJay
NimJay commented Nov 11, 2022
View reviewed changes
Comment thread container-analysis/snippets/quickstart.js
// [END containeranalysis_quickstart]
}

main(...process.argv.slice(2));

@NimJay NimJay Nov 11, 2022 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

We are keeping the quickstart.js because it's used in this cloud.google.com page.
We are supposed to treat the quickstart.js just like any other sample: if it's being used, migrate it.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@NimJay
NimJay marked this pull request as ready for review November 11, 2022 16:52
@NimJay
NimJay requested review from a team as code owners November 11, 2022 16:52
@snippet-bot

snippet-bot Bot commented Nov 11, 2022 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

Here is the summary of changes.

You are about to add 15 region tags.
  • container-analysis/snippets/createNote.js:25, tag containeranalysis_create_note
  • container-analysis/snippets/createOccurrence.js:30, tag containeranalysis_create_occurrence
  • container-analysis/snippets/deleteNote.js:25, tag containeranalysis_delete_note
  • container-analysis/snippets/deleteOccurrence.js:25, tag containeranalysis_delete_occurrence
  • container-analysis/snippets/getDiscoveryInfo.js:28, tag containeranalysis_discovery_info
  • container-analysis/snippets/getNote.js:25, tag containeranalysis_get_note
  • container-analysis/snippets/getOccurrence.js:25, tag containeranalysis_get_occurrence
  • container-analysis/snippets/highVulnerabilitiesForImage.js:27, tag containeranalysis_filter_vulnerability_occurrences
  • container-analysis/snippets/occurrencePubSub.js:26, tag containeranalysis_pubsub
  • container-analysis/snippets/occurrencesForImage.js:27, tag containeranalysis_occurrences_for_image
  • container-analysis/snippets/occurrencesForNote.js:25, tag containeranalysis_occurrences_for_note
  • container-analysis/snippets/pollDiscoveryOccurrenceFinished.js:28, tag containeranalysis_poll_discovery_occurrence_finished
  • container-analysis/snippets/pollDiscoveryOccurrenceFinished.js:50, tag containeranalysis_poll_discovery_occurrence_finished
  • container-analysis/snippets/quickstart.js:25, tag containeranalysis_quickstart
  • container-analysis/snippets/vulnerabilityOccurrencesForImage.js:27, tag containeranalysis_vulnerability_occurrences_for_image

This comment is generated by snippet-bot.
If you find problems with this result, please file an issue at:
https://github.com/googleapis/repo-automation-bots/issues.
To update this comment, add snippet-bot:force-run label or use the checkbox below:

  • Refresh this comment
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@NimJay
NimJay enabled auto-merge (rebase) November 11, 2022 16:58
kweinmeister
kweinmeister approved these changes Nov 11, 2022
View reviewed changes
auto-merge was automatically disabled November 11, 2022 17:16

Rebase failed

@JustinBeckwith @kweinmeister
samples
900a677
@NimJay
NimJay enabled auto-merge (rebase) November 11, 2022 17:50
auto-merge was automatically disabled November 11, 2022 17:53

Rebase failed

@NimJay NimJay mentioned this pull request Nov 11, 2022
migrate code from googleapis/nodejs-containeranalysis #2836
Closed
ace-n
ace-n approved these changes Nov 11, 2022
View reviewed changes
@ace-n
ace-n enabled auto-merge November 11, 2022 20:01
Ace Nassri
Merge branch 'main' into nodejs-containeranalysis-migration
78467b0
@ace-n

ace-n commented Nov 11, 2022

Copy link
Copy Markdown
Contributor

Using merge commit per @sofisl's suggestion

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@NimJay
Merge branch 'main' into nodejs-containeranalysis-migration
bdcb86a
@NimJay
NimJay disabled auto-merge November 11, 2022 22:18
@NimJay
NimJay merged commit 2668a58 into main Nov 11, 2022
@NimJay
NimJay deleted the nodejs-containeranalysis-migration branch November 11, 2022 22:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@kweinmeister kweinmeister kweinmeister approved these changes
+1 more reviewer
@ace-n ace-n ace-n approved these changes
Reviewers whose approvals may not affect merge requirements

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

samples Issues that are directly related to samples.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

13 participants

@NimJay @ace-n @kweinmeister @murog @JustinBeckwith @yoshi-automation @daniel-sanche @renovate-bot @xiaozhenliu-gg5 @alexander-fenster @donmccasland @wietsevenema @pattishin
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.