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

wrong-type-argument hash-table-p when debug with real device #185

Open
Artawower opened this issue Nov 26, 2022 · 4 comments
Open

wrong-type-argument hash-table-p when debug with real device #185

Artawower opened this issue Nov 26, 2022 · 4 comments

Comments

@Artawower
Copy link

Describe the bug
After selecting a real device from the debug list, I got an error:

error in process filter: Wrong type argument: hash-table-p, (:id "1C221FDF600D3N" :name "Pixel 6" :platform "android-arm64" :emulator nil :category "mobile" :platformType "android" :ephemeral t :emulatorId nil :sdk "Android 13 (API 33)" :capabilities (:hotReload t :hotRestart t :screenshot t :fastStart t :flutterExit t :hardwareRendering t :startPaused t) :isDevice t) [2 times]

With enabled toggle-debug-on-error

Debugger entered--Lisp error: (wrong-type-argument hash-table-p (:id "1C221FDF600D3N" :name "Pixel 6" :platform "android-arm64" :emulator nil :category "mobile" :platformType "android" :ephemeral t :emulatorId nil :sdk "Android 13 (API 33)" :capabilities (:hotReload t :hotRestart t :screenshot t :fastStart t :flutterExit t :hardwareRendering t :startPaused t) :isDevice t))
  gethash("id" (:id "1C221FDF600D3N" :name "Pixel 6" :platform "android-arm64" :emulator nil :category "mobile" :platformType "android" :ephemeral t :emulatorId nil :sdk "Android 13 (API 33)" :capabilities (:hotReload t :hotRestart t :screenshot t :fastStart t :flutterExit t :hardwareRendering t :startPaused t) :isDevice t))
  #f(compiled-function (input0) #<bytecode -0x35ff3a91cef330>)((:id "1C221FDF600D3N" :name "Pixel 6" :platform "android-arm64" :emulator nil :category "mobile" :platformType "android" :ephemeral t :emulatorId nil :sdk "Android 13 (API 33)" :capabilities (:hotReload t :hotRestart t :screenshot t :fastStart t :flutterExit t :hardwareRendering t :startPaused t) :isDevice t))
  lsp-dart-flutter-daemon-launch((:id "1C221FDF600D3N" :name "Pixel 6" :platform "android-arm64" :emulator nil :category "mobile" :platformType "android" :ephemeral t :emulatorId nil :sdk "Android 13 (API 33)" :capabilities (:hotReload t :hotRestart t :screenshot t :fastStart t :flutterExit t :hardwareRendering t :startPaused t) :isDevice t) #f(compiled-function (input0) #<bytecode -0x35ff3a91cef330>))
  #f(compiled-function (devices) #<bytecode 0x1107fd8a7bf565cc>)(((:id "apple_ios_simulator" :name "iOS Simulator" :category "mobile" :platformType "ios") (:id "Pixel_3a_API_33_arm64-v8a" :name "Pixel_3a_API_33_arm64-v8a" :category "mobile" :platformType "android") (:id "Pixel_6_API_33" :name "Pixel 6 API 33" :category "mobile" :platformType "android") (:id "1C221FDF600D3N" :name "Pixel 6" :platform "android-arm64" :emulator nil :category "mobile" :platformType "android" :ephemeral t :emulatorId nil :sdk "Android 13 (API 33)" :capabilities (:hotReload t :hotRestart t :screenshot t :fastStart t :flutterExit t :hardwareRendering t :startPaused t) :isDevice t) (:id "chrome" :name "Chrome" :platform "web-javascript" :emulator nil :category "web" :platformType "web" :ephemeral nil :emulatorId nil :sdk "Google Chrome 107.0.5304.87" :capabilities (:hotReload t :hotRestart t :screenshot nil :fastStart nil :flutterExit nil :hardwareRendering t :startPaused t) :isDevice t) (:id "macos" :name "macOS" :platform "darwin" :emulator nil :category "desktop" :platformType "macos" :ephemeral nil :emulatorId nil :sdk "macOS 13.0.1 22A400 darwin-arm" :capabilities (:hotReload t :hotRestart t :screenshot nil :fastStart nil :flutterExit t :hardwareRendering t :startPaused t) :isDevice t)))
  #f(compiled-function (emulators) #<bytecode -0xf0240e6ead09aa4>)(((:id "apple_ios_simulator" :name "iOS Simulator" :category "mobile" :platformType "ios") (:id "Pixel_3a_API_33_arm64-v8a" :name "Pixel_3a_API_33_arm64-v8a" :category "mobile" :platformType "android") (:id "Pixel_6_API_33" :name "Pixel 6 API 33" :category "mobile" :platformType "android")))
  #f(compiled-function (result) #<bytecode 0x18edb2bb19602201>)([(:id "apple_ios_simulator" :name "iOS Simulator" :category "mobile" :platformType "ios") (:id "Pixel_3a_API_33_arm64-v8a" :name "Pixel_3a_API_33_arm64-v8a" :category "mobile" :platformType "android") (:id "Pixel_6_API_33" :name "Pixel 6 API 33" :category "mobile" :platformType "android")])
  jsonrpc-connection-receive(#<lsp-dart-flutter-daemon-connection lsp-dart-flutter-daemon-connection-49734c70> (:id 7 :result [(:id "apple_ios_simulator" :name "iOS Simulator" :category "mobile" :platformType "ios") (:id "Pixel_3a_API_33_arm64-v8a" :name "Pixel_3a_API_33_arm64-v8a" :category "mobile" :platformType "android") (:id "Pixel_6_API_33" :name "Pixel 6 API 33" :category "mobile" :platformType "android")]))
  #f(compiled-function (msg) #<bytecode -0x1a2dcd8c29218e97>)("[{\"id\":7,\"result\":[{\"id\":\"apple_ios_simulator\",\"name\":\"iOS Simulator\",\"category\":\"mobile\",\"platformType\":\"ios\"},{\"id\":\"Pixel_3a_API_33_arm64-v8a\",\"name\":\"Pixel_3a_API_33_arm64-v8a\",\"category\":\"mobile\",\"platformType\":\"android\"},{\"id\":\"Pixel_6_API_33\",...")
  -map(#f(compiled-function (msg) #<bytecode -0x1a2dcd8c29218e97>) ("[{\"id\":7,\"result\":[{\"id\":\"apple_ios_simulator\",\"name\":\"iOS Simulator\",\"category\":\"mobile\",\"platformType\":\"ios\"},{\"id\":\"Pixel_3a_API_33_arm64-v8a\",\"nam..."))
  lsp-dart-flutter-daemon--process-filter(#<process LSP Dart - Flutter daemon> "[{\"id\":7,\"result\":[{\"id\":\"apple_ios_simulator\",\"name\":\"iOS Simulator\",\"category\":\"mobile\",\"platformType\":\"ios\"},{\"id\":\"Pixel_3a_API_33_arm64-v8a\",\"name\":\"Pixel_3a_API_33_arm64-v8a\",\"category\":\"mobile\",\"platformType\":\"android\"},{\"id\":\"Pixel_6_API_33\",\"name\":\"Pixel 6 API 33\",\"category\":\"mobile\",\"platformType\":\"android\"}]}]\n")

To Reproduce

  1. call dap-debug
  2. Choose Flutter :: Debug
  3. Select real device, try to debug

Expected behavior
Debugging works correctly.

Version

[LSP Dart] 1.24.1 at 2022.11.26 @ Emacs 29.0.50
[Dart SDK] Dart SDK version: 2.18.4 (stable) (Tue Nov 1 15:15:07 2022 +0000) on "macos_arm64"

[Flutter SDK] /Users/darkawower/dev/flutter/
[Flutter project] true
[Project entrypoint] /Users/darkawower/projects/pet/mobile/quiz_teacher/lib/main.dart
@ericdallo
Copy link
Member

@Artawower any chance you have lsp-use-plists as t?

@Artawower
Copy link
Author

@Artawower any chance you have lsp-use-plists as t?

Yep, its t

@ericdallo
Copy link
Member

I think that's the issue, lsp-dart is not handling pretty well that, I'll try to take a look soon

@lazyskulptor
Copy link
Contributor

I had similar issues.
In my case, errors occurs not only in real device as MacOS aslo all emulators(IOS, Android, Chrome).
By fixing codes in PR, it's solved please check out my codes.

I think, it needs to be enhanced by checking parameter is plist or hash-table.

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

No branches or pull requests

3 participants