Skip to content

make_subplots error message when spacing is impossible #2556

Closed
@nicolaskruchten

Description

@nicolaskruchten

Trivial example... no positive row-height can satisfy 3 rows with two 0.51-height gaps between them.

from plotly.subplots import make_subplots
fig = make_subplots(rows=3, vertical_spacing=0.51)

The error message is:

ValueError: 
    Invalid value of type 'builtins.float' received for the 'domain[0]' property of layout.yaxis
        Received value: 1.2666666666666666

    The 'domain[0]' property is a number and may be specified as:
      - An int or float in the interval [0, 1]

but it should be something more akin to "no way to satisfy vertical_spacing and rows simultaneously"

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions