Skip to content

dotenv format in 3.6 is incompatible with version 3.5 #702

@mltsy

Description

@mltsy

After this change: #622

A dotenv file generated by 3.6.0 is not readable by SOPS 3.5 or earlier, because of the newly added single quotes around every value (which the old SOPS seems to be unable to parse). I'm not sure whether this kind of change should be considered a breaking change or not, but given a typical use case (where you encrypt in one place and decrypt in another place), it's certainly not uncommon for one side to be using a different version than the other, so it's definitely pseudo-breaking.

One potential solution is to remember whether the file had quotes or not, and don't add quotes to a file that didn't have quotes (unless some flag is passed). Another one might be a flag that can omit the dotenv quotes, like --omit-dotenv-quotes so that people running into this problem can at least generate a file in the old style without downgrading SOPS (it would be nice in this case if it were also a config setting in sops.yaml)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions