8000 [feedback] format mac does not work in swagger:strfmt · Issue #1348 · go-swagger/go-swagger · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
[feedback] format mac does not work in swagger:strfmt #1348
Closed
go-openapi/validate
#60
@allencloud

Description

@allencloud

Problem statement

I ran into an issue that I wish swagger could help me to validate MAC address in struct defined in swagger.yml, like:

      MacAddress:
        description: "MAC address of the container."
        type: "string"
        format: mac

Then the generated struct has a validation function to validate the mac format of this field.

However it fails.

Could we support this feature in go-swagger?

Swagger specification

Steps to reproduce

Environment

swagger version: version: 0.12.0
go version: go version go1.9.1 darwin/amd64
OS:

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0