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

Zod schema is generated with invalid types #1476

Open
nicholaschiang opened this issue Dec 17, 2024 · 3 comments
Open

Zod schema is generated with invalid types #1476

nicholaschiang opened this issue Dec 17, 2024 · 3 comments
Labels
bug Something isn't working @kubb/plugin-zod

Comments

@nicholaschiang
Copy link

nicholaschiang commented Dec 17, 2024

What version of kubb is running?

3.3.3

What kind of platform do you use?

MacOS

How does your kubb.config.ts config look like

import { defineConfig } from '@kubb/core'
import { pluginOas } from '@kubb/plugin-oas'
import { pluginTs } from '@kubb/plugin-ts'
import { pluginZod } from '@kubb/plugin-zod'
import { pluginReactQuery } from '@kubb/plugin-react-query'

export default defineConfig({
  root: '.',
  input: {
    path: './openapi.json',
  },
  output: {
    path: './app/kubb',
    extension: { '.ts': '', '.tsx': '', '.js': '', '.json': '.json' },
  },
  plugins: [
    pluginOas(),
    pluginTs({
      enumType: 'enum',
      enumSuffix: '',
      unknownType: 'unknown',
    }),
    pluginZod({
      unknownType: 'unknown',
    }),
    pluginReactQuery({
      paramsType: 'object',
      client: {
        importPath: '~/client/kubb',
      },
      mutation: {
        importPath: '~/client/kubb',
      },
      suspense: false,
    }),
  ],
})

Swagger/OpenAPI file?

The full openapi.json file was too large to include in the issue text. You can find it here instead.

What version of external packages are you using(@tanstack-query, MSW, React, Vue, ...)

No response

What steps can reproduce the bug?

  1. Attempt to create the Zod schemas for the openapi.json file included above using the configuration provided:
$ pnpm exec kubb generate
  1. Open the generated kubb/zod/accountSettingsSchema.ts Zod schema file.
  2. Either run TS yourself or use your IDE's linter.
$ pnpm tsc
  1. Notice that the default values are not compatible with the schema types:
Screenshot 2024-12-17 at 12 54 39 PM

Here's an incomplete output of errors from TS (the complete output is too large for GitHub):

app/kubb/zod/clientSafeAccountSettingsSchema.ts:11:100 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

11     setting_admin_and_superuser_can_edit: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                                      ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:12:86 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

12     setting_admin_can_edit: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                        ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:13:90 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

13     setting_superuser_can_edit: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                            ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:14:90 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

14     setting_not_sent_to_client: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                            ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:15:83 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

15     show_data_dev_tools: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                     ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:16:88 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

16     enable_multiview_support: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                          ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:17:88 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

17     enable_copy_from_example: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                          ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:18:78 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

18     show_charts_v2: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:19:98 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

19     fuzzy_filter_cardinality_threshold: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                                    ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:20:106 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

20     dataset_update_existing_dimensions_metrics: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                                            ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:21:87 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

21     dataset_include_metrics: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                         ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:22:102 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

22     dataset_initial_dimension_metric_state: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                                        ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:23:91 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

23     dataset_num_rows_to_profile: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                             ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:24:106 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

24     dataset_top_k_profile_values_for_retrieval: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                                            ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:25:80 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

25     is_chats_default: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                  ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:26:81 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

26     is_widget_default: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                   ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:27:84 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

27     show_widget_settings: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                      ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:28:85 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

28     show_streamlit_button: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                       ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:29:84 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

29     use_onboarding_agent: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                      ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:30:90 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

30     use_predictive_model_agent: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                            ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:31:84 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

31     add_dms_from_reports: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                      ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:32:81 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

32     use_knowledge_sql: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                   ~~


app/kubb/zod/clientSafeAccountSettingsSchema.ts:33:81 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' is missing the following properties from type '{ value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }': value, name, description, value_object, and 2 more.
  Overload 2 of 2, '(def: () => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }): ZodDefault<...>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.
      Type '{}' provides no match for the signature '(): { value: string | number | boolean | null; name: string; description: string; value_object: { value: string | number | boolean | null; }; is_superuser_editable: boolean; is_admin_editable: boolean; ... 4 more ...; is_test?: boolean | undefined; }'.

33     grouping_strategy: z.lazy(() => clientSettingUnionBoolIntStrSchema).default({}),
                                                                                   ~~


app/kubb/zod/conversationBasicSchema.ts:11:58 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { read: boolean; write: boolean; }): ZodDefault<ZodLazy<ZodObject<{ read: ZodBoolean; write: ZodBoolean; }, "strip", ZodTypeAny, { read: boolean; write: boolean; }, { ...; }>>>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ read: boolean; write: boolean; }'.
      Type '{}' is missing the following properties from type '{ read: boolean; write: boolean; }': read, write
  Overload 2 of 2, '(def: () => { read: boolean; write: boolean; }): ZodDefault<ZodLazy<ZodObject<{ read: ZodBoolean; write: ZodBoolean; }, "strip", ZodTypeAny, { read: boolean; write: boolean; }, { ...; }>>>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { read: boolean; write: boolean; }'.
      Type '{}' provides no match for the signature '(): { read: boolean; write: boolean; }'.

11     permissions: z.lazy(() => permissionsSchema).default({}),
                                                            ~~


app/kubb/zod/conversationFullSchema.ts:13:58 - error TS2769: No overload matches this call.
  Overload 1 of 2, '(def: { read: boolean; write: boolean; }): ZodDefault<ZodLazy<ZodObject<{ read: ZodBoolean; write: ZodBoolean; }, "strip", ZodTypeAny, { read: boolean; write: boolean; }, { ...; }>>>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '{ read: boolean; write: boolean; }'.
      Type '{}' is missing the following properties from type '{ read: boolean; write: boolean; }': read, write
  Overload 2 of 2, '(def: () => { read: boolean; write: boolean; }): ZodDefault<ZodLazy<ZodObject<{ read: ZodBoolean; write: ZodBoolean; }, "strip", ZodTypeAny, { read: boolean; write: boolean; }, { ...; }>>>', gave the following error.
    Argument of type '{}' is not assignable to parameter of type '() => { read: boolean; write: boolean; }'.
      Type '{}' provides no match for the signature '(): { read: boolean; write: boolean; }'.

13     permissions: z.lazy(() => permissionsSchema).default({}),

How often does this bug happen?

None

What is the expected behavior?

Kubb should provide default values that conform with the schema types or simply omit the default values entirely.

Additional information

No response

@nicholaschiang nicholaschiang added the bug Something isn't working label Dec 17, 2024
@nicholaschiang
Copy link
Author

I can temporarily get around the issue by adding a // @ts-nocheck at the beginning of each file:

pluginZod({
  output: { path: 'zod', banner: '// @ts-nocheck' },
})

@stijnvanhulle
Copy link
Collaborator

@nicholaschiang This is likely due to some of your definitions having a required field. If the default is set to {}, it will trigger an error for the missing required properties. We may need to either adjust Kubb's settings to be less strict or modify your Swagger/OpenAPI file accordingly.

@nicholaschiang
Copy link
Author

How do I adjust Kubb's settings to be less strict?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working @kubb/plugin-zod
Projects
None yet
Development

No branches or pull requests

2 participants