release: 0.4.2

This commit is contained in:
Romain Dorgueil
2017-06-18 21:35:30 +02:00
parent b1db4263d4
commit 1d27376785
4 changed files with 25 additions and 6 deletions

View File

@ -1 +1 @@
__version__ = '0.4.1' __version__ = '0.4.2'

View File

@ -28,6 +28,7 @@ class ExecutorStrategy(Strategy):
futures = [] futures = []
for plugin_context in context.plugins: for plugin_context in context.plugins:
def _runner(plugin_context=plugin_context): def _runner(plugin_context=plugin_context):
with plugin_context: with plugin_context:
try: try:
@ -38,6 +39,7 @@ class ExecutorStrategy(Strategy):
futures.append(executor.submit(_runner)) futures.append(executor.submit(_runner))
for node_context in context.nodes: for node_context in context.nodes:
def _runner(node_context=node_context): def _runner(node_context=node_context):
try: try:
node_context.start() node_context.start()

View File

@ -1,6 +1,23 @@
Changelog Changelog
========= =========
v.0.4.2 - 18 june 2017
::::::::::::::::::::::
* [config] Implements a "requires()" service injection decorator for functions (api may change).
* [core] Execution contexts are now context managers.
* [fs] adds a defaut to current working directory in open_fs(...).
* [logging] Adds logging alias for easier imports.
* [stdlib] Fix I/O related nodes (especially json), there were bad bugs with ioformat.
Dependency updates
------------------
* Update bonobo-docker from 0.2.6 to 0.2.8
* Update dependencies.
* Update fs from 2.0.3 to 2.0.4
* Update requests from 2.17.3 to 2.18.1
v.0.4.0 - 10 june 2017 v.0.4.0 - 10 june 2017
:::::::::::::::::::::: ::::::::::::::::::::::

View File

@ -26,7 +26,7 @@ def test_write_csv_to_file_arg0(tmpdir):
@pytest.mark.parametrize('add_kwargs', ({}, { @pytest.mark.parametrize('add_kwargs', ({}, {
'ioformat': settings.IOFORMAT_KWARGS, 'ioformat': settings.IOFORMAT_KWARGS,
},)) }, ))
def test_write_csv_to_file_kwargs(tmpdir, add_kwargs): def test_write_csv_to_file_kwargs(tmpdir, add_kwargs):
fs, filename, services = csv_tester.get_services_for_writer(tmpdir) fs, filename, services = csv_tester.get_services_for_writer(tmpdir)
@ -46,8 +46,8 @@ def test_read_csv_from_file_arg0(tmpdir):
fs, filename, services = csv_tester.get_services_for_reader(tmpdir) fs, filename, services = csv_tester.get_services_for_reader(tmpdir)
with CapturingNodeExecutionContext( with CapturingNodeExecutionContext(
CsvReader(path=filename, delimiter=',', ioformat=settings.IOFORMAT_ARG0), CsvReader(path=filename, delimiter=',', ioformat=settings.IOFORMAT_ARG0),
services=services, services=services,
) as context: ) as context:
context.write(BEGIN, Bag(), END) context.write(BEGIN, Bag(), END)
context.step() context.step()
@ -75,8 +75,8 @@ def test_read_csv_from_file_kwargs(tmpdir):
fs, filename, services = csv_tester.get_services_for_reader(tmpdir) fs, filename, services = csv_tester.get_services_for_reader(tmpdir)
with CapturingNodeExecutionContext( with CapturingNodeExecutionContext(
CsvReader(path=filename, delimiter=','), CsvReader(path=filename, delimiter=','),
services=services, services=services,
) as context: ) as context:
context.write(BEGIN, Bag(), END) context.write(BEGIN, Bag(), END)
context.step() context.step()