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

Do not reuse event container in source #180

Open
maxnoe opened this issue May 25, 2023 · 0 comments
Open

Do not reuse event container in source #180

maxnoe opened this issue May 25, 2023 · 0 comments

Comments

@maxnoe
Copy link
Member

maxnoe commented May 25, 2023

The source reuses the same container for each event, which creates the potential for hard to trace bugs (information from a previous event creeping over into the next) and even uses mutable default arguments (in ctapipe_io_lst.containers) resulting in the exact same containers being used by multiple source instances.

This comes from older versions of ctapipe, where no better solution was available and creating containers was slow, this has improved since a long time though and the same changes have been made in ctapipe.

Sources should not "reuse" containers.

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