在做郭神第一行代码天气预报开发的时候,在中国的页面就是显示无法加载,省份不能出来,求助各位大神
locat为: 
    --------- beginning of system
2019-03-07 15:18:58.496 1821-3816/? I/ActivityManager: START u0 {act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10200000 cmp=com.kuyun.policevideo.coolweather/.MainActivity bnds=[641,1536][843,1794]} from uid 10034
2019-03-07 15:18:58.503 1560-4459/? W/audio_hw_generic: Not supplying enough data to HAL, expected position 8074427 , only wrote 8074080
2019-03-07 15:18:58.528 7897-8601/? I/MicroRecognitionRunner: Starting detection.
2019-03-07 15:18:58.530 7897-8596/? I/MicrophoneInputStream: mic_starting  SR : 16000 CC : 16 SO : 6
2019-03-07 15:18:58.545 1578-1695/? E/AudioFlinger: not enough memory for AudioTrack size=131296
2019-03-07 15:18:58.545 1578-1695/? D/MemoryDealer:   AudioTrack (0xe6f88150, size=4194304)
        0: 0xe6f88160 | 0x00000000 | 0x000200E0 | A 
        1: 0xe6f88300 | 0x000200E0 | 0x000200E0 | A 
        2: 0xe6f887c0 | 0x000401C0 | 0x000200E0 | A 
        3: 0xe6f88960 | 0x000602A0 | 0x000200E0 | A 
        4: 0xe6f88bb0 | 0x00080380 | 0x000200E0 | A 
        5: 0xe731cd50 | 0x000A0460 | 0x000200E0 | A 
        6: 0xe6f88e40 | 0x000C0540 | 0x000200E0 | A 
        7: 0xe731cf80 | 0x000E0620 | 0x000200E0 | A 
        8: 0xe6f88fd0 | 0x00100700 | 0x000200E0 | A 
        9: 0xe45d4180 | 0x001207E0 | 0x000200E0 | A 
       10: 0xe45d4350 | 0x001408C0 | 0x000200E0 | A 
       11: 0xe45d44d0 | 0x001609A0 | 0x000200E0 | A 
       12: 0xe45d4700 | 0x00180A80 | 0x000200E0 | A 
       13: 0xe45d4870 | 0x001A0B60 | 0x000200E0 | A 
       14: 0xe45d4a50 | 0x001C0C40 | 0x000200E0 | A 
       15: 0xe45d4c40 | 0x001E0D20 | 0x000200E0 | A 
       16: 0xe45d4e80 | 0x00200E00 | 0x000200E0 | A 
       17: 0xe2ba2020 | 0x00220EE0 | 0x000200E0 | A 
       18: 0xe2ba21e0 | 0x00240FC0 | 0x000200E0 | A 
       19: 0xe2ba2360 | 0x002610A0 | 0x000200E0 | A 
       
2019-03-07 15:18:58.545 1578-1695/? E/AudioFlinger: createRecordTrack_l() initCheck failed -12; no control block?
2019-03-07 15:18:58.553 1560-4459/? W/audio_hw_generic: Hardware backing HAL too slow, could only write 0 of 720 frames
2019-03-07 15:18:58.569 1560-4459/? W/audio_hw_generic: Hardware backing HAL too slow, could only write 0 of 720 frames
2019-03-07 15:18:58.571 1578-8762/? I/AudioFlinger: AudioFlinger's thread 0xe1203ec0 tid=8762 ready to run
2019-03-07 15:18:58.576 7897-8596/? E/IAudioFlinger: createRecord returned error -12
2019-03-07 15:18:58.576 7897-8596/? E/AudioRecord: AudioFlinger could not create record track, status: -12
2019-03-07 15:18:58.582 1560-4459/? W/audio_hw_generic: Hardware backing HAL too slow, could only write 0 of 720 frames
2019-03-07 15:18:58.733 1560-4459/? I/chatty: uid=1041(audioserver) writer identical 10 lines
2019-03-07 15:18:58.747 1560-4459/? W/audio_hw_generic: Hardware backing HAL too slow, could only write 0 of 720 frames
2019-03-07 15:18:58.754 1570-1634/? D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 8298496
2019-03-07 15:18:58.764 1560-4459/? W/audio_hw_generic: Hardware backing HAL too slow, could only write 0 of 720 frames
2019-03-07 15:18:58.772 8669-8669/com.kuyun.policevideo.coolweather W/ActivityThread: handleWindowVisibility: no activity for token android.os.BinderProxy@d865d50
2019-03-07 15:18:58.777 1560-4459/? W/audio_hw_generic: Hardware backing HAL too slow, could only write 0 of 720 frames
2019-03-07 15:18:58.921 1570-1634/? D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 8298496
2019-03-07 15:18:59.000 7897-8596/? E/AudioRecord-JNI: Error creating AudioRecord instance: initialization check failed with status -12.
2019-03-07 15:18:59.002 7897-8596/? E/android.media.AudioRecord: Error code -20 when initializing native AudioRecord object.
2019-03-07 15:18:59.002 7897-8596/? I/MicrophoneInputStream: mic_started  SR : 16000 CC : 16 SO : 6
2019-03-07 15:18:59.003 7897-8596/? E/ActivityThread: Failed to find provider info for com.google.android.apps.gsa.testing.ui.audio.recorded
2019-03-07 15:18:59.006 7897-7897/? I/MicroDetector: Keeping mic open: false
2019-03-07 15:18:59.004 7897-8596/? I/MicrophoneInputStream: mic_close  SR : 16000 CC : 16 SO : 6
2019-03-07 15:18:59.007 7897-8596/? I/AudioController: internalShutdown
2019-03-07 15:18:59.008 7897-7932/? I/DeviceStateChecker: DeviceStateChecker cancelled
2019-03-07 15:18:59.012 7897-7991/? I/MicroRecognitionRunner: Stopping hotword detection.
2019-03-07 15:18:59.016 7897-8601/? I/MicroRecognitionRunner: Detection finished
2019-03-07 15:18:59.057 2429-2438/? W/System: A resource failed to call release. 
2019-03-07 15:18:59.057 2429-2438/? W/System: A resource failed to call release. 
2019-03-07 15:18:59.096 2429-2440/? I/s.nexuslaunche: Background concurrent copying GC freed 3266(359KB) AllocSpace objects, 19(4MB) LOS objects, 17% free, 28MB/34MB, paused 4.540ms total 415.520ms
2019-03-07 15:18:59.135 1570-1634/? D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 2252800
2019-03-07 15:18:59.152 1570-1634/? D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 2252800
2019-03-07 15:18:59.171 1570-1694/? D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 2252800
2019-03-07 15:18:59.204 1650-1650/? D/SurfaceFlinger: duplicate layer name: changing com.kuyun.policevideo.coolweather/com.kuyun.policevideo.coolweather.MainActivity to com.kuyun.policevideo.coolweather/com.kuyun.policevideo.coolweather.MainActivity#1
2019-03-07 15:18:59.233 1570-1694/? D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 8298496
2019-03-07 15:18:59.247 1570-1694/? D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 8298496
2019-03-07 15:18:59.256 1570-1634/? D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 8298496
2019-03-07 15:18:59.331 8669-8680/com.kuyun.policevideo.coolweather I/deo.coolweathe: Background concurrent copying GC freed 2715(251KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 1701KB/3MB, paused 10.707ms total 115.427ms
2019-03-07 15:18:59.337 1942-2168/? D/EGL_emulation: eglMakeCurrent: 0xe37f3d00: ver 2 0 (tinfo 0xcec7e400)
2019-03-07 15:18:59.352 2429-2570/? I/OpenGLRenderer: Davey! duration=755ms; Flags=0, IntendedVsync=2659504473995, Vsync=2659604473991, OldestInputEvent=9223372036854775807, NewestInputEvent=0, HandleInputStart=2659608570100, AnimationStart=2659608728440, PerformTraversalsStart=2659609466050, DrawStart=2659614920430, SyncQueued=2659615087480, SyncStart=2659719422990, IssueDrawCommandsStart=2659719927750, SwapBuffers=2660337867380, FrameCompleted=2660364195600, DequeueBufferDuration=90000, QueueBufferDuration=342000, 
2019-03-07 15:18:59.365 8669-8694/com.kuyun.policevideo.coolweather D/EGL_emulation: eglMakeCurrent: 0xe4f85540: ver 2 0 (tinfo 0xe4f83650)
2019-03-07 15:18:59.367 2429-2429/? I/Choreographer: Skipped 36 frames!  The application may be doing too much work on its main thread.
2019-03-07 15:18:59.392 1942-2168/? D/EGL_emulation: eglMakeCurrent: 0xe37f3d00: ver 2 0 (tinfo 0xcec7e400)
2019-03-07 15:18:59.476 1930-1930/? I/GoogleInputMethod: onFinishInput() : Dummy InputConnection bound
2019-03-07 15:18:59.477 1930-1930/? I/GoogleInputMethod: onStartInput() : Dummy InputConnection bound
2019-03-07 15:18:59.484 1821-1843/? I/ActivityManager: Displayed com.kuyun.policevideo.coolweather/.MainActivity: +743ms
2019-03-07 15:18:59.601 1570-1634/? D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 143360
2019-03-07 15:18:59.607 1570-1694/? D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 143360
2019-03-07 15:18:59.612 1570-1634/? D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 143360
2019-03-07 15:18:59.650 1821-3933/? W/system_server: JNI critical lock held for 19.754ms on Thread[87,tid=3933,Runnable,Thread*=0xcb4e8200,peer=0x12e09378,"Binder:1821_17"]
2019-03-07 15:18:59.660 8669-8694/com.kuyun.policevideo.coolweather D/EGL_emulation: eglMakeCurrent: 0xe4f85540: ver 2 0 (tinfo 0xe4f83650)
2019-03-07 15:18:59.689 1942-2168/? D/EGL_emulation: eglMakeCurrent: 0xe37f3d00: ver 2 0 (tinfo 0xcec7e400)
2019-03-07 15:18:59.888 1560-4459/? W/audio_hw_generic: Hardware backing HAL too slow, could only write 0 of 720 frames
2019-03-07 15:18:59.918 1560-4459/? I/chatty: uid=1041(audioserver) writer identical 2 lines
2019-03-07 15:18:59.933 1560-4459/? W/audio_hw_generic: Hardware backing HAL too slow, could only write 0 of 720 frames
2019-03-07 15:18:59.973 2429-2570/? I/OpenGLRenderer: Davey! duration=868ms; Flags=0, IntendedVsync=2659771107712, Vsync=2660371107688, OldestInputEvent=9223372036854775807, NewestInputEvent=0, HandleInputStart=2660378869020, AnimationStart=2660379011430, PerformTraversalsStart=2660379757750, DrawStart=2660380395910, SyncQueued=2660380788000, SyncStart=2660725786540, IssueDrawCommandsStart=2660727001870, SwapBuffers=2660978586300, FrameCompleted=2660984542440, DequeueBufferDuration=85000, QueueBufferDuration=371000, 
2019-03-07 15:19:00.018 7897-7926/? D/EGL_emulation: eglMakeCurrent: 0xe4f85180: ver 2 0 (tinfo 0xe4f83320)
2019-03-07 15:19:00.053 1560-4459/? W/audio_hw_generic: Hardware backing HAL too slow, could only write 0 of 720 frames
2019-03-07 15:19:00.083 1560-4459/? I/chatty: uid=1041(audioserver) writer identical 2 lines
2019-03-07 15:19:00.098 1560-4459/? W/audio_hw_generic: Hardware backing HAL too slow, could only write 0 of 720 frames
2019-03-07 15:19:00.111 1942-2168/? D/EGL_emulation: eglMakeCurrent: 0xe37f3d00: ver 2 0 (tinfo 0xcec7e400)
2019-03-07 15:19:00.113 1560-4459/? W/audio_hw_generic: Hardware backing HAL too slow, could only write 0 of 720 frames
2019-03-07 15:19:00.158 1560-4459/? I/chatty: uid=1041(audioserver) writer identical 3

解决方案 »

  1.   

    你这log 怎么感觉是设备的内存空间不够了
      

  2.   

    没看出来什么重要信息,你日志发的应该不对,博客里有新人教程和如何查看日志https://blog.csdn.net/weimingjue/article/details/87921494
      

  3.   

    我和你的情况一样 加载失败没有数据 我看了下数据库是空的,我想怕不是okhttp的原因吧
      

  4.   

    在最新版本的安卓里,访问一些较早的网站需要在配置清单里加上android:usesCleartextTraffic="true"这句话就行了