-
-
Notifications
You must be signed in to change notification settings - Fork 81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Capture Grid view in Release Summary Report #596
Comments
I can take this! |
In my investigation, it seems that there isn't a direct API available for us to upload images to Markdown that recreates the copy and paste image on comment/thread in GitHub. Based on a stack overflow thread it seems that he closest implementation would be to commit an image into the repository itself, which is not ideal since we do not want to upload all snapshots images of the reports to the repo. Alternatively, a Medium article references Markdown Monster in which we can reference raw HTML in Markdown. This allows us to insert base64 content into Markdown: Since we will be using html2canvas to generate a screenshot/image of the Grid view, I propose some alternatives:
Thoughts? |
thank you for this excellent analysis @tommytwm, I have responded in Slack and reiterate here... based on your findings, we must reconsider this approach. Rather than capture grid view and include with release report, we should consider alternative ways to achieve the requirement of succinctly indicated the entirety of what was run in a pipeline (including passing jobs). To this end, we can start with a simple listing of passing jobs, or translate the Grid view into markdown tables. |
We can intend to use https://github.com/eclipse-aqavit-bot for this. FYI @gdams |
@tommytwm There are 2 API calls.
Click to see the testing code!
The above code works in my local. Please give it a try. Assuming we have the token and repo id, we need to figure out how to get cookie info. |
I'm having some issues with getting the dependencies to work. I'll get back to you later today to see if I'm able to run the dependencies.
|
Update: The code runs when I place it in |
getParents.js
|
#596 (comment) is a quick POC. You need to fill the placeholder ( |
I've managed to source some documentation regarding obtaining cookies:
|
According to node-fetch documentation, ES Modules is only supported in node-fetch for up to version 2. |
I've tested the two approaches locally by simply printing out the document's cookie, but the most I've managed to score is an |
@momanmalik could you take a look at this one? Thanks |
Closing this in favour of a simpler table view mentioned in #649 |
Background:
In Release Summary Report, we display all failed builds. It is very useful for triaging. However, it lacks an overview of the pipeline status. It would be great if we can capture the Grid view in Release Summary Report.
For example, the Release Summary Report will become:
Release Summary Report for openjdk8-pipeline
TRSS Build and TRSS Grid View
Jenkins Build URL https://ci.adoptopenjdk.net/job/build-scripts/job/openjdk8-pipeline/1950/
Started by user George Adams at 1/25/2022, 5:47:27 AM
create_installer_linux ❌ undefined ❌
Test_openjdk8_hs_extended.openjdk_arm_linux⚠️ UNSTABLE ⚠️
Test_openjdk8_hs_extended.openjdk_arm_linux_testList_0⚠️ UNSTABLE ⚠️
jdk_net_2 => deep history 1/2 passed | possible issues
jdk_tools_2 => deep history 0/2 passed | possible issues
Test_openjdk8_hs_extended.openjdk_arm_linux_testList_1⚠️ UNSTABLE ⚠️
hotspot_jre_2 => deep history 0/2 passed | possible issues
jdk_management_2 => deep history 0/2 passed | possible issues
Test_openjdk8_hs_extended.openjdk_arm_linux_testList_2⚠️ UNSTABLE ⚠️
jdk_beans_2 => deep history 0/2 passed | possible issues
jdk_other_2 => deep history 1/2 passed | possible issues
jdk_security4_2 => deep history 1/2 passed | possible issues
jdk_jfr_2 => deep history 0/2 passed | possible issues
jdk_imageio_2 => deep history 0/2 passed | possible issues
Test_openjdk8_hs_sanity.openjdk_arm_linux⚠️ UNSTABLE ⚠️
jdk_util_2 => deep history 1/6 passed | possible issues
jdk_jdi_jdk8_2 => deep history 0/6 passed | possible issues
Test_openjdk8_hs_sanity.system_arm_linux⚠️ UNSTABLE ⚠️
TestJlmRemoteMemoryAuth_2 => deep history 2/6 passed | possible issues
TestJlmRemoteMemoryNoAuth_2 => deep history 4/6 passed | possible issues
TestJlmRemoteClassAuth_2 => deep history 4/6 passed | possible issues
TestJlmRemoteNotifierProxyAuth_2 => deep history 5/6 passed | possible issues
TestJlmRemoteClassNoAuth_2 => deep history 3/6 passed | possible issues
TestJlmRemoteThreadAuth_2 => deep history 3/6 passed | possible issues
MauveSingleThrdLoad_HS_5m_2 => deep history 5/6 passed | possible issues
TestJlmRemoteThreadNoAuth_2 => deep history 3/6 passed | possible issues
MauveSingleInvocLoad_HS_5m_2 => deep history 5/6 passed | possible issues
Click to see the Grid view!
Implementation:
Investigate git (i.e., githubusercontent) API for uploading an image
Capture Grid view using https://html2canvas.hertzen.com/
Capture the Grid view and upload to githubusercontent once the user clicks on
Release Summary Report
Update Release Summary Report to add the collapsible section with Grid view image. For example:
The text was updated successfully, but these errors were encountered: