nativescript-vue-devtools icon indicating copy to clipboard operation
nativescript-vue-devtools copied to clipboard

Unable to connect to devtool

Open SandraLum opened this issue 6 years ago • 48 comments

Hi, I am trying out nativescript vue, following the starter guide in the official documentation and creating a new app using the vue init command and trying to connect to the dev tool.

I had no problem viewing the app on android emulator, however, I was unable to get the dev tool connected. I was stuck with Waiting for connection... with steps to add script at the top of the page you want to debug.

To Reproduce:

  1. create a new nativescript vue app from scratch following https://nativescript-vue.org/en/docs/getting-started/quick-start/
  2. Run npm install --save @vue/devtools@beta nativescript-toast nativescript-socket.io nativescript-vue-devtools
  3. Add the import in main.js import VueDevtools from 'nativescript-vue-devtools' Vue.use(VueDevtools)
  4. Run vue-devtools in one terminal
  5. Run rm -rf platforms && tns run android --bundle on another terminal

SandraLum avatar Nov 14 '18 08:11 SandraLum

Exactly same issue here.

Seems below nativescript-socket isn't returning correct stuff

const SocketIO = require('nativescript-socket.io')
debug && SocketIO.enableDebug()
return SocketIO.connect(address)

rw355 avatar Nov 15 '18 12:11 rw355

Same issue here - followed starter guide exactly.

AngeloCicero avatar Nov 19 '18 14:11 AngeloCicero

I have the same issue here, no errors, just not connecting.

bbc91 avatar Nov 20 '18 08:11 bbc91

Same here as the above comments.

nucleogenesis avatar Nov 23 '18 07:11 nucleogenesis

I've get the same issue, but it seems to happen when tns device version is updated to 5.0.0

"nativescript": { "tns-android": { "version": "5.0.0" }, "tns-ios": { "version": "5.0.0" } },

It work again when you rollback to the 4.2.0 version "nativescript": { "tns-android": { "version": "4.2.0" }, "tns-ios": { "version": "4.2.0" } },

Make change effect $ rm -rf platforms

djokone avatar Nov 23 '18 11:11 djokone

Same issue

stusmitharoo avatar Nov 24 '18 16:11 stusmitharoo

Same issue

romandrahan avatar Dec 17 '18 12:12 romandrahan

Same issue here

sivabudati avatar Dec 24 '18 04:12 sivabudati

Same here. It was working till I followed the steps to install and enable vue devtools.

kfiras avatar Dec 26 '18 16:12 kfiras

Same here

hubertstrk avatar Jan 02 '19 22:01 hubertstrk

Same here

kieuminhcanh avatar Jan 03 '19 02:01 kieuminhcanh

I tried it a few times without success, but now its working.

What i missed the first few tries was to confirm that electron is allowed to use the network (WIn10). The Windows System Dialog was initially hidden behind some other window. :-/ After confirmation, vue devtools instantly connect to my real device. (~‾▿‾)~

Win10 with a real device connected via USB. Versions:

"nativescript-vue": "^2.0.2",
"nativescript-vue-devtools": "^1.1.0",
"nativescript-socket.io": "^0.9.0",

"tns-android": {
      "version": "5.0.0"
    },
"tns-ios": {
     "version": "5.1.0"
}

Using it like documented:

if (TNS_ENV !== "production") {
  Vue.use(VueDevtools, {
    host: "192.168.45.20" // IP of the machine you are writing your code on, _not_ the Device IP your app runs on ;-)
  });
}

prinzt avatar Jan 17 '19 10:01 prinzt

Can't make it connect with --hmr as well unfortunatelly.

slushnys avatar Feb 20 '19 13:02 slushnys

Can anyone share with any solution to this problems?? Maybe someone from Nativescripte-vue team could answer this quetion??

kacperpll avatar Feb 28 '19 14:02 kacperpll

Does anyone have any updates about this issue or any new solutions? Just started using nativescript-vue and ran into this also.

bc-whisnant avatar Mar 14 '19 23:03 bc-whisnant

Not sure if nativescript-vue is there yet and I have not been successful in getting help or finding answers. It looks developers maintaining nativescript-vue are few and so are people using it. I had to switch to react-native.

On Thu, Mar 14, 2019 at 7:48 PM Brandon Whisnant [email protected] wrote:

Does anyone have any updates about this issue or any new solutions? Just started using nativescript-vue and ran into this also.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/nativescript-vue/nativescript-vue-devtools/issues/8#issuecomment-473107479, or mute the thread https://github.com/notifications/unsubscribe-auth/AFlMVnTK5_zMd7czoEXL0rIa5iy8HmcKks5vWt_MgaJpZM4YdQOP .

kfiras avatar Mar 15 '19 14:03 kfiras

@kfiras I will be switching to react native as well. Thank you for your reply.

bc-whisnant avatar Mar 17 '19 15:03 bc-whisnant

Same issue

Jakubo96 avatar Mar 19 '19 15:03 Jakubo96

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


This issue now has a funding of 0.142 ETH (19.58 USD @ $137.9/ETH) attached to it.

gitcoinbot avatar Mar 28 '19 18:03 gitcoinbot

See this boilerplate repo to reproduce the issue (you will need to set the host variable in the main.js file to your computer's network address)

https://github.com/wpatter6/nsvue-devtools-test

I am able to use termux with nmap to scan from my debugging device and see that the IP/port is open. I am also able to make a very basic website, add a vue instance, and paste the script tag shown in the developer tools UI to show that the devtools are working properly.

wpatter6 avatar Mar 28 '19 21:03 wpatter6

Issue Status: 1. Open 2. Cancelled


Work has been started.

These users each claimed they can complete the work by 6 hours ago. Please review their action plans below:

1) axelios has started work.

  1. I reinstalled the vue/devtools stack with same commands as described.
  2. Test with devices an own app.
  3. Find solution

Question Which OS are you using? Windows or Linux (Ubuntu, CentOS or any other)?

For your soon response thank you very much

Ralph Neumann

Learn more on the Gitcoin Issue Details page.

2) fabioluxx has started work.

I will try to reproduce your environment with provided information, check for errors and find a solution

Learn more on the Gitcoin Issue Details page.

gitcoinbot avatar Mar 29 '19 15:03 gitcoinbot

I am using Windows 10

hubertstrk avatar Mar 29 '19 15:03 hubertstrk

There have been some issues with some of those packages. You can fix this issue now by changing package.json with:

Replace:

nativescript-vue-devtools -> "nativescript-vue-devtools": "github:anthonny/nativescript-vue-devtools#master",

nativescript-toast -> "nativescript-toasty": "^1.3.0",

nativescript-socket.io -> "nativescript-socketio": "^3.2.1",

This is a temporary solution while the template and nativescript-vue-devtools is not fixed, but it works!

tralves avatar Mar 29 '19 17:03 tralves

@tralves That doesn't seem to fix it for me. Same behavior with these updated deps after wiping out node_modules and platforms and re-installing/building

Side note, my app uses nativescript-socket.io for other operations and it's having no trouble connecting to my socket.io server on heroku, but fails every time connecting to the devtools, and does the same with the other one nativescript-socketio, even if I completely remove the toaster and have it fall thru to an empty method. I'm also able to connect to the devtools with a generic socket.io tester desktop and android app without any trouble. So strange...

wpatter6 avatar Mar 29 '19 20:03 wpatter6

Issue Status: 1. Open 2. Cancelled


The funding of 0.142 ETH (20.09 USD @ $141.46/ETH) attached to this issue has been cancelled by the bounty submitter

gitcoinbot avatar Apr 01 '19 01:04 gitcoinbot

There have been some issues with some of those packages. You can fix this issue now by changing package.json with:

Replace:

nativescript-vue-devtools -> "nativescript-vue-devtools": "github:anthonny/nativescript-vue-devtools#master",

nativescript-toast -> "nativescript-toasty": "^1.3.0",

nativescript-socket.io -> "nativescript-socketio": "^3.2.1",

This is a temporary solution while the template and nativescript-vue-devtools is not fixed, but it works!

I did this and i run vue-devtools again, but still not working I am using an emulator

alkeinaiduko avatar Apr 07 '19 14:04 alkeinaiduko

Stink. Just went through this again with no luck. If I only had a brain cool enough to fix this...I totally would. But alas - I do not.

adamschnaare avatar Apr 12 '19 02:04 adamschnaare

The same issue any update I'm using an emulator

package.json

"dependencies": {
    "@vue/devtools": "^5.1.0",
    "nativescript-socketio": "^3.2.1",
    "nativescript-theme-core": "~1.0.4",
    "nativescript-toasty": "^1.3.0",
    "nativescript-vue": "~2.2.0",
    "nativescript-vue-devtools": "^1.2.0",
    "tns-core-modules": "~5.3.0",
    "vuex": "^3.1.0"
  },

app.js

import VueDevtools from 'nativescript-vue-devtools'
Vue.use(VueDevtools)

when I run tns debug android --bundle everything works as to expect the issue is I can't see vue-devtools tab

OmarMakled avatar Apr 21 '19 15:04 OmarMakled

I was having the same issue using an Android 9.0 (android-28) emulator. After downgrading to Android 8.1.0 (android-27) it worked as advertised in the docs.

calebbergman avatar Apr 30 '19 15:04 calebbergman

Does anyone have any update on this issue?

ericbae avatar May 03 '19 22:05 ericbae