Coder Social home page Coder Social logo

pydux's People

Contributors

chriskiehl avatar isnifer avatar kasbah avatar usrlocalben avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

pydux's Issues

Needs a license

Could you clarify what license you are releasing this under please?

Missing README.md in tarball on PyPI

The tarball on PyPI for version 0.2.0 is missing the README.md file, which causes pip install to fail:

Collecting pydux>=0.1.0 (from urwid_pydux==0.2.0->-r ./edge_vm_installer/requirements.txt (line 4))
  Downloading pydux-0.2.0.tar.gz
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-build-ESMAa7/pydux/setup.py", line 17, in <module>
        long_description=open('README.md').read(),
    IOError: [Errno 2] No such file or directory: 'README.md'

Performance degradation when using combine_reducer and state consists of objects that implement `__eq__`

The combine function is causing a huge performance degradation by using the equality operator != instead of is not.

has_changed = (has_changed or
next_state_for_key != previous_state_for_key)

This causes the whole state to be compared on each action that reaches the reducer, even if the actions are not handled in any reducer at all.

When the state consists of dictionaries, is not that obvious because dictionary comparison is very fast.
When the state consists of 'normal' class objects its also fast because __eq__ falls back to comparing identity using is.

When we modeled our state using pydantic it converts the objects to dicts first to compare for equality when using != which caused a significant performance impact.

We simply fixed it using is not in the combine function.

zuhause-plattform@f5e2bce

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.