Skip to content
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

feat(docs): Add troubleshooting section for empty_file error #2212

Merged
merged 1 commit into from
Mar 20, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions docs/docs/troubleshooting.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,14 @@ A `devicetree error` followed by a reference to the line number on `<keyboard>.k
devicetree error: /__w/zmk-config/zmk-config/config/cradio.keymap:109 (column 4): parse error: expected ';' or ','
```

A `devicetree error` followed by an `empty_file.c` reference with `lacks #binding-cells` string indicates possible problems with improper parameters for specific bindings:

```
devicetree error: <Node /soc/gpio@50000300 in '/tmp/tmp.vJq9sMwkcY/zephyr/misc/empty_file.c'> lacks #binding-cells
```

This error can be triggered by incorrect binding syntax such as `&kp BT_SEL 0` instead of `&bt BT_SEL 0`.

#### devicetree_unfixed.h error
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at this again, I wonder if this devicetree_unfixed.h is also a devicetree error which should be added to the above section rather than having its own header?

The example looks like the start devicetree error: was removed. Otherwise it looks like a similar error in which case it probably shouldn't have it's own heading?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here is a recent variant of this error: https://github.com/l2yuk3n/zmk-config/actions/runs/8303562600/job/22727892620#step:11:120 It indeed doesn't start with devicetree error:.

I believe the wording is a bit different since the last Zephyr upgrade or two, so it would be good to update it. For instance unfixed is now generated. I think it would make sense to merge this with this new section as well, since the root cause is very similar (or the same? mismatch between the binding and #parameters).

That being said we can do that in another PR.


A `devicetree_unfixed.h` error that follows with an "undeclared here" string indicates a problem with key bindings, like behavior nodes (e.g. `&kp` or `&mt`) with incorrect number of parameters:
Expand Down
Loading