You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2022/03/21 04:42:33 UTC

[GitHub] [superset] srinisubramanian opened a new issue #19268: slug is not updated when importing dashboard via API

srinisubramanian opened a new issue #19268:
URL: https://github.com/apache/superset/issues/19268


   The slug is not set when importing a dashboard
   
   #### How to reproduce the bug
   
   Set a slug and export a dashboard using the export API.  Import the dashboard using the /import API.  The slug is not set after import
   
   ### Expected results
   
   Slug should be set to the value in the json
   
   ### Actual results
   
   Slug is not set
   
   #### Screenshots
   
   If applicable, add screenshots to help explain your problem.
   
   
   ### Environment
   
   (please complete the following information):
   
   - API superset version 1.41
   - any feature flags active:
   
   ### Checklist
   
   Make sure to follow these steps before submitting your issue - thank you!
   
   - [ ] I have checked the superset logs for python stacktraces and included it here as text if there are any.
   - [ ] I have reproduced the issue with at least the latest released version of superset.
   - [ ] I have checked the issue tracker for the same issue and I haven't found one similar.
   
   ### Additional context
   
   Add any other context about the problem here.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on issue #19268: slug is not updated when importing dashboard via API

Posted by GitBox <gi...@apache.org>.
villebro commented on issue #19268:
URL: https://github.com/apache/superset/issues/19268#issuecomment-1073918480


   I believe they're incompatible, unfortunately. Are you able to re-export the old dashboards with the flag turned on?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] srinisubramanian closed issue #19268: slug is not updated when importing dashboard via API

Posted by GitBox <gi...@apache.org>.
srinisubramanian closed issue #19268:
URL: https://github.com/apache/superset/issues/19268


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] villebro commented on issue #19268: slug is not updated when importing dashboard via API

Posted by GitBox <gi...@apache.org>.
villebro commented on issue #19268:
URL: https://github.com/apache/superset/issues/19268#issuecomment-1073608188


   @srinisubramanian have you enabled the `VERSIONED_EXPORT` feature flag, or are you using the old JSON import/export?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] srinisubramanian commented on issue #19268: slug is not updated when importing dashboard via API

Posted by GitBox <gi...@apache.org>.
srinisubramanian commented on issue #19268:
URL: https://github.com/apache/superset/issues/19268#issuecomment-1073645162


   I had not set VERSIONED_EXPORT as I thought it was defaulted to True and hence was doing the JSOn stuff.
   
   Anyways I now added it to superset_config.py and cleared out the database and reinitialized the test instance.  Also changed dev landscape to include the VERSIONED_EXPORT.  The export API now downloaded a zip file.
   
   Then attempted the import via the API.  THrows a 500 error:
   ```
   2022-03-21 14:20:56,235:INFO:werkzeug:127.0.0.1 - - [21/Mar/2022 14:20:56] "POST /api/v1/dashboard/import HTTP/1.1" 308 -
   Command failed validation
   2022-03-21 14:20:56,358:INFO:superset.dashboards.commands.importers.dispatcher:Command failed validation
   Error importing dashboard
   2022-03-21 14:20:56,358:WARNING:superset.views.base:Error importing dashboard
   2022-03-21 14:20:56,361:INFO:werkzeug:127.0.0.1 - - [21/Mar/2022 14:20:56] "POST /api/v1/dashboard/import/ HTTP/1.0" 500 -
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] srinisubramanian edited a comment on issue #19268: slug is not updated when importing dashboard via API

Posted by GitBox <gi...@apache.org>.
srinisubramanian edited a comment on issue #19268:
URL: https://github.com/apache/superset/issues/19268#issuecomment-1073645162


   I had not set VERSIONED_EXPORT as I thought it was defaulted to True and hence was doing the JSOn stuff.
   
   Anyways I now added it to superset_config.py and cleared out the database and reinitialized the test instance.  Also changed dev landscape to include the VERSIONED_EXPORT.  The export API now downloaded a zip file.
   
   Then attempted the import via the API.  THrows a 500 error:
   ```
   2022-03-21 14:20:56,235:INFO:werkzeug:127.0.0.1 - - [21/Mar/2022 14:20:56] "POST /api/v1/dashboard/import HTTP/1.1" 308 -
   Command failed validation
   2022-03-21 14:20:56,358:INFO:superset.dashboards.commands.importers.dispatcher:Command failed validation
   Error importing dashboard
   2022-03-21 14:20:56,358:WARNING:superset.views.base:Error importing dashboard
   2022-03-21 14:20:56,361:INFO:werkzeug:127.0.0.1 - - [21/Mar/2022 14:20:56] "POST /api/v1/dashboard/import/ HTTP/1.0" 500 -
   ```
   
   I provided only formData and overwrite as multipart/form-data.  The database was already created with the same name in the target system.  Do I need to pass any other parameters also?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] srinisubramanian edited a comment on issue #19268: slug is not updated when importing dashboard via API

Posted by GitBox <gi...@apache.org>.
srinisubramanian edited a comment on issue #19268:
URL: https://github.com/apache/superset/issues/19268#issuecomment-1073919805


   I can re-export. But import keeps failing with a validation error. No other details in log also


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] srinisubramanian commented on issue #19268: slug is not updated when importing dashboard via API

Posted by GitBox <gi...@apache.org>.
srinisubramanian commented on issue #19268:
URL: https://github.com/apache/superset/issues/19268#issuecomment-1073919805


   I can re-export. But import keeps failing. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] srinisubramanian commented on issue #19268: slug is not updated when importing dashboard via API

Posted by GitBox <gi...@apache.org>.
srinisubramanian commented on issue #19268:
URL: https://github.com/apache/superset/issues/19268#issuecomment-1074732607


   Details captured in #19297 .. closing this issue


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] srinisubramanian commented on issue #19268: slug is not updated when importing dashboard via API

Posted by GitBox <gi...@apache.org>.
srinisubramanian commented on issue #19268:
URL: https://github.com/apache/superset/issues/19268#issuecomment-1073865057


   @villebro  While I am able to import new dashboards created and some really simple dashboard examples, some other dashboards that I created BEFORE the VERSIONED_EXPORT was turned on, I am not able to import.  It keeps failing with a validation error.
   
   Question:  Can dashboards created when VERSIONED_EXPORT was false, be exported and imported?  Looks like some uuid issues?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] srinisubramanian commented on issue #19268: slug is not updated when importing dashboard via API

Posted by GitBox <gi...@apache.org>.
srinisubramanian commented on issue #19268:
URL: https://github.com/apache/superset/issues/19268#issuecomment-1073663847


   @villebro  I did make some more progress.  Rather than using the API I imported using the UI and I was prompted for the password.  Looks like the database to connect to seems to be validated by connecting and in my case the same user was not existing.  Once I set that up the import went through.  I did a reimport and that prompted for an overwrite without prompting for password and did go through.  
   
   In this case the slug was also set.  I will check more with API now, thanks.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org