Update the tx_power field to be a double instead of an integer #7715

Closed
opened 2025-12-29 20:27:24 +01:00 by adam · 4 comments
Owner

Originally created by @BrunoBlanes on GitHub (Mar 3, 2023).

NetBox version

v3.4.5

Feature type

Change to existing functionality

Proposed functionality

I propose to update the afore mentioned field to a double in order to be more precise as to the power set and observed.

Use case

Although initially proposed on #7606 as a means to indicate configured transmit power, it became one too effective way of documenting the default transmit power of optical SFP modules in order to diagnose potencial degradation of performance over time.

Changing it to a double would improve this behavior by more accurately representing powers as given by most equipment:
image

Database changes

Probably a minor no breakable change.

External dependencies

None that I am aware of.

Originally created by @BrunoBlanes on GitHub (Mar 3, 2023). ### NetBox version v3.4.5 ### Feature type Change to existing functionality ### Proposed functionality I propose to update the afore mentioned field to a double in order to be more precise as to the power set and observed. ### Use case Although initially proposed on #7606 as a means to indicate configured transmit power, it became one too effective way of documenting the default transmit power of optical SFP modules in order to diagnose potencial degradation of performance over time. Changing it to a double would improve this behavior by more accurately representing powers as given by most equipment: ![image](https://user-images.githubusercontent.com/28227097/222719468-faf1a5ca-ed09-4cd2-bbab-11ab27628d27.png) ### Database changes Probably a minor no breakable change. ### External dependencies None that I am aware of.
adam added the type: featurepending closurestatus: under review labels 2025-12-29 20:27:24 +01:00
adam closed this issue 2025-12-29 20:27:24 +01:00
Author
Owner

@jeremystretch commented on GitHub (May 4, 2023):

I propose to update the afore mentioned field to a double in order to be more precise as to the power set and observed.

I assume you mean a decimal (float)?

Although initially proposed on https://github.com/netbox-community/netbox/issues/7606 as a means to indicate configured transmit power, it became one too effective way of documenting the default transmit power of optical SFP modules in order to diagnose potencial degradation of performance over time.

The purpose of the field is to track the configured value, so any change would require a use case relevant to this purpose. Can you provide one?

Probably a minor no breakable change.

This would be a breaking API change because the type of the field will change.

@jeremystretch commented on GitHub (May 4, 2023): > I propose to update the afore mentioned field to a double in order to be more precise as to the power set and observed. I assume you mean a decimal (float)? > Although initially proposed on https://github.com/netbox-community/netbox/issues/7606 as a means to indicate configured transmit power, it became one too effective way of documenting the default transmit power of optical SFP modules in order to diagnose potencial degradation of performance over time. The purpose of the field is to track the _configured_ value, so any change would require a use case relevant to this purpose. Can you provide one? > Probably a minor no breakable change. This would be a breaking API change because the type of the field will change.
Author
Owner

@BrunoBlanes commented on GitHub (May 4, 2023):

I assume you mean a decimal (float)?

Yes.

The purpose of the field is to track the configured value, so any change would require a use case relevant to this purpose. Can you provide one?

The idea is to use this field when installing a new optical transceiver and document its initial power output so that we would be able to compare it later and see how it has degraded.

Usually they have an operational range (see this datasheet) which means that its power output could vary a lot from one to another, in the case of this model it could vary up to 5dB, and so being able to refer to its actual initial power output (with multiple decimal place precision) means I'd be able to approximate a date in the future when it would be out of range and in need of replacement.

@BrunoBlanes commented on GitHub (May 4, 2023): > I assume you mean a decimal (float)? Yes. > The purpose of the field is to track the configured value, so any change would require a use case relevant to this purpose. Can you provide one? The idea is to use this field when installing a new optical transceiver and document its initial power output so that we would be able to compare it later and see how it has degraded. Usually they have an operational range (see [this datasheet](http://cn.opwaytech.com/szsgwg202103054174/uploads/allimg/210726/3-210H6163035493.pdf)) which means that its power output could vary a lot from one to another, in the case of this model it could vary up to *5dB*, and so being able to refer to its actual initial power output (with multiple decimal place precision) means I'd be able to approximate a date in the future when it would be out of range and in need of replacement.
Author
Owner

@github-actions[bot] commented on GitHub (Aug 24, 2023):

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. NetBox is governed by a small group of core maintainers which means not all opened issues may receive direct feedback. Do not attempt to circumvent this process by "bumping" the issue; doing so will result in its immediate closure and you may be barred from participating in any future discussions. Please see our contributing guide.

@github-actions[bot] commented on GitHub (Aug 24, 2023): This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. NetBox is governed by a small group of core maintainers which means not all opened issues may receive direct feedback. **Do not** attempt to circumvent this process by "bumping" the issue; doing so will result in its immediate closure and you may be barred from participating in any future discussions. Please see our [contributing guide](https://github.com/netbox-community/netbox/blob/develop/CONTRIBUTING.md).
Author
Owner

@github-actions[bot] commented on GitHub (Sep 23, 2023):

This issue has been automatically closed due to lack of activity. In an effort to reduce noise, please do not comment any further. Note that the core maintainers may elect to reopen this issue at a later date if deemed necessary.

@github-actions[bot] commented on GitHub (Sep 23, 2023): This issue has been automatically closed due to lack of activity. In an effort to reduce noise, please do not comment any further. Note that the core maintainers may elect to reopen this issue at a later date if deemed necessary.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#7715