Skip to content
This repository has been archived by the owner on Jul 9, 2020. It is now read-only.

Add hostname validator to Device.name #62

Closed
nemesifier opened this issue Oct 19, 2017 · 3 comments
Closed

Add hostname validator to Device.name #62

nemesifier opened this issue Oct 19, 2017 · 3 comments

Comments

@nemesifier
Copy link
Member

How to reproduce the issue: try to save a new device with name test device.
Result: netjsonconfig validation complains test device is not a valid hostname and the validation error is shown in the configuration section.
Fix: it would be better to show this validation error relating directly to the name field

@R9295
Copy link
Member

R9295 commented Dec 14, 2017

@nemesisdesign I was able to create a new device with the name set to test device. I didn't receive a validation error.

@R9295
Copy link
Member

R9295 commented Dec 14, 2017

no_validation_error

@nemesifier
Copy link
Member Author

try creating a new device and also a configuration (scroll down, click "add configuration")
the error is triggered by the configuration, which is a oneToOne optional relation between Device and Config

R9295 added a commit to R9295/django-netjsonconfig that referenced this issue Dec 19, 2017
R9295 added a commit to R9295/django-netjsonconfig that referenced this issue Dec 19, 2017
R9295 added a commit to R9295/django-netjsonconfig that referenced this issue Dec 19, 2017
R9295 added a commit to R9295/django-netjsonconfig that referenced this issue Dec 19, 2017
R9295 added a commit to R9295/django-netjsonconfig that referenced this issue Dec 20, 2017
R9295 added a commit to R9295/django-netjsonconfig that referenced this issue Dec 20, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants