-
Notifications
You must be signed in to change notification settings - Fork 4
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
Cleanup Task to Delete incomplete Interviews #831
Comments
* Clarify docassemblecli requirement specifier in actions * Allow complete flexibility in docassemble cli installer * Ensure projects get deleted on failed takedowns, harden actions by using `env` to avoid directly evaluating inputs. * Add to CHANGELOG * Implement PR suggestions for more precautions
Closed wrong issue, sorry |
Brainstorming: This may have an MVP and future improvements. For example, one complication is that one interview could open another interview.
Is it possible to use the API to give every session a tag so that we can just use the tag to delete all of the user's interviews at once? Maybe using the Project name as the tag? We probably need API access to Note: We need to use the auth of the user running the interview, not the auth of the author's API key - sometimes authors "log in" as a different user to test different functionality. I think being in an interview and making a request without a different API key would work (never needed to try it), but can we count on being present in an interview at the time we need to delete it? The user could have navigated away from the interview. We could change how we navigate to an interview so that each "I start the interview" (or similar) Step opens a new window/tab. When we close up a Scenario, we would delete the interview associated with that window/tab before closing it. |
Given:
Then:
Note: We are deleting the interview with API keys. Deleting robotically is slow (introducing more incidental flake) and will run into complications because at some point folks are going to log in as different users in the same test, or use some other complex behavior, and that will be much harder to account for. This is a nice-to-have, not a critical feature. We don't want to make it burdensome if we can reasonably avoid it. Additional work our authors will have to do:
Example of an author creating (and getting back) a new API key for a user: curl -X POST \
https://apps-dev.suffolklitlab.org/api/user/123/api \
-H 'Content-Type: application/json' \
-d '{
"key": "yourAdminAPIKeyWhateverItIs",
"method": "none"
}' This can be done for absolutely any user account. Further things to consider:
Warnings to add to the report:
New tests to write: API tests, no warnings
API with warnings
Non-API warnings
|
Close #831, allow author to delete interviews from interview list
A cleanup task should be to delete any incomplete interviews for the testing user. There are a couple of different API endpoints that might be useful here:
The text was updated successfully, but these errors were encountered: