Kibana import not working when Vega code is included and exported via API - kibana

I have been exporting / importing dashboards in kibana between different environments.
No problems when manually exporting and importing as .ndjson but when I use the API
with curl command to automate the process, all dashboards are imported normally except the ones
that use Vega visualizations. Vega is formatted in JSON and I can't see that the problem could be.
The only useful error that I have when Vega code is reached is:
command not found
Anyone had any experience with this?

Related

google colab does not import modules

I was trying to find a way to install modules permanently. I came to this post which teaches how to install packages on google drive, then mounting the drive and then using "sys.path.append" to tell the python where to look for the new package.
this method works as expected when a module directly is imported when you code in the notebook itself.
However, when I tried to run a project that I already had and wanted to run the .py file (by using"!python myCode.py"), the "sys" module can't append the path of the modules that have been installed in google drive.
in short, when you use the approach in the link above, you can only import packages when you directly code in the notebook itself. the approach did not work for me when I tried to use it on my .py files. i.e., when I used "!python myCode.py"
any suggestion on how to solve this problem? do you have the same problem as well?
thanks,

How to upload a report to SonarQube properly using SonarQube API

I want to upload a json report made in R using lintr package to my SonarQube server. I'm making a POST taking advantage of the api/ce/submit command (You can find it in https://next.sonarqube.com/sonarqube/web_api/api/ce?internal=true). To do this i'm using Postman with this params:
projectKey: XX
projectName: XXname
report: lintr_out.json
projectBranch: testing-1.0
This command create the Project in Sonar but it's not able to show the information of the report.
Anybody knows how can i see the results of the report in Sonar properly? Thanks for all!
The WS api/ce is for internal use (as marked). It is not an API and the report it expect may change its format anytime.
To submit issues based on a third party linter, I advice you look at the generic issue import feature. You simply have to convert your JSON file to the format we expect.

Google cloud function & Imagemagick: can't deal with PDF

I am trying to convert the first page of a pdf uploaded to Storage to a JPG so that I can generate a thumbnail and display it to my users. I use Imagemagick for that. The issue is that it seems like Google cloud function instances don't have ghostscript (gs) that seems to be a dependency to manipulate pdfs.
Is there a way to have it available in some way?
(fyi, I am able to properly convert on my local machine with both Imagemagick and ghostscript installed). So, I know the command I am using is good.
AWS Lambda instances have ghostscript installed by the way
Thanks
Actually Ghostscript was deprecated from the app engine as well. I think your best option is maybe to use pdf.js deployed with your cloud function. I have not tried it myself but it looks like the only way forward with the current state of CF. Other option is to deploy a GCE with Ghostscript and send a request from the CF to convert the PDF page for you.

How can I use SonarQube web service API for reporting purpose

I want to create a custom report. Response format for sonarqube web service API /api/issues/search is JSON or XML. How can I use that response to create a html or CSV file using "unix shell without using command line tools" so that I can use it as a Report. Or is there any other better way to achieve this?
you can generate a html file if you run an analysis in the preview mode http://docs.sonarqube.org/pages/viewpage.action?pageId=6947686
It looks as if the SonarQube team has been working hard to not allow people to do this. They appear to want people to purchase an Enterprise Subscription in order to export reports.
An old version of sonar-runner (now called sonar-scanner) had an option to allow local report output. But that feature is "no more supported".
ERROR: The preview mode, along with the 'sonar.analysis.mode' parameter, is no more supported. You should stop using this parameter.
Looks like version 2.4 of Sonar Runner does what you want. If you can find it. Of course they only have 2.5RC1 available on the site now.
Using the following command should work on version 2.4:
sonar-runner -Dsonar.analysis.mode=preview -Dsonar.issuesReport.html.enable=true
There at least two open-source projects that query the SQ API to generate reports in various formats.
https://github.com/cnescatlab/sonar-cnes-report/tree/dev (Java)
https://github.com/soprasteria/sonar-report (JavaScript/Node)
At the time of writing both are active.

Is it possible to copy the monkey runner results to a excel file

I want the results to be in a excel sheet.
The results should be made as a report.
I am testing a android device and want the result.
monkeyrunner
If you want to automate the whole process you can try xlwt podule to write Excel files from python.
If monkeyrunner gives you some problem importing python modules give AndroidViewClient/culebra a try.
Additionally, ask yourself whether you need Excel at all when you can generate nice reports from python using Sphinx or pod.

Resources