-
-
Notifications
You must be signed in to change notification settings - Fork 32.6k
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
Fix scaffolding generations #138820
Fix scaffolding generations #138820
Conversation
@balloob here's the fix for the additional issue you mentioned on my previous PR |
9a0fdb1
to
2b32b54
Compare
05e07b9
to
f449e38
Compare
Fix `script.scaffold` generation which is not `integration` for example `config_flow` which was failing due to hassfest quality check. Fix `config_flow_helper` which would generate out of order manifest keys due to lack of sorting. This moves the `sort_manifest`` from to `script.util` as it's now used in multiple scripts. This updates all flows to pass the integration path to hassfest, so it only checks the integration it's working on and skips the quality check which will fail on newly integrations. If a sub process fails during the generation, it will now report and instruct the user to take action.
f449e38
to
8b4228a
Compare
For the future, please don't squash or amend commits after review has started to make it easier for readers to track changes. |
Thanks for info, different teams work differently 😄 Do you prefer merge commits or Any other preferences I can read up on? |
Rebasing and merging, to update the branch, are both ok, but I think most people prefer merge since history isn't lost. We'll squash when merging the PR, so it doesn't matter for the result in the target branch. It's fine to press the update branch button in the GitHub web UI. |
Improve the logging of the scaffold script to make it easier to debug problems with the script, this now includes details of each subcommand that is run.
Proposed change
Fix
script.scaffold
generation which is notintegration
for exampleconfig_flow
which was failing due to hassfest quality check.Fix
config_flow_helper
which would generate out of order manifest keys due to lack of sorting.This moves the
sort_manifest
from toscript.util
as it's now used in multiple scripts.This updates all flows to pass the integration path to hassfest, so it only checks the integration it's working on and skips the quality check which will fail on newly integrations.
Type of change
Additional information
This fixes the issue flagged by @balloob here
I've tested that all templates for
script.scaffold
successfully generate a new integration without error.Checklist
ruff format homeassistant tests
)If user exposed functionality or configuration variables are added/changed:
If the code communicates with devices, web services, or third-party tools:
Updated and included derived files by running:
python3 -m script.hassfest
.requirements_all.txt
.Updated by running
python3 -m script.gen_requirements_all
.To help with the load of incoming pull requests: