Skip to content

error: '3752' cannot be found in NormalFunction's oid #94

Description

@madflow

This is a drive-by bug report. I am just toying around with this library. No expectations.

import pgStructure from "pg-structure";

const db = await pgStructure(
  {
    database: "postgres",
    user: "postgres",
    password: "postgres",
  },
  {
    includeSchemas: ["public"],
  },
);
486 |     get(value, { key = this.defaultKey, fromIndex = 0, throwUnknown = this._throwUnknown, } = {}) {
487 |         const index = this.getIndex(value, { key, fromIndex });
488 |         if (throwUnknown && index === -1) {
489 |             const firstObjectElement = this.find((e) => typeof e === "object");
490 |             const possibleType = firstObjectElement && `${firstObjectElement.constructor.name}'s `;
491 |             throw new Error(`'${value}' cannot be found in ${possibleType || ""}${key}.`);
                        ^
error: '3752' cannot be found in NormalFunction's oid.
      at get (/pg-structure/node_modules/indexable-array/dist/index.js:491:19)
      at /pg-structure/node_modules/pg-structure/dist/main.js:237:22
      at forEach (:1:21)
      at addTriggers (/pg-structure/node_modules/pg-structure/dist/main.js:235:5)
      at addObjects (/pg-structure/dist/main.js:339:5)
      at /pg-structure/node_modules/pg-structure/dist/main.js:378:5

Bun v1.1.10 (macOS arm64)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions