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

Rebuilding a ConditionalDimension with no factor adds a factor. #2325

Open
EdCaunt opened this issue Mar 4, 2024 · 2 comments
Open

Rebuilding a ConditionalDimension with no factor adds a factor. #2325

EdCaunt opened this issue Mar 4, 2024 · 2 comments

Comments

@EdCaunt
Copy link
Contributor

EdCaunt commented Mar 4, 2024

If a ConditionalDimension is created with factor=None, then self._factor is set to None, but self.factor will return 1. As such, when rebuilding a ConditionalDimension with no factor, a factor of 1 is added unexpectedly, changing the generated code.

@georgebisbas
Copy link
Contributor

Is there an MFE for this?

@EdCaunt
Copy link
Contributor Author

EdCaunt commented May 17, 2024

Create a ConditionalDimension with a condition but no factor, then compare cd._factor to cd._rebuild()._factor

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

No branches or pull requests

2 participants