You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
======================================================================
FAIL: test_data_importers (tests.test_tools.TestTools)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/travis/build/IRC-SPHERE/HyperStream/tests/test_tools.py", line 388, in test_data_importers
assert_all_close(sea_ice_sums.window().values(), list(map(sum, sea_ice.window().values())), 1e-5)
File "/home/travis/build/IRC-SPHERE/HyperStream/tests/helpers.py", line 203, in assert_all_close
.format(i, x, y, prec=prec))
AssertionError: Elements not equal at location 0. a = 15.48000, b = 0.00000
-------------------- >> begin captured logging << --------------------
root: DEBUG: creating session: [uuid=49c40ada-726b-11e7-a3c3-42010a0a140e]
root: DEBUG: Defining a CsvReader tool with parameters {'filename': 'plugins/data_importers/data/sea_ice.csv'}
root: DEBUG: creating sea_ice
root: DEBUG: creating sea_ice_sums
root: DEBUG: Defining a ListSum tool
root: DEBUG: set calculated intervals
--------------------- >> end captured logging << ---------------------
Can't really understand why b = 0.00000 there. The same test runs fine on OS-X also with python 3.6.1. For now I've commented the offending line (last line of test)
Contents of the test:
deftest_data_importers(self):
withHyperStream(file_logger=False, console_logger=False, mqtt_logger=None) ashs:
reader=hs.plugins.data_importers.tools.csv_reader('plugins/data_importers/data/sea_ice.csv')
# noinspection PyTypeCheckerti=TimeInterval(datetime(1990, 1, 1).replace(tzinfo=UTC), datetime(2011, 4, 1).replace(tzinfo=UTC))
# TODO: More complicated tests, including headers, different delimiters, messy data etc etc.sea_ice=hs.channel_manager.memory.get_or_create_stream("sea_ice")
reader.execute(sources=[], sink=sea_ice, interval=ti)
sea_ice_sums=hs.channel_manager.mongo.get_or_create_stream("sea_ice_sums")
hs.tools.list_sum().execute(sources=[sea_ice], sink=sea_ice_sums, interval=ti)
# print(sea_ice_sums.window().values())# TODO: the below assertion is causing travis to fail - why?assert_all_close(sea_ice_sums.window().values(), list(map(sum, sea_ice.window().values())), 1e-5)
The text was updated successfully, but these errors were encountered:
See e.g. here
Logging output:
Can't really understand why b = 0.00000 there. The same test runs fine on OS-X also with python 3.6.1. For now I've commented the offending line (last line of test)
Contents of the test:
The text was updated successfully, but these errors were encountered: