thegreenwebfoundation / admin-portal

The member portal and platform powering The Green Web Foundation
Apache License 2.0
24 stars 11 forks source link

Moving to v4.0-rc3 and added machine-uuid #602

Closed ArneTR closed 3 months ago

ArneTR commented 3 months ago

Hey @mrchrisadams ,

we have massively slimmed our Eco-CI tool and wanted to bring you the lastest update via PR.

What I changed in your workflow

Also we have done some improvements to the SCI calculation and are now showing more granular data.

In essence though the speed gain should be the biggest win. We went down from ~30 seconds to ~1-2 seconds of overhead for a typical 5-7 step workflow.

PR-Comments

Somehow the PR comments are not showing correctly for you. I am not sure why that is. For every PR you should get a comment like that:

Screenshot 2024-06-18 at 2 49 59 PM

I have a feeling some general setting on the repo is more restrictive than we expect it to be. I will look into that once a workflow for this PR has run

ArneTR commented 3 months ago

Actually by submitting this PR I might have found the issue:

Is that what you want?

In case you want that I can add it to the PR. Let me know. In any case it would be needed if you want the Eco-CI PR-Comment funcationality as I believe there is no safe way to determine if we are in a PR event if you have not set the trigger in the workflow.

mrchrisadams commented 3 months ago

Hi @ArneTR

Your https://github.com/thegreenwebfoundation/admin-portal/blob/master/.github/workflows/run-tests.yml file only specifies to run on push. So me making a PR does not trigger that workflow as I am an outside collaborator and technically never pushed.

I think this is might be related to the act that we've been pushing branches inside our own repo when we do PRs, rather than working with PRs from external repos.

TBH, I think it probably does make sense to run this on external PRs too as you suggest. I've never done this before though - would it just be a case of adding something like this?

on:
  push:
    paths-ignore:
      - '**.md'
      - '.gitignore'
  pull_request:
    paths-ignore:
      - '**.md'
      - '.gitignore'

I'm not sure what the correct syntax would be. If you know, would you add the correct incantation? I'll merge it in once it's made as I think this would be pretty neat.

ArneTR commented 3 months ago

jap, that looks correct