I'm encountering the following error while working with fred_gnp
from quantopian.pipeline.data.quandl
ValueError: Bad response: Pre-processing failed with:
Failed to decode data access token.
fred_gnp
which has suddenly stopped working usingPipeline
. To avoid attaching the entire notebook, the following code raises the error locally.
from quantopian.pipeline.filters import StaticAssets
from quantopian.pipeline import Pipeline, CustomFactor
from quantopian.research import run_pipeline
from quantopian.pipeline.data.quandl import fred_gnp
class LatestMacroEconomic(CustomFactor):
window_length = 1
def compute(self, today, asset_ids, out, values):
out[:] = values[-1]
pipe = Pipeline(
columns={
'fred_gnp': LatestMacroEconomic(inputs=[fred_gnp.value])},
screen=StaticAssets([symbols('AAPL')])
)
df = run_pipeline(pipe, '2017-01-01', '2017-12-01')