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

KeyError: code looking for facility type "manufacturing" #211

Open
rjhanes opened this issue Jan 8, 2025 · 0 comments
Open

KeyError: code looking for facility type "manufacturing" #211

rjhanes opened this issue Jan 8, 2025 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@rjhanes
Copy link
Collaborator

rjhanes commented Jan 8, 2025

branch: dev-circfutures-liaison

running with lines 7-10 in des_interface.py commented out

data branch: tiny-circfutures-tiny

Scenario options: computing locations, running routes, instantiating CostGraph

CostGraph instantiates correctly, Components and Context are correct

The error is thrown after the DES begins

Context populated with components at 90 s
Traceback (most recent call last):
  File "C:\Users\rhanes\GitHub\celavi\celavi\component.py", line 146, in bol_process
    count_inventory = self.context.count_facility_inventories[self.current_location]
KeyError: 'manufacturing_10000011'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "C:\Users\rhanes\AppData\Local\anaconda3\envs\celavi\lib\runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "C:\Users\rhanes\AppData\Local\anaconda3\envs\celavi\lib\runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "C:\Users\rhanes\GitHub\celavi\celavi\__main__.py", line 25, in <module>
    Scenario(parser=PARSER)
  File "C:\Users\rhanes\GitHub\celavi\celavi\scenario.py", line 111, in __init__
    self.execute()
  File "C:\Users\rhanes\GitHub\celavi\celavi\scenario.py", line 486, in execute
    self.context.run()
  File "C:\Users\rhanes\GitHub\celavi\celavi\des.py", line 568, in run
    self.env.run(until=int(self.max_timesteps))
  File "C:\Users\rhanes\AppData\Local\anaconda3\envs\celavi\lib\site-packages\simpy\core.py", line 246, in run
    self.step()
  File "C:\Users\rhanes\AppData\Local\anaconda3\envs\celavi\lib\site-packages\simpy\core.py", line 204, in step
    raise exc
KeyError: 'manufacturing_10000011'
@rjhanes rjhanes added the bug Something isn't working label Jan 8, 2025
@rjhanes rjhanes self-assigned this Jan 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant