-
Notifications
You must be signed in to change notification settings - Fork 1
Fix for HA 2026.x #1
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
base: master
Are you sure you want to change the base?
Conversation
Reviewer's GuideUpdate the NiceHash custom component to be compatible with Home Assistant 2026.x and add local development and linting tooling aligned with Home Assistant core practices. Flow diagram for local development workflow with new toolingflowchart TD
A["Clone repository"] --> B["Create dev container or local venv"]
B --> C["pip install -r requirements.txt"]
C --> D["Run scripts/setup"]
D --> E["Run scripts/develop to start Home Assistant 2026.x"]
E --> F["Home Assistant loads custom_components.nicehash using HomeAssistant type"]
C --> G["Run scripts/lint"]
G --> H["ruff uses .ruff.toml rules"]
E --> I["Edit integration code in editor"]
I --> G
subgraph Runtime_Config
J["config/configuration.yaml"]
K["logger: custom_components.nicehash = debug"]
end
J --> E
K --> E
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey - I've found 1 issue, and left some high level feedback:
- The new
scripts/develop,scripts/lint, andscripts/setupfiles are empty in this diff; consider either adding their intended logic or removing them to avoid confusion about their purpose. - The newly added
config/configuration.yamland pinnedhomeassistant==2026.1.0inrequirements.txtlook like local dev tooling; consider isolating these into a dedicated dev environment setup (e.g., under.devcontaineror similar) so they don't affect consumers of the integration.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- The new `scripts/develop`, `scripts/lint`, and `scripts/setup` files are empty in this diff; consider either adding their intended logic or removing them to avoid confusion about their purpose.
- The newly added `config/configuration.yaml` and pinned `homeassistant==2026.1.0` in `requirements.txt` look like local dev tooling; consider isolating these into a dedicated dev environment setup (e.g., under `.devcontainer` or similar) so they don't affect consumers of the integration.
## Individual Comments
### Comment 1
<location> `config/configuration.yaml:5-6` </location>
<code_context>
+default_config:
+
+# https://www.home-assistant.io/integrations/homeassistant/
+homeassistant:
+ debug: true
+
+# https://www.home-assistant.io/integrations/logger/
</code_context>
<issue_to_address>
**issue (bug_risk):** `homeassistant: debug: true` is not a valid core config option and may break config loading.
If this file is intended to be used directly, this key will likely cause a configuration error. To enable debug logging, rely on the existing `logger:` configuration (which already sets `custom_components.nicehash` to `debug`) and remove `debug: true` from the `homeassistant:` block.
</issue_to_address>Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
| homeassistant: | ||
| debug: true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
issue (bug_risk): homeassistant: debug: true is not a valid core config option and may break config loading.
If this file is intended to be used directly, this key will likely cause a configuration error. To enable debug logging, rely on the existing logger: configuration (which already sets custom_components.nicehash to debug) and remove debug: true from the homeassistant: block.
Summary by Sourcery
Update NiceHash Home Assistant integration for compatibility with HA 2026.x and add local development tooling.
Enhancements:
Build:
Chores: