You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We implemented this code to duplicate a Metabase collection and change the data source.
The downloaded data fom Metabase (via API) includes the following structure:
collections
collection 1
collection 2
collection 3
cards
dashboards
snippets
The code successfully duplicates the following while changing the data source:
cards
the dashboard
the collections
However, it does not duplicate dashboard tabs.
Environment
Metabase Version: v1.50.32
Ruby Version: 3.3.6
Steps to reproduce
Create a collection in metabase with:
A collection that stores queries using field filters
A dashboard with tabs and filters
Expected behavior
After importing the duplicated collection to Metabase, both the original and the duplicated dashboards should contain all tabs, with queries functioning as expected.
Actual behavior
After importing, the original dashboard appears without tabs, and queries fail.
Problem
We suspect this issue arises because the duplicated dashboards (which have unique IDs) are internally referencing the same tabs, a configuration Metabase may not support.
Possible solution
The clone.rb script does not currently address tabs. Extending it to include tabs might resolve this issue.
The text was updated successfully, but these errors were encountered:
this is just meant to be a prototype to demonstrate feasibility. I would not recommend using this in production and I am not surprised but there are edge cases that don't work. I tested this with x-rays and they don't have tabs.
You are welcome to use this code as guideline to create your own implementation. As an alternative, you could try looking at the yaml and the code and submit a patch that works. I would be happy to review it.
Description
We implemented this code to duplicate a Metabase collection and change the data source.
The downloaded data fom Metabase (via API) includes the following structure:
The code successfully duplicates the following while changing the data source:
However, it does not duplicate dashboard tabs.
Environment
Metabase Version: v1.50.32
Ruby Version: 3.3.6
Steps to reproduce
Create a collection in metabase with:
Expected behavior
After importing the duplicated collection to Metabase, both the original and the duplicated dashboards should contain all tabs, with queries functioning as expected.
Actual behavior
After importing, the original dashboard appears without tabs, and queries fail.
Problem
We suspect this issue arises because the duplicated dashboards (which have unique IDs) are internally referencing the same tabs, a configuration Metabase may not support.
Possible solution
The
clone.rb
script does not currently address tabs. Extending it to include tabs might resolve this issue.The text was updated successfully, but these errors were encountered: