Skip to content
This repository has been archived by the owner on May 5, 2021. It is now read-only.

Forward slash in folder name breaks export #169

Open
sciurus opened this issue Jan 14, 2020 · 1 comment
Open

Forward slash in folder name breaks export #169

sciurus opened this issue Jan 14, 2020 · 1 comment

Comments

@sciurus
Copy link

sciurus commented Jan 14, 2020

In Grafana, I created a folder name Test / Folder. Inside that folder I created a dashboard named A Test Dashboard.

The dashboard fails to export with the error

✘ Dashboard a-test-dashboard import failed: Error: ENOENT: no such file or directory, mkdir 'dashboards/Test / Folder'

I tried creating a dashboard with name Test / Dashboard in the General folder and it was successfully exported as test-dashboard.

It looks like

return fileNameWithExtension.replace(/\.[^/.]+$/, '');
is used to sanitize the names of files but not of directories.

@Sytten
Copy link
Member

Sytten commented Jan 15, 2020

Good catch, I will sanitize the folder name thanks for reporting. I plan to start working on wizzy next week. Please comment back if its not fixed soon.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants