Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in make_transfers #662

Open
mildfuzz opened this issue Apr 19, 2024 · 0 comments
Open

Error in make_transfers #662

mildfuzz opened this issue Apr 19, 2024 · 0 comments

Comments

@mildfuzz
Copy link

I can see transfer stategy and team selection, but then it falls over with this:

Traceback (most recent call last):
  File "/home/john.farrow/miniconda3/envs/airsenalenv/bin/airsenal_run_pipeline", line 8, in <module>
    sys.exit(run_pipeline())
             ^^^^^^^^^^^^^^
  File "/home/john.farrow/miniconda3/envs/airsenalenv/lib/python3.12/site-packages/click/core.py", line 1157, in __call__
    return self.main(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/john.farrow/miniconda3/envs/airsenalenv/lib/python3.12/site-packages/click/core.py", line 1078, in main
    rv = self.invoke(ctx)
         ^^^^^^^^^^^^^^^^
  File "/home/john.farrow/miniconda3/envs/airsenalenv/lib/python3.12/site-packages/click/core.py", line 1434, in invoke
    return ctx.invoke(self.callback, **ctx.params)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/john.farrow/miniconda3/envs/airsenalenv/lib/python3.12/site-packages/click/core.py", line 783, in invoke
    return __callback(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/john.farrow/miniconda3/envs/airsenalenv/lib/python3.12/site-packages/airsenal/scripts/airsenal_run_pipeline.py", line 240, in run_pipeline
    transfers_ok = make_transfers(fpl_team_id)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/john.farrow/miniconda3/envs/airsenalenv/lib/python3.12/site-packages/airsenal/scripts/make_transfers.py", line 324, in make_transfers
    post_transfer_bank = deduct_transfer_price(pre_transfer_bank, priced_transfers)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/john.farrow/miniconda3/envs/airsenalenv/lib/python3.12/site-packages/airsenal/scripts/make_transfers.py", line 53, in deduct_transfer_price
    transfer["selling_price"] - transfer["purchase_price"]
    ~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~
TypeError: unsupported operand type(s) for -: 'NoneType' and 'int'
@mildfuzz mildfuzz changed the title Error in final step of pipeline Error in make_transfers Apr 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant