Skip to content

Require normalized project names #311

@mbland

Description

@mbland

What is the problem you're trying to solve

compose-spec/compose-go#261 changed docker compose behavior to require normalized project names as input, instead of normalizing project names automatically. This landed in compose-spec/compose-go v1.2.5 and docker/compose v2.5.1.

However, the current error message "... is not a valid project name" gives no indication why a name isn't valid. This is surprising for users whose previously working project names no longer work with newer versions of docker compose. The valid format also isn't yet documented anywhere.

Describe the solution you'd like

An update to the spec to document the valid format may be in order (unless there are issues with other implementations besides docker compose preventing that). Following that, possibly updates to:

I've drafted a patch in the update-project-name-spec branch of my mbland/compose-spec fork. If the change is acceptable, I'd also be willing to update WithName from cli/options.go in the compose-spec/compose-go repo to expand upon the error message.

Additional context

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