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

[Bug]: Android 14 causing all kinds of issues #3855

Closed
GR3YH4TT3R93 opened this issue Feb 24, 2024 · 11 comments
Closed

[Bug]: Android 14 causing all kinds of issues #3855

GR3YH4TT3R93 opened this issue Feb 24, 2024 · 11 comments

Comments

@GR3YH4TT3R93
Copy link

Problem description

The first issue started with backslashes in scripts that worked previously (android 13) are mangled on android 14 e.g.

if [[ $old_style =~ '\e\][0-9]+;.+\a' ]]; then
Used to work on Android 13 but now requires:

if [[ $old_style =~ '\\e\][0-9]+;.+\\a' ]]; then
and after updating, language servers for nvim that were installed via Mason are no longer able to be spawned with the error:

"Spawning language server with cmd: /data/data/com.termux/files/home/.local/share/nvim/mason/bin/tailwindcss-language-server failed. The language server is either not installed, missing from PATH".

I have a feeling that these issues are related but I don't have the experience or knowledge of what's going on to say for sure. I tried adding the mason/bin directory to PATH via

export MASON_HOME="/data/data/com.termux/files/home/.local/share/nvim/mason/bin" case ":$PATH:" in *":MASON_HOME:"*) ;; *) export PATH="$MASON_HOME:$PATH" ;; esac

with no success

Steps to reproduce the behavior.

1.) Install Termux on Android 14 device

2.) Install git, zsh

3.) Clone zsh-vi-mode via git clone https://github.com/jeffreytse/zsh-vi-mode.git $HOME/.zsh-vi-mode

4.) Source the plugin in .zshrc via source $HOME/.zsh-vi-mode/zsh-vi-mode.plugin.zsh

5.) Restart Termux or source .zshrc

6.) hit enter. Will get an error about trailing backslashes

7.) Install neovim

8.) Install and setup Mason, mason-lspconfig, and nvim-lspconfig, plugins

9.) Open file that has a supported lsp server from Mason.

10.) you should see the error provided in the description above.

What is the expected behavior?

The zsh-vi-mode plugin to work wothout modifications and LSP servers to be spawned like they were on android 13

System information

  • Termux application version: 0.118.0
  • Android OS version: 14
  • Device model: OnePlus 10T
@s1mp7e
Copy link

s1mp7e commented Feb 25, 2024

I have the same problem. Also Android 14 and OnePlus phone. Neovim does not work with language servers installed from npm. The server location path is determined correctly. But it feels like he doesn't see links to the servers' executable files. Language servers work if you run them from the command line.

@agnostic-apollo
Copy link
Member

Install termux-exec deb from end of following and see if execution gets fixed.

termux/termux-exec#24 (comment)

@GR3YH4TT3R93
Copy link
Author

@agnostic-apollo it fails with the following error:

curl -o ~/te-997.deb https://fornwall.me/te-997.deb && apt install --reinstall ~/te-997.deb % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 15 100 15 0 0 4 0 0:00:03 0:00:03 --:--:-- 4 Reading package lists... Error! E: Invalid archive signature E: Internal error, could not locate member control.tar{.zst,.lz4,.gz,.xz,.bz2,.lzma,} E: Could not read meta data from /data/data/com.termux/files/home/te-997.deb E: The package lists or status file could not be parsed or opened.

@agnostic-apollo
Copy link
Member

There is termux-exec.zip attached to my comment, download and extract that.

@s1mp7e
Copy link

s1mp7e commented Feb 25, 2024

Install termux-exec deb from end of following and see if execution gets fixed.

termux/termux-exec#24 (comment)

My problem is solved. Thank you very much.

@GR3YH4TT3R93
Copy link
Author

My bad, solved my problem as well! Tysm!

@agnostic-apollo
Copy link
Member

Welcome both.

@agnostic-apollo
Copy link
Member

And escaping backslashes in regexes is normally required.

@GR3YH4TT3R93
Copy link
Author

That's strange.. I wonder why it's not an issue for most people, the example above is a snippet from jeffreytse/zsh-vi-mode that's causing me and others issues only on android 14. Did they "fix" a "bug" pertaining to escaped backslashes or something?

@agnostic-apollo
Copy link
Member

There would be conflicting behavior with newline \n and others not requiring an escape, vs sequences not being special like \a. Makes sense to mandate escaping for the later.

@agnostic-apollo
Copy link
Member

\n would be in bracket though. However...

The interpretation of an ordinary character preceded by an unescaped ( '\' ) is undefined, except in the context of a bracket expression.

https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap09.html#tag_09_04

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants