Slacker News Slacker News logo featuring a lazy sloth with a folded newspaper hat
  • top
  • new
  • show
  • ask
  • jobs
Library

Comment by me-vs-cat

6 months ago

This style looks pretty good to me:

    pipeline = task(...)
    pipeline |= task(...)

So does this style:

    steps = [task(...), task(...)]
    pipeline = functools.reduce(operator.or_, steps)

But it appears you can just change "task" to "Task" and then:

    pipeline = pyper.Pipeline([Task(...), Task(...)])

0 comments

me-vs-cat

Reply

No comments yet

Contribute on Hacker News ↗

Slacker News

Product

  • API Reference
  • Hacker News RSS
  • Source on GitHub

Community

  • Support Ukraine
  • Equal Justice Initiative
  • GiveWell Charities