Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename Interface form_factor to type #2920

Closed
jeremystretch opened this issue Feb 21, 2019 · 3 comments
Closed

Rename Interface form_factor to type #2920

jeremystretch opened this issue Feb 21, 2019 · 3 comments
Labels
status: accepted This issue has been accepted for implementation
Milestone

Comments

@jeremystretch
Copy link
Member

jeremystretch commented Feb 21, 2019

Proposed Changes

Rename the form_factor field on the dcim.Interface model to type, and update forms and serializers accordingly.

Justification

"Form factor" is a misnomer given the field's purpose in conveying specific network technologies. For example, 100 Mbps and 1 Gbps Ethernet can both utilize the 8P8C copper form factor, but provide two different types of services and employ different wire protocols.

@jeremystretch jeremystretch added status: accepted This issue has been accepted for implementation API change type: housekeeping Changes to the application which do not directly impact the end user labels Feb 21, 2019
@jeremystretch jeremystretch added this to the v2.6 milestone Feb 21, 2019
@jeremystretch jeremystretch removed the type: housekeeping Changes to the application which do not directly impact the end user label Feb 22, 2019
@lampwins
Copy link
Contributor

lampwins commented Mar 4, 2019

@jeremystretch I think we should we allow a period of backward compatibility in the API. Say go ahead and change the model field but in the API continue to allow the use of form_factor for a period of time (I suggest until 2.7)? I foresee this being one of those nasty breaking changes for a lot of people and thus a reason to delay 2.6 adoption.

@jeremystretch
Copy link
Member Author

Yeah, I've been asking myself whether it's honestly worth the hassle. I suppose we could migrate the field name, then add a getter/setter named form_factor with a deprecation warning to retain backward compatibility until v2.7.

@jeremystretch
Copy link
Member Author

jeremystretch commented Apr 12, 2019

I've renamed form_factor to type but added a new form_factor field to replicate the functionality of type for backward compatibility. form_factor will be fully removed in NetBox v2.7.

aruhier pushed a commit to scaleway/netbox-netprod-importer that referenced this issue Jul 27, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Jan 16, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: accepted This issue has been accepted for implementation
Projects
None yet
Development

No branches or pull requests

2 participants