Coder Social home page Coder Social logo

Comments (7)

Fatal1ty avatar Fatal1ty commented on May 16, 2024 1

Hi @rominf @anthrotype

msgpack and pyyaml are going to be extra requirements in the next 3.0 version.

The existing mixins will be imported from mashumaro.mixins.msgpack and mashumaro.mixins.yaml.

from mashumaro.

Fatal1ty avatar Fatal1ty commented on May 16, 2024

@rominf I don't agree with you. If i make dependencies optional, it will break compatibility for those who already use mashumaro. If you really don't want to install dependencies for some reason, you can tell pip to ignore them with --no-dependencies flag.

from mashumaro.

rominf avatar rominf commented on May 16, 2024

Can you explain why do you think "it will break compatibility for those who already use mashumaro"? Users who already have mashumaro installed will not notice the change, as they will not even call pip for installation. On the other hand, if they would want to update all dependencies (but probably they won't if they use only conversion to and from dict only, as I), they will have do:

$ pip install -U mashumaro[msgpack,yaml]

That can be documented.

Also, how can I tell poetry not to install the dependencies? I don't think it's possible.

from mashumaro.

Fatal1ty avatar Fatal1ty commented on May 16, 2024

Users who already have mashumaro installed will not notice the change, as they will not even call pip for installation.

You're totally wrong here. The users should be able to install the current major version of mashumaro without making changes to their requirements. If setuptools had the ability to specify default "extras" dependencies, I would use it. There is the issue for that.

I will consider to make pyyaml and msgpack dependencies optional in the next major release.

from mashumaro.

rominf avatar rominf commented on May 16, 2024

You're totally wrong here. The users should be able to install the current major version of mashumaro without making changes to their requirements.

I don't agree with you, in my opinion it's a minor issue for users. But anyway, you are the creator of the library and I respect your opinion.

I will consider to make pyyaml and msgpack dependencies optional in the next major release.

Nice to hear. I hope you will do it, as it will attract more users.

from mashumaro.

anthrotype avatar anthrotype commented on May 16, 2024

my 2c: I really like mashumaro, I was thinking of replacing my use of cattrs with it, but decided not to because it forces my application to depend on msgpack and yaml which I am not planning on using. Please make them extras! Thanks

from mashumaro.

Fatal1ty avatar Fatal1ty commented on May 16, 2024

And finally these two packages are optional in 3.0.

from mashumaro.

Related Issues (20)

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.