Skip to content

Compose producing unexpected values #38

@christopherjmblack

Description

@christopherjmblack

The following two snippets produce different results:

The following appears to me to be correct:

lens.Each().Parts().F(sum).get()([1,2,3]) # returns 6

Whereas I think this is a bug:

(lens.Each() & lens.Parts().F(sum)).get()([1,2,3]) # returns 1

I'm using python-lenses 1.1.0, running in python 3.9.13.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions