formating, better consistency in readers, ability to read files from http (fast and dirty).

This commit is contained in:
Romain Dorgueil
2017-02-12 08:10:22 +01:00
parent 9dab39a474
commit b035bdea32
33 changed files with 203 additions and 158 deletions

View File

@ -13,7 +13,6 @@ Example on how to use :class:`bonobo.Bag` instances to pass flexible args/kwargs
"""
from random import randint
from bonobo import Bag, Graph
@ -26,10 +25,7 @@ def extract():
def transform(topic: str):
return Bag.inherit(
title=topic.title(),
rand=randint(10, 99)
)
return Bag.inherit(title=topic.title(), rand=randint(10, 99))
def load(topic: str, title: str, rand: int):

View File

@ -35,11 +35,7 @@ def load(row: dict):
print(row)
graph = Graph(
extract,
transform,
load
)
graph = Graph(extract, transform, load)
if __name__ == '__main__':
from bonobo import run

View File

@ -31,11 +31,7 @@ def load(s: str):
print(s)
graph = Graph(
extract,
transform,
load
)
graph = Graph(extract, transform, load)
if __name__ == '__main__':
from bonobo import run