Fix processor options sharing stale column values across calls#582
Merged
Fix processor options sharing stale column values across calls#582
Conversation
Co-authored-by: dale-wahl <32108944+dale-wahl@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix incorrect column options in processor
Fix processor options sharing stale column values across calls
Mar 10, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Processor
get_options()could return stale or incorrect column options from a previous call whenget_columns()returned[], due to shared mutable class state and incorrect dataset references.Root Causes
BasicProcessor.get_options()returned a direct reference tocls.options, allowing callers to mutate the class-level dict, which persisted across calls.work():self.get_options(self.dataset, ...)passed the output dataset (no columns yet), so column-dependent options were never populated with actual column names. Should useself.source_dataset(the input).parent_datasetinget_available_processors():get_options(config=config)omittedparent_dataset, preventing processors from correctly resolving column-dependent options when determining re-runnability.Changes
backend/lib/processor.pyget_options()now returnscopy.deepcopy(cls.options)instead of a direct reference, preventing mutation of shared class state.work()now callsself.get_options(self.source_dataset, config=self.config)so the correct input dataset (with actual columns) is passed.common/lib/dataset.pyget_available_processors()now callsget_options(parent_dataset=self, config=config), passing the parent dataset so processors can evaluate their options in context.Original prompt
🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.