Bouni / python-luxtronik

python-luxtronik is a library that allow you to interact with a Luxtronik heatpump controller.
MIT License
37 stars 20 forks source link

Attempt to run CI only once #127

Closed Bouni closed 1 year ago

Bouni commented 1 year ago

This is an attempt to prevent our CI pipeline from running twice for every PR. There is no need to run it on: push for a PR and on: pull-request as well.

github-actions[bot] commented 1 year ago

Coverage

Coverage Report
FileStmtsMissCoverMissing
luxtronik
   __init__.py13410621%38–54, 61–66, 69–73, 79, 83, 102–113, 116–119, 122–142, 145–160, 163–180, 183–198, 202–204, 208–209, 213–214
   __main__.py21210%2–48
   calculations.py322328%43, 307, 311–319, 324–336, 340–341
   datatypes.py2351394%37, 42, 47, 52, 57, 72–75, 80–83, 92
   discover.py433421%25–77
   parameters.py503922%33–36, 1166, 1170–1178, 1186–1206, 1210–1211, 1215–1222
   visibilities.py322328%13, 372, 376–384, 389–401, 405–406
luxtronik/scripts
   dump_changes.py44440%5–93
   dump_luxtronik.py28280%5–64
TOTAL62733147% 

Tests Skipped Failures Errors Time
102 4 :zzz: 0 :x: 0 :fire: 0.776s :stopwatch:
Bouni commented 1 year ago

Seems to work, we run only 6 checks instead of 12 as we do currently

kbabioch commented 1 year ago

I guess the problem with omitting push is that it will only run on pull requests then. This could make it harder to prepare something in a (private) branch, since the pipeline will run only on creating a pull request.

Also, what will happen when pushing additional commits to an existing pull request?

Bouni commented 1 year ago

I guess the first point is what pre-commit solves.

I have checked the second because I had the same concern but every push to a PR triggers the CI. ( This one has two commits and the CI ran for both)