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

Preserving the Area -> Bus mapping #1006

Closed
sourabhdalvi opened this issue Jul 19, 2023 · 2 comments
Closed

Preserving the Area -> Bus mapping #1006

sourabhdalvi opened this issue Jul 19, 2023 · 2 comments
Assignees
Labels

Comments

@sourabhdalvi
Copy link
Collaborator

I have seen an issues where when I'm disconnecting components like Area's and Buses from a system the reference of which buses are in each area is lost. Why is this done?, since we do keep the reference of the Bus when disconnecting a Generator from the system. Can we do the same for Areas ?

@jd-lara
Copy link
Member

jd-lara commented Jan 15, 2024

What would it mean to have an Area referenced in a Bus that isn't in the system? Also, what would it mean to have a bus in an area that isn't in the system?

The described behavior is as expected IMO. I will close this issue since it seems more of an user problem

@jd-lara jd-lara closed this as completed Jan 15, 2024
@daniel-thom
Copy link
Contributor

@sourabhdalvi I want to ensure that your question is addressed. The logic of your question may be inverted. The specific behavior is the following:

  1. User removes an Area or LoadZone from a system.
  2. PSY loops over all buses in the system and removes any connection to the area or load zone. For example, bus.area will be set to nothing.
  3. If the user removes a Bus, the area and/or load zone is still set on that object. That behavior is identical to removing a Generator. This seems a bit odd to me if generator.bus or bus.area is still attached to the system. Maybe we should require removal of child components before removal of the parent.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants