I didn’t see this, but it further supports my theory that there is something different in your network settings from our usual setup.
Thanks @Mathias_Westerdahl.
This is (a part of) what I see with ifconfig:
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 16384
options=1203<RXCSUM,TXCSUM,TXSTATUS,SW_TIMESTAMP>
inet 127.0.0.1 netmask 0xff000000
inet6 ::1 prefixlen 128
inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
nd6 options=201<PERFORMNUD,DAD>
gif0: flags=8010<POINTOPOINT,MULTICAST> mtu 1280
stf0: flags=0<> mtu 1280
en0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
options=50b<RXCSUM,TXCSUM,VLAN_HWTAGGING,AV,CHANNEL_IO>
ether 78:7b:8a:d9:e4:f9
inet6 fe80::50:2f9b:f642:eedd%en0 prefixlen 64 secured scopeid 0x4
inet 192.168.1.3 netmask 0xffffff00 broadcast 192.168.1.255
nd6 options=201<PERFORMNUD,DAD>
media: autoselect (1000baseT <full-duplex,energy-efficient-ethernet>)
status: active
en1: flags=8823<UP,BROADCAST,SMART,SIMPLEX,MULTICAST> mtu 1500
options=400<CHANNEL_IO>
ether 14:20:5e:03:a5:82
nd6 options=201<PERFORMNUD,DAD>
media: autoselect (<unknown type>)
status: inactive
en2: flags=8963<UP,BROADCAST,SMART,RUNNING,PROMISC,SIMPLEX,MULTICAST> mtu 1500
options=460<TSO4,TSO6,CHANNEL_IO>
ether 82:d1:15:47:a8:00
media: autoselect <full-duplex>
status: inactive
en3: flags=8963<UP,BROADCAST,SMART,RUNNING,PROMISC,SIMPLEX,MULTICAST> mtu 1500
options=460<TSO4,TSO6,CHANNEL_IO>
ether 82:d1:15:47:a8:01
media: autoselect <full-duplex>
status: inactive
Is this fine? wrong? there is something I have to change?
I have never touched such things on my Mac, nor on some other computer to be honest.
Many, many thanks!
I think that looks ok.
Digging into the error message, it comes from the engine, trying to figure out the ip of the host machine.
It uses gethostbyname, which in your case will get info from your /etc/hosts
file.
Here’s what mine looks like:
~/work/defold $ cat /etc/hosts [dev] 14:54:18
##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost
I remember getting that 5s delay when I was at a hotel with only ipv6 wifi, really odd. Workaround for me was to disable wifi, obviously inconvenient but…
@Mathias_Westerdahl cat /etc/hosts gives identical result for me
@Erik_Angelin wifi is already disabled (and it always was, I use an ethernet cable).
What if you add a 127.0.0.1 entry for iMac-di-Rocco.local?
thanks @Erik_Angelin!!!
But how I do that? as you may guess I am a really noob with these system configurations…
If you add a new row “127.0.0.1 iMac-di-Rocco.local” in /etc/hosts
Another diagnostic would be interesting to see is if you run this in your terminal:
python -c 'import socket;print socket.gethostbyname("iMac-di-Rocco.local")'
and
python -c 'import socket;print socket.getaddrinfo("iMac-di-Rocco.local","http")'
I have added the line as you suggested. Now /etc/hosts is:
##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost
127.0.0.1 iMac-di-Rocco.local
But the two issues are still there. Moreover I have tried the two commands suggested by Matthias. Here the output from gethostbyname
127.0.0.1
and this is from getaddrinfo
[(2, 2, 17, '', ('127.0.0.1', 80)), (2, 1, 6, '', ('127.0.0.1', 80))]
Ok, in my case it returns “192.168.10.210” from those python commands.
I’d start looking into that then, to see why you don’t get your local IP as expected.
Some time ago this command from the terminal helped me solve a similar issue.
sudo hostname localhost
And indeed this SOLVED the 5sec issue!!! Thanks @dmitriy
But the “connection refused” issue when re-launching the game is still there; I have to manually shut down the app.
Hey, any news about this "connection refused” issue when re-launching the game from the editor while it is already running?
Thanks!
We have not started investigation yet. The particular issue is discussed in this thread: Testing locally fails third build onwards with v1.2.173
I get this crash on Android when the app starts when bundled with v1.2.173 or v1.2.174:
2020-09-25 14:52:41.667 23485-23485/? E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.winkelgames.juump, PID: 23485
java.lang.RuntimeException: Unable to get provider com.google.firebase.provider.FirebaseInitProvider: android.content.res.Resources$NotFoundException: Unable to find resource ID #0x7f090041
at android.app.ActivityThread.installProvider(ActivityThread.java:7290)
at android.app.ActivityThread.installContentProviders(ActivityThread.java:6764)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6614)
at android.app.ActivityThread.access$1600(ActivityThread.java:231)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1952)
at android.os.Handler.dispatchMessage(Handler.java:107)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:7682)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:516)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:950)
Caused by: android.content.res.Resources$NotFoundException: Unable to find resource ID #0x7f090041
at android.content.res.ResourcesImpl.getResourcePackageName(ResourcesImpl.java:284)
at android.content.res.Resources.getResourcePackageName(Resources.java:2092)
at com.google.android.gms.common.internal.StringResourceValueReader.<init>(Unknown Source:5)
at com.google.firebase.FirebaseOptions.fromResource(com.google.firebase:firebase-common@@16.0.2:160)
at com.google.firebase.FirebaseApp.initializeApp(com.google.firebase:firebase-common@@16.0.2:301)
at com.google.firebase.provider.FirebaseInitProvider.onCreate(com.google.firebase:firebase-common@@16.0.2:53)
at android.content.ContentProvider.attachInfo(ContentProvider.java:2154)
at android.content.ContentProvider.attachInfo(ContentProvider.java:2128)
at com.google.firebase.provider.FirebaseInitProvider.attachInfo(com.google.firebase:firebase-common@@16.0.2:47)
at android.app.ActivityThread.installProvider(ActivityThread.java:7279)
at android.app.ActivityThread.installContentProviders(ActivityThread.java:6764)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6614)
at android.app.ActivityThread.access$1600(ActivityThread.java:231)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1952)
at android.os.Handler.dispatchMessage(Handler.java:107)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:7682)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:516)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:950)
It works when bundled with 1.2.172. Could this have something to do with the new way of bundling? The keystore was converted from existing .pk8 and .pem files with no apparent issues.
I am using Google Play Game Services v1.3.0. Maybe it needs to be updated to the latest, v1.3.3?
I’m working on a fix! It will if all goes well be available on Monday.
Such glorious news. Have a good weekend!
great
bob.jar PR: https://github.com/defold/defold/pull/5241
Build server PR: https://github.com/defold/extender/pull/177
An update: The crash I posted is gone using the latest beta. However, a new crash is now happening which may or may not be related.