Skip to content
This repository has been archived by the owner on Dec 29, 2019. It is now read-only.

Immutability of targets and pure functions #8

Open
krlmlr opened this issue Mar 2, 2018 · 4 comments
Open

Immutability of targets and pure functions #8

krlmlr opened this issue Mar 2, 2018 · 4 comments

Comments

@krlmlr
Copy link
Owner

krlmlr commented Mar 2, 2018

concept from FP.

@krlmlr krlmlr changed the title Immutability of targets Immutability of targets and pure functions Mar 5, 2018
@krlmlr
Copy link
Owner Author

krlmlr commented Mar 5, 2018

@wlandau: Have you thought about the many concepts from functional programming that are picked up by drake and other workflow managers?

@wlandau-lilly
Copy link

Regarding immutability specifically, it first crossed my mind here. In a way, immutability reinforces reproducibility. And the way that drake expects commands that depend on other functions touches on FP a bit. Other parallels have not occurred to me.

@krlmlr
Copy link
Owner Author

krlmlr commented Mar 10, 2018

I did mention purity in the workshop: Ideally, all commands should be pure or at least idempotent (repeated execution doesn't change the results). That's difficult/impossible to check for drake, it's something that the user needs to keep in mind. But we can help by capturing console output.

@wlandau
Copy link

wlandau commented Mar 11, 2018

Drake does try to counter side effects by wrapping commands in calls to local(). But I agree, other requirements of purity are difficult to check. We could add output to the metadata (alongside warnings and messages) roughly here.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants