diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md deleted file mode 100644 index 85050fe9..00000000 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ /dev/null @@ -1,38 +0,0 @@ ---- -name: Bug report -about: Create a report to help us improve -labels: 'type: bug, priority: p2' ---- - -Thanks for stopping by to let us know something could be better! - -**PLEASE READ**: If you have a support contract with Google, please create an issue in the [support console](https://cloud.google.com/support/) instead of filing on GitHub. This will ensure a timely response. - -1) Is this a client library issue or a product issue? -This is the client library for . We will only be able to assist with issues that pertain to the behaviors of this library. If the issue you're experiencing is due to the behavior of the product itself, please visit the [ Support page]() to reach the most relevant engineers. - -2) Did someone already solve this? - - Search the issues already opened: https://github.com/googleapis/google-auth-library-nodejs/issues - - Search the issues on our "catch-all" repository: https://github.com/googleapis/google-cloud-node - - Search or ask on StackOverflow (engineers monitor these tags): http://stackoverflow.com/questions/tagged/google-cloud-platform+node.js - -3) Do you have a support contract? -Please create an issue in the [support console](https://cloud.google.com/support/) to ensure a timely response. - -If the support paths suggested above still do not result in a resolution, please provide the following details. - -#### Environment details - - - OS: - - Node.js version: - - npm version: - - `google-auth-library` version: - -#### Steps to reproduce - - 1. ? - 2. ? - -Making sure to follow these steps will guarantee the quickest resolution possible. - -Thanks! diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md deleted file mode 100644 index b0327dfa..00000000 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ /dev/null @@ -1,18 +0,0 @@ ---- -name: Feature request -about: Suggest an idea for this library -labels: 'type: feature request, priority: p3' ---- - -Thanks for stopping by to let us know something could be better! - -**PLEASE READ**: If you have a support contract with Google, please create an issue in the [support console](https://cloud.google.com/support/) instead of filing on GitHub. This will ensure a timely response. - - **Is your feature request related to a problem? Please describe.** -A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] - **Describe the solution you'd like** -A clear and concise description of what you want to happen. - **Describe alternatives you've considered** -A clear and concise description of any alternative solutions or features you've considered. - **Additional context** -Add any other context or screenshots about the feature request here. diff --git a/.github/ISSUE_TEMPLATE/question.md b/.github/ISSUE_TEMPLATE/question.md deleted file mode 100644 index 97323113..00000000 --- a/.github/ISSUE_TEMPLATE/question.md +++ /dev/null @@ -1,12 +0,0 @@ ---- -name: Question -about: Ask a question -labels: 'type: question, priority: p3' ---- - -Thanks for stopping by to ask us a question! Please make sure to include: -- What you're trying to do -- What code you've already tried -- Any error messages you're getting - -**PLEASE READ**: If you have a support contract with Google, please create an issue in the [support console](https://cloud.google.com/support/) instead of filing on GitHub. This will ensure a timely response. diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index bcc0d40c..b611a80b 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -11,7 +11,7 @@ jobs: matrix: node: [18, 20, 22] steps: - - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 + - uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4 - uses: actions/setup-node@v4 with: node-version: ${{ matrix.node }} @@ -29,7 +29,7 @@ jobs: windows: runs-on: windows-latest steps: - - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 + - uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4 - uses: actions/setup-node@v4 with: node-version: 18 @@ -40,7 +40,7 @@ jobs: lint: runs-on: ubuntu-latest steps: - - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 + - uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4 - uses: actions/setup-node@v4 with: node-version: 18 diff --git a/.jsdoc.js b/.jsdoc.js index 5596afee..a521abe2 100644 --- a/.jsdoc.js +++ b/.jsdoc.js @@ -31,7 +31,7 @@ module.exports = { source: { excludePattern: '(^|\\/|\\\\)[._]', include: [ - 'src', + 'build/src', ], includePattern: '\\.js$' }, diff --git a/CHANGELOG.md b/CHANGELOG.md index b2848303..ba31befa 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,13 @@ [1]: https://www.npmjs.com/package/google-auth-library?activeTab=versions +## [9.14.2](https://github.com/googleapis/google-auth-library-nodejs/compare/v9.14.1...v9.14.2) (2024-10-09) + + +### Bug Fixes + +* Disable Universe Domain Check ([#1878](https://github.com/googleapis/google-auth-library-nodejs/issues/1878)) ([8adb44c](https://github.com/googleapis/google-auth-library-nodejs/commit/8adb44c738b88bfc44e57b0694c3815d138a40e5)) + ## [9.14.1](https://github.com/googleapis/google-auth-library-nodejs/compare/v9.14.0...v9.14.1) (2024-08-30) diff --git a/owlbot.py b/owlbot.py index 2ff4b9eb..d41bc272 100644 --- a/owlbot.py +++ b/owlbot.py @@ -22,5 +22,6 @@ node.owlbot_main( templates_excludes=[ ".github/workflows/ci.yaml", + ".github/ISSUE_TEMPLATE/bug_report.yml" ], ) diff --git a/package.json b/package.json index e617eebf..9a1570c9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "google-auth-library", - "version": "9.14.1", + "version": "9.14.2", "author": "Google Inc.", "description": "Google APIs Authentication Client Library for Node.js", "engines": { @@ -25,7 +25,6 @@ "jws": "^4.0.0" }, "devDependencies": { - "@compodoc/compodoc": "1.1.23", "@types/base64-js": "^1.2.5", "@types/chai": "^4.1.7", "@types/jws": "^3.1.0", @@ -42,6 +41,9 @@ "execa": "^5.0.0", "gts": "^5.0.0", "is-docker": "^2.0.0", + "jsdoc": "^4.0.0", + "jsdoc-fresh": "^3.0.0", + "jsdoc-region-tag": "^3.0.0", "karma": "^6.0.0", "karma-chrome-launcher": "^3.0.0", "karma-coverage": "^2.0.0", @@ -56,6 +58,7 @@ "ncp": "^2.0.0", "nock": "^13.0.0", "null-loader": "^4.0.0", + "pdfmake": "0.2.12", "puppeteer": "^21.0.0", "sinon": "^18.0.0", "ts-loader": "^8.0.0", @@ -75,7 +78,7 @@ "compile": "tsc -p .", "fix": "gts fix", "pretest": "npm run compile -- --sourceMap", - "docs": "compodoc src/", + "docs": "jsdoc -c .jsdoc.json", "samples-setup": "cd samples/ && npm link ../ && npm run setup && cd ../", "samples-test": "cd samples/ && npm link ../ && npm test && cd ../", "system-test": "mocha build/system-test --timeout 60000", diff --git a/samples/package.json b/samples/package.json index dc45153a..76c03ec0 100644 --- a/samples/package.json +++ b/samples/package.json @@ -16,7 +16,7 @@ "@google-cloud/language": "^6.5.0", "@google-cloud/storage": "^7.0.0", "@googleapis/iam": "^21.0.0", - "google-auth-library": "^9.14.1", + "google-auth-library": "^9.14.2", "node-fetch": "^2.3.0", "open": "^9.0.0", "server-destroy": "^1.0.1" diff --git a/src/auth/googleauth.ts b/src/auth/googleauth.ts index 3d08ec7f..b211d7c9 100644 --- a/src/auth/googleauth.ts +++ b/src/auth/googleauth.ts @@ -457,12 +457,6 @@ export class GoogleAuth { // Determine if we're running on GCE. if (await this._checkIsGCE()) { - // set universe domain for Compute client - if (!originalOrCamelOptions(options).get('universe_domain')) { - options.universeDomain = - await this.getUniverseDomainFromMetadataServer(); - } - (options as ComputeOptions).scopes = this.getAnyScopes(); return await this.#prepareAndCacheClient(new Compute(options)); } diff --git a/test/test.googleauth.ts b/test/test.googleauth.ts index 495585df..09853af4 100644 --- a/test/test.googleauth.ts +++ b/test/test.googleauth.ts @@ -1149,9 +1149,8 @@ describe('googleauth', () => { it('getCredentials should get metadata from the server when running on GCE', async () => { const clientEmail = 'test-creds@test-creds.iam.gserviceaccount.com'; - const universeDomain = 'my-amazing-universe.com'; const scopes = [ - nockIsGCE({universeDomain}), + nockIsGCE(), createGetProjectIdNock(), nock(host).get(svcAccountPath).reply(200, clientEmail, HEADERS), ]; @@ -1160,7 +1159,6 @@ describe('googleauth', () => { const body = await auth.getCredentials(); assert.ok(body); assert.strictEqual(body.client_email, clientEmail); - assert.strictEqual(body.universe_domain, universeDomain); assert.strictEqual(body.private_key, undefined); scopes.forEach(s => s.done()); }); @@ -1644,14 +1642,6 @@ describe('googleauth', () => { assert.notEqual(universe_domain, DEFAULT_UNIVERSE); assert.equal(await auth.getUniverseDomain(), universe_domain); }); - - it('should use the metadata service if on GCP', async () => { - const universeDomain = 'my.universe.com'; - const scope = nockIsGCE({universeDomain}); - - assert.equal(await auth.getUniverseDomain(), universeDomain); - await scope.done(); - }); }); function mockApplicationDefaultCredentials(path: string) {