MAINT: Moved DailyReturn to protocol module to break circular references

and removed code that solved that same problem with conditional imports.
This commit is contained in:
Richard Frank authored and Eddie Hebert committed 2013-03-01 16:05:39 -05:00
1 parent f1ff9cee0d
commit ebdb5429aa
7 files changed
+40 -41

No files matched your search

+4 -3
View File
@@ -1,5 +1,5 @@
#
# Copyright 2012 Quantopian, Inc.
# Copyright 2013 Quantopian, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -21,8 +21,9 @@ import pytz
import numpy as np
import zipline.finance.risk as risk
import zipline.finance.trading as trading
from zipline.protocol import DailyReturn
from test_risk import RETURNS
@@ -52,7 +53,7 @@ class RiskCompareIterativeToBatch(unittest.TestCase):
cur_returns = []
for i, ret in enumerate(RETURNS):
todays_return_obj = trading.DailyReturn(
todays_return_obj = DailyReturn(
todays_date,
ret
)