“Error while receiving image in the application using Firebase and Flutter.”

huangapple go评论119阅读模式
英文:

Error while reciving image in the application using firebase and flutter

问题

每当我尝试构建和运行此应用程序时,它会成功运行,但无法从Firebase数据库获取图像,并出现以下错误。我尝试使用Firebase插件,并在控制台中检查应用程序是否配置正确,但应用程序已正确连接,我可以创建用户并登录到应用程序,也可以上传照片,但无法接收它。

代码链接在这里:博客

英文:

whenever I try to build this app and run this app its runs successfully but unable to get images from firebase database and I get this error. i tried to use firebase plugins and checked in the console that the app is been configured or not but the app was connected correctly i can create user and login in the app also able to upload photo but unable to recive it

  1. D/FlutterView(19804): Detaching from a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@daebe54
  2. I/OpenGLRenderer(19804): Initialized EGL, version 1.4
  3. D/OpenGLRenderer(19804): Swap behavior 1
  4. W/RenderThread(19804): type=1400 audit(0.0:22544): avc: denied { search } for name="kgsl-3d0" dev="sysfs" ino=22816 scontext=u:r:untrusted_app:s0:c512,c768 tcontext=u:object_r:sysfs_kgsl:s0 tclass=dir permissive=0
  5. W/Adreno-ES20(19804): <get_gpu_clk:229>: open failed: errno 13
  6. W/Adreno-EGL(19804): <qeglDrvAPI_eglGetConfigAttrib:612>: EGL_BAD_ATTRIBUTE
  7. W/Adreno-EGL(19804): <qeglDrvAPI_eglGetConfigAttrib:612>: EGL_BAD_ATTRIBUTE
  8. I/SurfaceView(19804): updateSystemUiVisibility, blackBackground = false, viewVisibility = 0, appBounds = Rect(0, 0 - 720, 1440), mScreenRect = Rect(0, 0 - 720, 1356), surface = io.flutter.embedding.android.FlutterSurfaceView{ff4c83e V.E...... ......ID 0,0-720,1356}
  9. D/FlutterView(19804): Attaching to a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@daebe54
  10. W/1.gpu (19804): type=1400 audit(0.0:22545): avc: denied { search } for name="kgsl-3d0" dev="sysfs" ino=22816 scontext=u:r:untrusted_app:s0:c512,c768 tcontext=u:object_r:sysfs_kgsl:s0 tclass=dir permissive=0
  11. W/Adreno-ES20(19804): <get_gpu_clk:229>: open failed: errno 13
  12. W/Adreno-EGL(19804): <qeglDrvAPI_eglGetConfigAttrib:612>: EGL_BAD_ATTRIBUTE
  13. W/Adreno-EGL(19804): <qeglDrvAPI_eglGetConfigAttrib:612>: EGL_BAD_ATTRIBUTE
  14. I/flutter (19804): Image Url: https://firebasestorage.googleapis.com/v0/b/blog-8c8f3.appspot.com/o/Post%20Image%2F2019-12-31%2003%3A09%3A37.024688.jpg?alt=media&token=0cf6ac7c-a2cd-4e7b-b85c-da21d8f3488c
  15. I/flutter (19804): Length: [Instance of 'Posts'].length
  16. [38;5;248m════════ Exception caught by widgets library ═══════════════════════════════════[39;49m
  17. [38;5;244mThe following assertion was thrown building:[39;49m
  18. 'package:flutter/src/painting/_network_image_io.dart': Failed assertion: line 22 pos 14: 'url != null': is not true.
  19. [38;5;248mEither the assertion indicates an error in the framework itself, or we should provide substantially more information in this error message to help you determine and fix the underlying cause.
  20. In either case, please report this assertion by filing a bug on GitHub:
  21. https://github.com/flutter/flutter/issues/new?template=BUG.md
  22. [39;49m
  23. [38;5;244mWhen the exception was thrown, this was the stack[39;49m
  24. [38;5;244m#2 new NetworkImage[39;49m
  25. [38;5;244m#3 new Image.network[39;49m
  26. [38;5;248m#4 _HomePageState.postsUI[39;49m
  27. [38;5;248m#5 _HomePageState.build.<anonymous closure>[39;49m
  28. [38;5;244m#6 SliverChildBuilderDelegate.build[39;49m
  29. [38;5;244m...[39;49m
  30. [38;5;248m════════════════════════════════════════════════════════════════════════════════[39;49m
  31. [38;5;248m════════ Exception caught by widgets library ═══════════════════════════════════[39;49m
  32. [38;5;244mThe following assertion was thrown building:[39;49m
  33. 'package:flutter/src/painting/_network_image_io.dart': Failed assertion: line 22 pos 14: 'url != null': is not true.
  34. [38;5;248mEither the assertion indicates an error in the framework itself, or we should provide substantially more information in this error message to help you determine and fix the underlying cause.
  35. In either case, please report this assertion by filing a bug on GitHub:
  36. https://github.com/flutter/flutter/issues/new?template=BUG.md
  37. [39;49m
  38. [38;5;244mWhen the exception was thrown, this was the stack[39;49m
  39. [38;5;244m#2 new NetworkImage[39;49m
  40. [38;5;244m#3 new Image.network[39;49m
  41. [38;5;248m#4 _HomePageState.postsUI[39;49m
  42. [38;5;248m#5 _HomePageState.build.<anonymous closure>[39;49m
  43. [38;5;244m#6 SliverChildBuilderDelegate.build[39;49m
  44. [38;5;244m...[39;49m
  45. [38;5;248m════════════════════════════════════════════════════════════════════════════════

here is my code link blog

答案1

得分: 3

你犯了一个错误,请将“images”替换为“image”。

DATA[individualKey]["image"],
DATA[individualKey]["description"],
DATA[individualKey]["date"],
DATA[individualKey]["time"],

英文:

You made an error replace "images" with "image"

  1. DATA[individualKey]["image"],
  2. DATA[individualKey]["description"],
  3. DATA[individualKey]["date"],
  4. DATA[individualKey]["time"],

huangapple
  • 本文由 发表于 2020年1月4日 00:05:53
  • 转载请务必保留本文链接:https://go.coder-hub.com/59581698.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定