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

fix "any key" mappings in deflayermap #1238

Merged
merged 2 commits into from
Sep 13, 2024

Conversation

wis
Copy link
Contributor

@wis wis commented Sep 12, 2024

Describe your changes. Use imperative present tense.

may fix #1236, it fixes the behavior according to my manual testing, but not sure if the fix is a "correct" fix (in the sense of a "correct program").

Edit: may fix #1220 too apparently.

Checklist

  • Add documentation to docs/config.adoc
    • Yes or N/A
  • Add example and basic docs to cfg_samples/kanata.kbd
    • Yes or N/A
  • Update error messages
    • Yes or N/A
  • Added tests
    • Yes
  • did manual testing
    • Yes

By the way, this test failure only happens in GH Actions, it does not
happen in local development when running any of the `just` commands, like
`just test`

the failing test:
Run cargo clippy --all --no-default-features -- -D warnings
    Checking windows_x86_64_msvc v0.52.4
    Checking winapi v0.3.9
    Checking windows_x86_64_msvc v0.48.5
    Checking cfg-if v1.0.0
    Checking windows-targets v0.52.4
    Checking windows-targets v0.48.5
    Checking utf8parse v0.2.1
    Checking windows-sys v0.52.0
    Checking scopeguard v1.2.0
    Checking itoa v1.0.10
    Checking anstyle v1.0.6
    Checking lock_api v0.4.11
    Checking anstyle-parse v0.2.3
   Compiling time-core v0.1.2
    Checking log v0.4.21
   Compiling num-conv v0.1.0
    Checking colorchoice v1.0.0
    Checking powerfmt v0.2.0
    Checking smallvec v1.13.2
    Checking deranged v0.3.11
   Compiling time-macros v0.2.18
    Checking anstyle-query v1.0.2
    Checking is-terminal v0.4.12
    Checking anstyle-wincon v3.0.2
    Checking anstream v0.6.13
    Checking clap_lex v0.7.0
    Checking byteorder v1.5.0
    Checking strsim v0.11.0
    Checking rustc-demangle v0.1.23
    Checking clap_builder v4.5.2
    Checking backtrace v0.3.71
    Checking hash32 v0.2.1
    Checking serde v1.0.197
    Checking time v0.3.36
    Checking anyhow v1.0.81
    Checking spin v0.9.8
    Checking ryu v1.0.17
    Checking stable_deref_trait v1.2.0
    Checking unicode-linebreak v0.1.5
    Checking unicode-width v0.1.11
    Checking is_ci v1.2.0
    Checking smawk v0.3.2
    Checking supports-color v2.1.0
    Checking textwrap v0.15.2
    Checking heapless v0.7.17
    Checking thiserror v1.0.58
    Checking clap v4.5.4
    Checking parking_lot_core v0.9.9
    Checking backtrace-ext v0.2.1
    Checking supports-unicode v2.1.0
    Checking supports-hyperlinks v2.1.0
    Checking windows-sys v0.48.0
    Checking arraydeque v0.5.1
    Checking winapi-util v0.1.6
    Checking terminal_size v0.1.17
    Checking rustc-hash v1.1.0
    Checking termcolor v1.4.1
    Checking bitflags v1.3.2
    Checking either v1.10.0
    Checking serde_json v1.0.114
    Checking option-ext v0.2.0
    Checking simplelog v0.12.2
    Checking owo-colors v3.5.0
    Checking once_cell v1.19.0
    Checking lazy_static v1.4.0
    Checking bitflags v2.5.0
    Checking patricia_tree v0.8.0
    Checking kanata-tcp-protocol v0.171.1 (D:\a\kanata\kanata\tcp_protocol)
    Checking native-windows-gui v1.0.13
    Checking miette v5.10.0
    Checking itertools v0.12.1
    Checking kanata-keyberon v0.171.1 (D:\a\kanata\kanata\keyberon)
    Checking dirs-sys v0.4.1
    Checking parking_lot v0.12.1
    Checking nibble_vec v0.1.0
    Checking bytemuck v1.15.0
   Compiling kanata v1.7.0-prerelease-1 (D:\a\kanata\kanata)
    Checking endian-type v0.1.2
    Checking radix_trie v0.2.1
    Checking dirs v5.0.1
    Checking instant v0.1.12
    Checking memchr v2.7.1
    Checking encode_unicode v0.3.6
    Checking regex-syntax v0.8.3
    Checking win_dbg_logger v0.1.0
    Checking widestring v1.1.0
    Checking aho-corasick v1.1.3
    Checking kanata-parser v0.171.1 (D:\a\kanata\kanata\parser)
    Checking kanata_example_tcp_client v1.1.0 (D:\a\kanata\kanata\example_tcp_client)
    Checking windows_key_tester v0.3.0 (D:\a\kanata\kanata\windows_key_tester)
    Checking regex-automata v0.4.6
error: using `map` over `inspect`
   --> parser\src\cfg\sexpr.rs:296:27
    |
296 |         self.bytes.next().map(|b| {
    |                           ^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_inspect
    = note: `-D clippy::manual-inspect` implied by `-D warnings`
    = help: to override `-D warnings` add `#[allow(clippy::manual_inspect)]`
help: try
    |
296 ~         self.bytes.next().inspect(|&b| {
297 |             if b == b'\n' {
298 |                 self.line += 1;
299 |                 self.line_beginning = self.source_length - self.bytes.len()
300 ~             }
    |

error: could not compile `kanata-parser` (lib) due to 1 previous error
warning: build failed, waiting for other jobs to finish...
Error: Process completed with exit code 1.
@jtroo
Copy link
Owner

jtroo commented Sep 13, 2024

Thanks!

@jtroo jtroo merged commit 497f7d8 into jtroo:main Sep 13, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants