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

Add a new VertexAI error type #8240

Open
wants to merge 17 commits into
base: master
Choose a base branch
from
Open

Conversation

dlarocque
Copy link
Contributor

@dlarocque dlarocque commented May 9, 2024

  • Added VertexAIError so that users can instanceof the errors from the VertexAI SDK.
  • Added optional HTTP fields to errors (status, statusText, errorDetails) (mirroring google-gemini/generative-ai-js@111e970)
  • Moved away from using ErrorFactory towards our new error type
  • Added a generic error code VertexAIErrorCode.ERROR to align with the generic error in the Google AI SDK GoogleGenerativeAIError

Testing

I tested this in a React application in Chrome and Safari, and in a Node project.
instanceof and the stack trace works in these environments.

Error output in different environments

Safari

image

Chrome

image

Node

VertexAIError [FirebaseError]: Error fetching from https://firebaseml.googleapis.com/v2beta/projects/<omitted>/locations/us-central1/publishers/google/models/gemini-1.5-pro-preview-0409:generateContent: [400 Bad Request] Invalid value at 'contents[0].parts[0].text' (TYPE_STRING), 1 [{"@type":"type.googleapis.com/google.rpc.BadRequest","fieldViolations":[{"field":"contents[0].parts[0].text","description":"Invalid value at 'contents[0].parts[0].text' (TYPE_STRING), 1"}]}]
    at makeRequest (/Users/dlarocque/workspace/firebase/firebase-js-sdk/packages/vertexai/dist/index.cjs.js:408:19)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async generateContent (/Users/dlarocque/workspace/firebase/firebase-js-sdk/packages/vertexai/dist/index.cjs.js:747:22)
    at async run (/Users/dlarocque/workspace/test/vertex-gcs-filedata/index.js:19:20) {
  code: 'fetch-error',
  customData: undefined,
  status: 400,
  statusText: 'Bad Request',
  errorDetails: [
    {
      '@type': 'type.googleapis.com/google.rpc.BadRequest',
      fieldViolations: [
        {
          field: 'contents[0].parts[0].text',
          description: "Invalid value at 'contents[0].parts[0].text' (TYPE_STRING), 1"
        }
      ]
    }
  ],
  toString: [Function (anonymous)]
}

@dlarocque dlarocque requested a review from hsubox76 May 9, 2024 20:20
@dlarocque dlarocque requested a review from a team as a code owner May 9, 2024 20:20
Copy link

changeset-bot bot commented May 9, 2024

🦋 Changeset detected

Latest commit: 646340f

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
Name Type
@firebase/vertexai-preview Patch
firebase Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@dlarocque dlarocque requested review from a team as code owners May 9, 2024 20:22
@google-oss-bot
Copy link
Contributor

google-oss-bot commented May 9, 2024

Size Report 1

Affected Products

  • @firebase/auth-cordova

    TypeBase (aa060a7)Merge (cb386b5)Diff
    browser?210 kB? (?)
    module?210 kB? (?)
  • @firebase/auth-web-extension

    TypeBase (aa060a7)Merge (cb386b5)Diff
    browser?137 kB? (?)
    main?152 kB? (?)
    module?137 kB? (?)
  • @firebase/vertexai-preview

    TypeBase (aa060a7)Merge (cb386b5)Diff
    browser25.2 kB25.4 kB+248 B (+1.0%)
    main25.8 kB26.0 kB+269 B (+1.0%)
    module25.2 kB25.4 kB+248 B (+1.0%)
  • firebase

    TypeBase (aa060a7)Merge (cb386b5)Diff
    firebase-vertexai-preview.js19.3 kB19.6 kB+309 B (+1.6%)

Test Logs

  1. https://storage.googleapis.com/firebase-sdk-metric-reports/ksEUxT8WMy.html

@google-oss-bot
Copy link
Contributor

google-oss-bot commented May 9, 2024

Size Analysis Report 1

Affected Products

  • @firebase/vertexai-preview

    • BlockReason

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size3.67 kB2.94 kB-724 B (-19.7%)
      size-with-ext-deps21.4 kB20.7 kB-703 B (-3.3%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      variables

      15 dependencies

      BlockReason
      DEFAULT_LOCATION
      ERRORS
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      14 dependencies

      BlockReason
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      - ERRORS

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      - ErrorFactory

    • ChatSession

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size14.4 kB14.1 kB-312 B (-2.2%)
      size-with-ext-deps32.8 kB32.5 kB-308 B (-0.9%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      classes

      ChatSession
      RequestUrl
      VertexAIService

      ChatSession
      RequestUrl
      VertexAIError
      VertexAIService

      + VertexAIError

      variables

      27 dependencies

      BlockReason
      DEFAULT_API_VERSION
      DEFAULT_BASE_URL
      DEFAULT_LOCATION
      ERRORS
      ERROR_FACTORY
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      LANGUAGE_TAG
      PACKAGE_VERSION
      POSSIBLE_ROLES
      SILENT_ERROR
      Task
      VALID_PARTS_PER_ROLE
      VALID_PART_FIELDS
      VALID_PREVIOUS_CONTENT_ROLES
      VERTEX_TYPE
      badFinishReasons
      name
      responseLineRE
      version

      25 dependencies

      BlockReason
      DEFAULT_API_VERSION
      DEFAULT_BASE_URL
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      LANGUAGE_TAG
      PACKAGE_VERSION
      POSSIBLE_ROLES
      SILENT_ERROR
      Task
      VALID_PARTS_PER_ROLE
      VALID_PART_FIELDS
      VALID_PREVIOUS_CONTENT_ROLES
      VERTEX_TYPE
      badFinishReasons
      name
      responseLineRE
      version

      - ERRORS
      - ERROR_FACTORY

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      FirebaseError

      + FirebaseError
      - ErrorFactory

    • FinishReason

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size3.67 kB2.94 kB-724 B (-19.7%)
      size-with-ext-deps21.4 kB20.7 kB-703 B (-3.3%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      variables

      15 dependencies

      BlockReason
      DEFAULT_LOCATION
      ERRORS
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      14 dependencies

      BlockReason
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      - ERRORS

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      - ErrorFactory

    • FunctionCallingMode

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size3.67 kB2.95 kB-724 B (-19.7%)
      size-with-ext-deps21.4 kB20.7 kB-703 B (-3.3%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      variables

      15 dependencies

      BlockReason
      DEFAULT_LOCATION
      ERRORS
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      14 dependencies

      BlockReason
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      - ERRORS

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      - ErrorFactory

    • FunctionDeclarationSchemaType

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size3.68 kB2.96 kB-724 B (-19.7%)
      size-with-ext-deps21.4 kB20.7 kB-703 B (-3.3%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      variables

      15 dependencies

      BlockReason
      DEFAULT_LOCATION
      ERRORS
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      14 dependencies

      BlockReason
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      - ERRORS

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      - ErrorFactory

    • GenerativeModel

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size16.7 kB16.6 kB-60 B (-0.4%)
      size-with-ext-deps35.1 kB35.0 kB-56 B (-0.2%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      classes

      ChatSession
      GenerativeModel
      RequestUrl
      VertexAIService

      ChatSession
      GenerativeModel
      RequestUrl
      VertexAIError
      VertexAIService

      + VertexAIError

      variables

      27 dependencies

      BlockReason
      DEFAULT_API_VERSION
      DEFAULT_BASE_URL
      DEFAULT_LOCATION
      ERRORS
      ERROR_FACTORY
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      LANGUAGE_TAG
      PACKAGE_VERSION
      POSSIBLE_ROLES
      SILENT_ERROR
      Task
      VALID_PARTS_PER_ROLE
      VALID_PART_FIELDS
      VALID_PREVIOUS_CONTENT_ROLES
      VERTEX_TYPE
      badFinishReasons
      name
      responseLineRE
      version

      25 dependencies

      BlockReason
      DEFAULT_API_VERSION
      DEFAULT_BASE_URL
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      LANGUAGE_TAG
      PACKAGE_VERSION
      POSSIBLE_ROLES
      SILENT_ERROR
      Task
      VALID_PARTS_PER_ROLE
      VALID_PART_FIELDS
      VALID_PREVIOUS_CONTENT_ROLES
      VERTEX_TYPE
      badFinishReasons
      name
      responseLineRE
      version

      - ERRORS
      - ERROR_FACTORY

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      FirebaseError

      + FirebaseError
      - ErrorFactory

    • HarmBlockMethod

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size3.67 kB2.95 kB-724 B (-19.7%)
      size-with-ext-deps21.4 kB20.7 kB-703 B (-3.3%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      variables

      15 dependencies

      BlockReason
      DEFAULT_LOCATION
      ERRORS
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      14 dependencies

      BlockReason
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      - ERRORS

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      - ErrorFactory

    • HarmBlockThreshold

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size3.67 kB2.95 kB-724 B (-19.7%)
      size-with-ext-deps21.4 kB20.7 kB-703 B (-3.3%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      variables

      15 dependencies

      BlockReason
      DEFAULT_LOCATION
      ERRORS
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      14 dependencies

      BlockReason
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      - ERRORS

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      - ErrorFactory

    • HarmCategory

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size3.67 kB2.94 kB-724 B (-19.7%)
      size-with-ext-deps21.4 kB20.7 kB-703 B (-3.3%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      variables

      15 dependencies

      BlockReason
      DEFAULT_LOCATION
      ERRORS
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      14 dependencies

      BlockReason
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      - ERRORS

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      - ErrorFactory

    • HarmProbability

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size3.67 kB2.95 kB-724 B (-19.7%)
      size-with-ext-deps21.4 kB20.7 kB-703 B (-3.3%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      variables

      15 dependencies

      BlockReason
      DEFAULT_LOCATION
      ERRORS
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      14 dependencies

      BlockReason
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      - ERRORS

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      - ErrorFactory

    • HarmSeverity

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size3.67 kB2.94 kB-724 B (-19.7%)
      size-with-ext-deps21.4 kB20.7 kB-703 B (-3.3%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      variables

      15 dependencies

      BlockReason
      DEFAULT_LOCATION
      ERRORS
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      14 dependencies

      BlockReason
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      - ERRORS

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      - ErrorFactory

    • POSSIBLE_ROLES

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size3.71 kB2.99 kB-724 B (-19.5%)
      size-with-ext-deps21.4 kB20.7 kB-703 B (-3.3%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      variables

      16 dependencies

      BlockReason
      DEFAULT_LOCATION
      ERRORS
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      POSSIBLE_ROLES
      Task
      VERTEX_TYPE
      name
      version

      15 dependencies

      BlockReason
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      POSSIBLE_ROLES
      Task
      VERTEX_TYPE
      name
      version

      - ERRORS

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      - ErrorFactory

    • VertexAIError

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size?3.27 kB? (?)
      size-with-ext-deps?21.0 kB? (?)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      functions?

      registerVertex

      ?
      classes?

      VertexAIError
      VertexAIService

      ?
      variables?

      14 dependencies

      BlockReason
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      ?
      enums??

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/app?

      _registerComponent
      registerVersion

      ?
      @firebase/component?

      Component

      ?
      @firebase/util?

      FirebaseError

      ?
    • getGenerativeModel

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size16.7 kB16.8 kB+22 B (+0.1%)
      size-with-ext-deps35.2 kB35.2 kB+26 B (+0.1%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      classes

      ChatSession
      GenerativeModel
      RequestUrl
      VertexAIService

      ChatSession
      GenerativeModel
      RequestUrl
      VertexAIError
      VertexAIService

      + VertexAIError

      variables

      27 dependencies

      BlockReason
      DEFAULT_API_VERSION
      DEFAULT_BASE_URL
      DEFAULT_LOCATION
      ERRORS
      ERROR_FACTORY
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      LANGUAGE_TAG
      PACKAGE_VERSION
      POSSIBLE_ROLES
      SILENT_ERROR
      Task
      VALID_PARTS_PER_ROLE
      VALID_PART_FIELDS
      VALID_PREVIOUS_CONTENT_ROLES
      VERTEX_TYPE
      badFinishReasons
      name
      responseLineRE
      version

      25 dependencies

      BlockReason
      DEFAULT_API_VERSION
      DEFAULT_BASE_URL
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      LANGUAGE_TAG
      PACKAGE_VERSION
      POSSIBLE_ROLES
      SILENT_ERROR
      Task
      VALID_PARTS_PER_ROLE
      VALID_PART_FIELDS
      VALID_PREVIOUS_CONTENT_ROLES
      VERTEX_TYPE
      badFinishReasons
      name
      responseLineRE
      version

      - ERRORS
      - ERROR_FACTORY

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory

      FirebaseError

      + FirebaseError
      - ErrorFactory

    • getVertexAI

      Size

      TypeBase (aa060a7)Merge (cb386b5)Diff
      size3.84 kB3.12 kB-719 B (-18.7%)
      size-with-ext-deps28.8 kB28.1 kB-703 B (-2.4%)

      Dependency

      TypeBase (aa060a7)Merge (cb386b5)Diff
      variables

      15 dependencies

      BlockReason
      DEFAULT_LOCATION
      ERRORS
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      14 dependencies

      BlockReason
      DEFAULT_LOCATION
      FinishReason
      FunctionCallingMode
      FunctionDeclarationSchemaType
      HarmBlockMethod
      HarmBlockThreshold
      HarmCategory
      HarmProbability
      HarmSeverity
      Task
      VERTEX_TYPE
      name
      version

      - ERRORS

      External Dependency

      ModuleBase (aa060a7)Merge (cb386b5)Diff
      @firebase/util

      ErrorFactory
      getModularInstance

      getModularInstance

      - ErrorFactory

Test Logs

  1. https://storage.googleapis.com/firebase-sdk-metric-reports/CyoYbsvpma.html

@dlarocque dlarocque removed the request for review from hsubox76 May 10, 2024 14:07
@dlarocque dlarocque marked this pull request as draft May 10, 2024 14:07
@dlarocque dlarocque marked this pull request as ready for review May 10, 2024 16:05
@dlarocque dlarocque requested a review from a team as a code owner May 10, 2024 16:05
Copy link
Contributor

@hsubox76 hsubox76 left a comment

Choose a reason for hiding this comment

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

I know this looks like a lot of comments but the core of this PR was pretty solid, it's a big rewrite of the whole error architecture, thanks for putting in all the work investigating and trying different approaches.

packages/vertexai/src/types/error.ts Outdated Show resolved Hide resolved
packages/vertexai/src/types/error.ts Outdated Show resolved Hide resolved
packages/vertexai/src/types/error.ts Outdated Show resolved Hide resolved
packages/vertexai/src/types/error.ts Outdated Show resolved Hide resolved
packages/vertexai/src/api.ts Outdated Show resolved Hide resolved
packages/vertexai/src/requests/response-helpers.ts Outdated Show resolved Hide resolved
packages/vertexai/src/requests/response-helpers.ts Outdated Show resolved Hide resolved
packages/vertexai/src/types/error.ts Outdated Show resolved Hide resolved
packages/vertexai/src/types/error.ts Outdated Show resolved Hide resolved
@dlarocque dlarocque requested a review from hsubox76 May 13, 2024 15:09
Copy link
Contributor

@hsubox76 hsubox76 left a comment

Choose a reason for hiding this comment

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

Looks good! One more real comment and some nits.

.changeset/light-cheetahs-arrive.md Outdated Show resolved Hide resolved
packages/vertexai/src/types/error.ts Outdated Show resolved Hide resolved
packages/vertexai/src/api.ts Outdated Show resolved Hide resolved
@dlarocque dlarocque requested a review from hsubox76 May 31, 2024 20:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants