Coder Social home page Coder Social logo

flutter_apod's Introduction

flutter_apod

A simple flutter application featuring Astronomy Picture Of the Day NASA API.

This app showcase:

  • A simple ViewModel approach with ChangeNotifier with a separated repository layer (ร  la clean/hexagonal architecture)
  • Injecting dependency with provider
  • Running ViewModel test with simulated time with FakeAsync. So the correct behavior of the ViewModel is tested in a deterministic fashion.
  • Displaying an "infinite scroll" grid of images

This toy app allowed to uncover a bug in Flutter 2.0.3 : There is a socket leak every time an image cannot be loaded (when an non ok http code is returned). This app has missing days, so a lot of 404 is returned when fetching images. Over time too many sockets are kept opened, and no more requests can be performed.

Getting Started

Just launch the app with :

flutter run

To exhibit the socket leak, run the app and scroll to the bottom, at the end it will have a lot of 404 (files not yet uploaded). At some point no more request can be perfomed, and fails with (on iOS):

dnssd_clientstub deliver_request: socketpair failed 24 (Too many open files)

flutter_apod's People

Watchers

James Cloos avatar Alexandre Delattre avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.