Skip to content

contract type not working #4

@s-github-2

Description

@s-github-2

contract_type was not getting used - following change fixes it

    # Temporarily stores JSON data in the browser (generally safe to store up to 2MB of data)
    @app.callback(Output('storage-option-chain-all', 'data'),
                [Input('submit-button-state', 'n_clicks'), Input('storage-historical', 'data'), Input('storage-quotes', 'data')],
                [State('memory-ticker', 'value'), State('memory-expdays','value'), State('memory-confidence','value'),State('memory-contract-type','value')]
                )
    def get_option_chain_all(n_clicks, hist_data, quotes_data, ticker, expday_range, confidence_lvl, contract_type):

        if ticker is None:
            raise PreventUpdate 

        json_data = tos_get_option_chain(ticker, contractType=contract_type, rangeType='ALL', apiKey=API_KEY) # changed from 'ALL'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions