Rendering of rack reservations is poor #7313

Closed
opened 2025-12-29 20:21:40 +01:00 by adam · 3 comments
Owner

Originally created by @candlerb on GitHub (Dec 2, 2022).

NetBox version

v3.3.9

Python version

3.8

Steps to Reproduce

  1. Create a rack. (Any rack; doesn't matter if it has devices in it or not)
  2. Create a 1U reservation
  3. Render the rack elevation

image

Expected Behavior

In older versions of Netbox, it used to be the case that the reservation area was hatched out.

Observed Behavior

It's very weird: a small piece of hatching sits to the side of the rack.

image

This is viewed using Chrome 107 under macOS 12.6.1.

(This has actually been broken for a while and I don't remember when it first started happening, but I've only just got around to reporting it)

Originally created by @candlerb on GitHub (Dec 2, 2022). ### NetBox version v3.3.9 ### Python version 3.8 ### Steps to Reproduce 1. Create a rack. (Any rack; doesn't matter if it has devices in it or not) 2. Create a 1U reservation 3. Render the rack elevation ![image](https://user-images.githubusercontent.com/44789/205256804-51287958-6036-4e1f-b33e-b8d6c01a0f84.png) ### Expected Behavior In older versions of Netbox, it used to be the case that the reservation area was hatched out. ### Observed Behavior It's very weird: a small piece of hatching sits *to the side* of the rack. ![image](https://user-images.githubusercontent.com/44789/205256670-d561f339-2d89-4cc8-a471-1e2b2d45a7d3.png) This is viewed using Chrome 107 under macOS 12.6.1. (This has actually been broken for a while and I don't remember when it first started happening, but I've only just got around to reporting it)
adam closed this issue 2025-12-29 20:21:40 +01:00
Author
Owner

@candlerb commented on GitHub (Dec 2, 2022):

Another example: new 42U rack, no devices, reservation at position 3.

image

Also upgraded to Chrome 108, no difference.

@candlerb commented on GitHub (Dec 2, 2022): Another example: new 42U rack, no devices, reservation at position 3. ![image](https://user-images.githubusercontent.com/44789/205258081-3866e9fc-639d-41e3-8b27-c27c6587fa60.png) Also upgraded to Chrome 108, no difference.
Author
Owner

@candlerb commented on GitHub (Dec 2, 2022):

Hmm, so checking in the source code, this is intentional:

    def draw_margin(self):
        """
        Draw any rack reservations in the right-hand margin alongside the rack elevation.
        """

In that case, I think the chosen rendering is not good. It certainly looks like a bug, at least for a 1U reservation. It's not quite so bad for a large reservation, but still looks odd to me with the wide stripes:

image

Perhaps it would be better to have an icon next to each reserved unit?

I guess the reason for moving this was for the case where a unit contains a reservation and a device?

@candlerb commented on GitHub (Dec 2, 2022): Hmm, so checking in the source code, this is intentional: ``` def draw_margin(self): """ Draw any rack reservations in the right-hand margin alongside the rack elevation. """ ``` In that case, I think the chosen rendering is not good. It certainly *looks* like a bug, at least for a 1U reservation. It's not quite so bad for a large reservation, but still looks odd to me with the wide stripes: ![image](https://user-images.githubusercontent.com/44789/205260579-1b5948e5-41ac-4d96-a43a-6405c9f30fdb.png) Perhaps it would be better to have an icon next to each reserved unit? I guess the reason for moving this was for the case where a unit contains a reservation *and* a device?
Author
Owner

@jeremystretch commented on GitHub (Dec 2, 2022):

This is working as intended and was included in the v3.3 beta for review and testing. Please see #4350.

@jeremystretch commented on GitHub (Dec 2, 2022): This is working as intended and was included in the v3.3 beta for review and testing. Please see #4350.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#7313