def rotation_speculation() -> str: query = request.args.get('fq') if query is None: query = '' view = RotationChanges(oracle.if_todays_prices(out=False), oracle.if_todays_prices( out=True), cs.playability(), speculation=True, query=query) return view.page()
def rotation_speculation_files(changes_type: str) -> Response: out = changes_type != 'new' changes = oracle.if_todays_prices(out=out) s = '\n'.join('4 {name}'.format(name=card.to_mtgo_format(c.name)) for c in changes) return make_response( s, 200, { 'Content-type': 'text/plain; charset=utf-8', 'Content-Disposition': f'attachment; filename={changes_type}.txt' })
def rotation_speculation() -> str: view = RotationChanges(oracle.if_todays_prices(out=False), oracle.if_todays_prices(out=True), cs.playability(), speculation=True) return view.page()