https://pulumi.com logo
#typescript
Title
# typescript
a

adventurous-lighter-33507

02/12/2021, 8:25 PM
Hey all, I am trying to create a new relic one dashboard with a pie chart. Here is my code:
Copy code
import { OneDashboard, OneDashboardArgs } from "@pulumi/newrelic";
import { OneDashboardPage, OneDashboardPageWidgetPy } from "@pulumi/newrelic/types/input";
const pieWiget: OneDashboardPageWidgetPy = {
  column: 1,
  height: 3,
  row: 4,
  width: 4,
  nrqlQueries: [
    {
      accountId: 399786,
      query:
        "...",
    },
  ],
  title: "filter envs",
};
const page1: OneDashboardPage = {
  name: "Deployments",
  description: "Current deployments by environment",
  widgetPies: [pieWiget],
};

const deploymentsDashboardArgs: OneDashboardArgs = {
  name: "Deployments Dashboard",
  pages: [page1],
};

new OneDashboard("deployments", deploymentsDashboardArgs);
I am getting the following error:
Copy code
error: newrelic:index/oneDashboard:OneDashboard resource 'deployments' has a problem: page.0: invalid or unknown key: widget_pies
w

witty-candle-66007

02/12/2021, 8:59 PM
There may be an issue with the “pie” widget in the sdk. Do you see issues with any of the other widgets types?
a

adventurous-lighter-33507

02/12/2021, 9:05 PM
no, i have tried the rest and they seem fine
w

witty-candle-66007

02/12/2021, 9:06 PM
OK. I’m looking into the pie widget and respond once I know for sure.
👍 1
As suspected, there is an bug with the “pie” widget. I opened this issue: https://github.com/pulumi/pulumi-newrelic/issues/175
a

adventurous-lighter-33507

02/12/2021, 10:52 PM
great. thanks
3 Views