Skip to content

Field null in Override configuration is ignored. #413

Closed
@ipsusila

Description

@ipsusila

Hi, thank you for the nice software. I'm facing the following issue, in which the overrides settings was not applied properly.

When the configuration is:

overrides:
  - go_type: "sql.NullInt64"
    db_type: "integer"
    null: true

the null config value is not decoded properly. However, if I changed the configuration to (use "null" as field name)

overrides:
  - go_type: "sql.NullInt64"
    db_type: "integer"
    "null": true

sqlc will correctly override type as expected. In the former case, YAML decoder is failed to decode the configuration (the value is always false), perhaps because the field name is null.
Probably this issue is related to #412 too?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions