larsoner / circleci-artifacts-redirector-action Goto Github PK
View Code? Open in Web Editor NEWGitHub Action to add a GitHub status link to a CircleCI artifact.
License: MIT License
GitHub Action to add a GitHub status link to a CircleCI artifact.
License: MIT License
First of all, thank you so much for creating this very useful action!
We're trying to utilise this action, but it doesn't work. Would it be possible for you to point out any possible causes making this action not working in our setting?
Following the README.md
, I see its debug-level log by enabling ACTIONS_STEP_DEBUG=true
, but I don't see any relevant information there:
Our workflow file in master:
on: [status]
jobs:
circleci_artifacts_redirector_job:
runs-on: ubuntu-20.04
steps:
- uses: larsoner/circleci-artifacts-redirector-action@master
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
artifact-path: 0/html/index.html
circleci-jobs: build-Docs
job-title: Check the rendered docs here!
Our CircleCI job that generates artifacts:
https://github.com/PyTorchLightning/pytorch-lightning/blob/a6e9bc2943bf2c82036e31a4948bd8caa54957ee/.circleci/config.yml#L162
Any help is welcome. Thank you in advance.
This looks related to #38. About 5 days ago, this error started showing up again:
Hi, the workflow has started failing today with the above error. The same error shows in Matplotlib and Cartopy
https://github.com/matplotlib/matplotlib/actions/runs/4450306863/jobs/7815604256
https://github.com/SciTools/cartopy/actions/runs/4448260418/jobs/7810837269
Any ideas?
Thanks!
we've been using this extension for a while now and recently the link stopped working,
for example in openturns/openturns#1995
the link provided is https://9096-40717169-gh.circle-artifacts.com/0/html/index.html which results in an "Artifact not found" page
if I follow the artifact link from the circleci job I see that it ends at:
https://output.circle-artifacts.com/output/job/7d1e22b0-669f-42f8-a1c1-442ab387aa06/artifacts/0/html/index.html
should something be updated here, or is circleci wrong ?
the link job should be pretty standard:
https://github.com/openturns/openturns/blob/master/.github/workflows/circleci.yml
Looking at the source, it seems like you use payload.repository.id
in the domain name for links. That ID seems to point to the target repo. The way CircleCI works is to build a head commit, not a merge, so the target doesn't matter. If the source repo also has CircleCI enabled, then the build is not run again for the PR. The domain name then has the ID of the source repository.
For example, in this PR, the link from the Action is posted as:
https://31997-1385122-gh.circle-artifacts.com/0/doc/build/html/index.html
i.e., repository ID = 1385122, but navigating through the build, the link should be:
https://13144-7439715-gh.circle-artifacts.com/0/doc/build/html/index.html
with repository ID = 7439715, which corresponds with the source repo.
I don't know if this information is exposed somehow in the payload.
On the numpy/numpy repo we are using this action and the github action run is showing this warning:
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: 328d16f.
Hi,
For some reason I noticed that this Gh action stopped working awhile ago. Now https://github.com/neurodata/scikit-tree/actions/workflows/circle_artifacts.yml shows it is only trigged by codecov(?) but not run?
Here is my workflow file: https://github.com/neurodata/scikit-tree/blob/main/.github/workflows/circle_artifacts.yml
Here is my circleCI docs build file: https://github.com/neurodata/scikit-tree/blob/main/.circleci/config.yml
I'm wondering if you can easily spot something that's not working?
We use this action a lot, and it is very useful to test-build our HTML pages and link them to our pull requests. So first off: Thank you for this contribution!
Usually, an action html_demo artifact
is run, the details of which in the PR (e.g., here) link to the HTML artifacts on CircleCI.
Yesterday for the first time, the action threw the error message:
Error: Cannot read properties of undefined (reading 'length')
For the Action log, see here: https://github.com/hbrs-cse/Modellbildung-und-Simulation/actions/runs/4688129308/jobs/8308267867
We run
Run larsoner/circleci-artifacts-redirector-action@master
with:
repo-token: ***
artifact-path: 0/html/index.html
circleci-jobs: html_demo
The full debug message is in the Action log.
The curious part imho is
##[debug]build: 3617
##[debug]Fetching JSON: https://circleci.com/api/v2/project/gh/hbrs-cse/Modellbildung-und-Simulation/3617/artifacts
##[debug]Artifacts JSON (status=404):
##[debug]{"message":"Job not found."}
Error: Cannot read properties of undefined (reading 'length')
length
is only used by index.js to create the URL. This seems to be a follow-up error, because:
The URL from which the JSON is fetched, is correct. However, the status is returned as 404 and the JSON {"message":"Job not found."}
is only returned for other URLs, such as this one.
I was trying to use this and couldn't get it to write a status to any PR until I enabled the "read and write permissions" actions setting in the repo settings. This doesn't seem to be mentioned anywhere in the README. It's not clear to me why that should be needed, but it apparently it.
Hi @larsoner , thanks for this gem which we use in so many projects!
I have a bit of a crazy suggestion / feature request: would it be possible to use this action (or a related one) to generate a badge that could be put in the readme and that would point to the latest artifacts that ran successful on master? Such a badge would be super useful to avoid having to connect circleCI to push to a repo to update the dev version of the docs, which is something a bit tedious to do.
See the GitHub Actions Blog post. It seems like they are doing some kind of brownout, as the "Check the URL" step that's in the readme has been failing.
If you look at https://github.com/sympy/sympy/actions/workflows/docs-preview.yml, you can see there are a ton of failed builds for the docs preview action. I think this is because it runs every time there is a status change from any CI job, but it only makes sense when the status change actually comes from the CircleCI job.
Is it possible to make the action not run at all in these cases? It's obviously not a huge issue, but the current way is fairly confusing, and makes the "all workflows" list harder to read https://github.com/sympy/sympy/actions.
By the way, do you know why half of those jobs are indicated as being started by me, even for commits that I had nothing to do with? How does GitHub determine who the author of a "status" update is?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.