question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

BUG: In 3.5.1 grid.y.show = true breaks if there is a y2 axis but no y axis

See original GitHub issue

Description

In version 3.5.1, when a chart:

  • has a y2 axis
  • does NOT have a y axis
  • has grid.y.show = true

the generation breaks after drawing the axes:

immagine

Conceptually this makes sense, but it did NOT happen in version 3.4.1.

Steps to check or reproduce

The following chart configuration produces the bug:

{
  "bindto": "#lineChart", 

  "data": {
    "rows": [
      [ "Bar", "Line_1", "Line_2" ],
      [ 0.5, 2, 1 ],
      [ 3, 1, 2 ],
      [ 2, 1, 3 ],
      [ 1, 2.5, 0.5 ],
      [ 2, 1, 0 ],
      [ 1.5, 2, 1 ],
      [ 0, 2, 1 ],
      [ 0.5, 1, 3 ],
      [ 1, 1, 2 ],
      [ 2, 1, 1 ],
      [ 0.5, 1, 2 ],
      [ 1, 0.5, 3 ]
    ],
    "types": {
      "Line_1": "line",
      "Line_2": "line",
    },
    "type": "bar",
    "axes": {
      "Bar": "y2",
      "Line_1": "y2",
      "Line_2": "y2"
    }
  },
  "axis": {
    "x": {
      "type": "category",
      "categories": [ "gen", "feb", "mar", "apr", "mag", "giu", "lug", "ago", "set", "ott", "nov", "dic" ],
      "clipPath": false
    },
    "y": {
      "show": false
    },
    "y2": {
      "show": true,
      "padding": { "bottom": 0 },
      "min": 0,
      "max": 3
    }
  },
  "grid": {
    "y": {
      "show": true // this breaks the chart
    }
  }
}

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
netilcommented, Sep 8, 2022

Next release will out on this month.

1reaction
netilcommented, Aug 26, 2022

Hi @m-gallesio, it seems duplicated and already fixed(with the issue you mentioned). From the latest build from the master, it renders without issue.

image

Try with the nightly build

Read more comments on GitHub >

github_iconTop Results From Across the Web

[BUG] Ticks should align when multiple Y axis for line and bar ...
Current Behavior. Y ticks does not align and show extra grid lines. Possible Solution. In this sample, it show only one Y-axis grid...
Read more >
How do I align gridlines for two y-axis scales using Matplotlib?
Is there a way to make the ticks and gridlines aligned on both y-axes? The first image shows what I get, and the...
Read more >
Axis Options for LAYOUT OVERLAY - SAS Help Center
For the Y and Y2 axes, the label is oriented vertically and is centered in the axis tick display area (excluding the offsets)....
Read more >
plotting - Custom Grid Lines for ProbabilityScalePlot
It appears that it's correctly assigning something to the x and y axis, but based on the error I assume that it's not...
Read more >
Mathematics 1 Problem Sets - Phillips Exeter Academy
If don't know how to perform a needed action, there are many resources available online. Also, if you are asked to “graph y...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found