First off, no chance you can use Android's built-in debugging? More info here: https://developer.chrome.com/devtools/docs/remote-debugging
Another option is that weinre for some reason can't find it's script tag, to figure out where the server is ("foo:8080"). Usually the server is determined by looking for the script tag for the target script. You can override this with globals:
The `WeinreServerId` is the hash bit on the URL. Defaults to "anonymous", and you're not using it, so you shouldn't need to set it to anything.
Also try adding --verbose and --debug to your server startup, and perhaps you'll catch some kind of error message, if it actually connects but then later dies for some other reason.