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

Added deactivate_flows_task #3664

Merged
merged 5 commits into from
Sep 29, 2023
Merged

Added deactivate_flows_task #3664

merged 5 commits into from
Sep 29, 2023

Conversation

lakshmi2506
Copy link
Contributor

@lakshmi2506
Copy link
Contributor Author

Hi @davidmreed

Added the deactivate_flow task through adding the status option in the activate_flow.py task and wrote the necessary test case.

Please review the PR
Thank you

self.logger.info(
f"Activating the following Flows: {self.options['developer_names']}"
)
if self.options["status"]:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lakshmi2506
Consider the test case that status was not entered in the options:

create_task(
            ActivateFlow,
            {
                "developer_names": [
                    "Auto_Populate_Date_And_Name_On_Program_Engagement",
                    "ape",
                ],
            },
        )

Would this code still pass or get a key error, since status is not a task option.

To fix this I recommend adding

self.options["status"] = process_list_arg(
            self.options.get("status"), False
        )
        

to the _init_options() section.

@jofsky jofsky enabled auto-merge (squash) September 29, 2023 19:11
@jofsky jofsky merged commit 7e2068c into main Sep 29, 2023
16 checks passed
@jofsky jofsky deleted the feature/deactivate_flow branch September 29, 2023 19:12
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

Successfully merging this pull request may close these issues.

3 participants