Commit Graph

168 Commits

Author SHA1 Message Date
Dan fb54edac1c Adding additional details to error messages, and cleaning up the cruft around these messages to keep them clear and succinct.
Most noteable is the addition of the line on which the error occurs for script tasks.  It will report the line number and pass back the content of
the line that failed.
The validator only returns the first error it encounters, as it's clear that all we ever get right now is two of the same error.
Did a lot of work between this and spiffworkflow to remove all the places where we obfuscate or drop details as we converted between workflowExceptions and APIExceptions.
Dropped the python levenshtein dependency, in favor of just rolling a simple one ourselves in Spiffworkflow.
2021-07-07 00:53:49 -04:00
Dan 7aa4b0833c Merge remote-tracking branch 'origin/dev' into feature/documents_xls_refactor 2021-07-06 13:11:08 -04:00
Dan 1b1a994360 Refactoring Reference files to use the lookup table, rather than parsing the results directly out of the spreadsheet, or attempting to cache them.
Adding a DocumentService to clean up the FileService, and get Documents well seperated, as it seems likely be pulled out or seperated in the future, there is now a Documents api file as well, for the same reason.
Some other minor changes are just fixing white space to assure our code is linting correctly.
I removed _create_study_workflow_approvals from the base test, as we don't use approvals like this anymore.
2021-07-06 13:10:20 -04:00
NWalker4483 338fe30984 Merge branch 'dev' of https://github.com/sartography/cr-connect-workflow into partial_testing 2021-06-09 14:32:01 -04:00
Dan fce9166c4a Do not require users to be admins for viewing the document directory tab. 2021-06-09 09:51:30 -04:00
Dan Funk 9c4994581d
Merge pull request #324 from sartography/modify-infinite-loop-312
Modify infinite loop #312
2021-06-08 10:30:13 -04:00
mike cullerton d657744816 Added optional `validate_study_id` parameter to the validation api endpoint. 2021-06-03 14:17:12 -04:00
mike cullerton e9fe555e05 New `/datastore/file/{file_id}` endpoint definition 2021-06-01 13:49:21 -04:00
Dan Funk 415964806d
Merge pull request #307 from sartography/standalone-set-default-false-323
Set the default for the `standalone` parameter to `false`. #323
2021-05-14 12:33:33 -04:00
Dan Funk 99da502912
Merge branch 'dev' into 321-Markdown-Macro 2021-05-14 12:32:41 -04:00
mike cullerton 6b242c07e2 Set the default for the `standalone` parameter to `false`. 2021-05-06 11:54:04 -04:00
Kelly McDonald cbd1d01203 Add URL to the study_info('documents') script
fixes #321 - I merged in branches that fix #320 and #297

320-add-default-for-file-data-get
297-filename-in-documents
2021-05-05 11:30:08 -04:00
Dan Funk 34759a2f3d
Merge branch 'dev' into feature/performance-refactor 2021-05-04 11:30:13 -04:00
Dan Funk 77d9bfca43
Merge pull request #296 from sartography/launch-workflow-outside-study-204
Launch workflow outside study 204
2021-05-04 11:16:08 -04:00
Dan a719cf4bf9 When retrieving the study, only update the status of underlying workflows if specifically requested.
Record the size of a file in the database for quick access (this helps with a frontend refactor, so it isn't downloading the file just to see it's size)
Cleaning up the timing/performance metric reporting to make it easier to read.
Fixing a bug that prevented non-admins for getting the document-directory
2021-04-30 11:55:12 -04:00
mike cullerton 24c818bf31 Added study_id to workflow_api 2021-04-29 14:29:21 -04:00
Dan 248ca6a33a Don't require people to be admins just so they can see the list of documents, or we get recursive loads on Kelly's non admin account (and everyone elsees)
todo: Create a ticket to assure we don't get in an infinite loading loop.
2021-04-27 12:14:37 -04:00
Mike Cullerton 39fcab3730
Merge branch 'dev' into launch-workflow-outside-study-204 2021-04-26 10:27:32 -04:00
mike cullerton 5936b2e8ef Created 2 api endpoints; one to get a workflow from a workflow spec, and one to list all standalone workflow specs.
Also added `standalone` argument to workflow_spec schema properties
2021-04-26 08:27:24 -04:00
Dan cf051a7d4f Merge branch 'dev' into 277-Document-pane
# Conflicts:
#	crc/api/file.py
2021-04-21 14:09:44 -04:00
Dan ecff7d20d3 Adding a test for the new endpoint and cleaning up the API documenation 2021-04-21 14:00:19 -04:00
Kelly McDonald e2197ddab9 Changes to support the frontend data pane
fixes #277 and requires frontend branch 277-document-pane
2021-04-20 08:12:27 -04:00
mike cullerton 4615649938 Added delete_files argument to the workflow restart api endpoint 2021-04-15 11:21:51 -04:00
Kelly McDonald 949f3be403 give an endpoint to return all files associated with a study 2021-04-12 12:23:33 -04:00
Dan 2100f27976 fixing the api.yml file which was starting to throw errors when updating the libraries.
Seems that sqlalchemy now has a hard time incrementing sequences, so putting in a fix for this.
Upgrading many of our libraries, to avoid any disconnects as we try to handle security patches from these automated bumps.
2021-04-02 17:10:05 -04:00
Dan ded11ddd82 fixing a code smell 2021-03-26 20:25:34 -04:00
Dan Funk 14386b8ba9
Merge pull request #264 from sartography/bug/243_complete_all
Bug/243 complete all
2021-03-14 12:34:55 -04:00
Dan 15c64c862e Adding an argument to update task that will allow it to complete all remaining tasks through an "update_all" flag,
this will allow us to remove some fairly complex logic from the front end that isn't behaving properly.
2021-03-12 20:41:07 -05:00
mike cullerton 14e62a7ec2 Modify the send_email api endpoint (in Configurator Tools section) to accept subject, message, and data.
Subject, address and message are required.
Data is not required.
Message is in the body of the request.
Subject, address, and data are in the query string.
2021-03-11 11:10:10 -05:00
Dan aac3d5c16e Bug #255, this requires the front end to pass in the name of the task, when doing a lookup. This will prevent a bug where we have multiple user tasks, with enum fields that set the same variable, but use different lookup tables to populate the dropbown or search feature. 2021-03-01 14:54:04 -05:00
Kelly McDonald 003bf2f9b9 Remove Approvals per ticket 183 2021-02-16 09:05:29 -05:00
mike cullerton e1532a90c9 New api endpoint for restarting a workflow. Unsure if I needed the responses section. **Dan, can you check this?**
Also, removed clear_data and reload_spec as parameters for standard get workflow endpoint.
2021-01-19 15:00:39 -05:00
mike cullerton 6a9e6d3570 Restart workflow without form data. Committing so Dan can check it out 2021-01-14 15:32:14 -05:00
Kelly McDonald adc4dc4453 redid the api a bit so that nothing was using open security - added a new endpoint for getting a workflow spec that uses the alternate API_TOKEN security and leave the original endpoint as it was. 2020-12-11 12:03:41 -05:00
Kelly McDonald 3a1160efac refactored calls into a service 2020-12-11 11:41:32 -05:00
Kelly McDonald 993c7bc76e fixed error on api.yml from search / replace 2020-12-11 08:29:37 -05:00
Kelly McDonald 3f56dfe484 Move all workflow sync stuff into new file
Make changes to api naming scheme
add some error checking around endpoints for missing/invalid endpoints
2020-12-10 10:46:23 -05:00
Kelly McDonald e377a05dea Add some punctuation 2020-12-09 13:50:52 -05:00
Kelly McDonald c57b17df1e Add a robust way of adding an API key, update examples and documentation for swagger API and add the ability to completely sync the local system from the remote system. 2020-12-09 12:13:17 -05:00
Kelly McDonald 0e1aa59fa1 Make a change to make sure that if there is a new file locally that is not present remotely when we pull from the remote, the new local file gets deleted.
Also: add several things to the requirements.txt that should have been there in the first place.
2020-12-08 13:42:01 -05:00
Kelly McDonald f26a8615a4 Get more file details so we can fill out everything locally and also add a method to download the file by md5_hash 2020-12-07 08:49:38 -05:00
Kelly McDonald d41d018fe3 For a given workflow - find the files that are different from a remote endpoint for the same workflow 2020-12-04 11:49:07 -05:00
Kelly McDonald 0f59d3de09 add endpoint that gets a record for all changed /new workflow_specs at a remote endpoint 2020-12-03 14:45:57 -05:00
Kelly McDonald 92aa1b971d commit before removing big long SQL 2020-12-02 16:04:00 -05:00
Dan 66693d9f3a Removing datastore script, as it isn't used in the api at all. 2020-11-18 15:06:28 -05:00
Dan c62b73a539 drop some of the test-only api endpints and rework the tests so they aren't needed 2020-11-18 15:04:36 -05:00
Kelly McDonald 70425eee0d Add last_updated field - change the api signature to be closer to what we need going forward, but retain the old methods for testing the script get/set through the API 2020-11-13 12:03:29 -05:00
Kelly McDonald 7c2c725840 save before changing how API works 2020-11-13 09:58:21 -05:00
Kelly McDonald 9a4d167dcd Add in api changes 2020-11-11 09:44:58 -05:00
Dan Funk 66e49a347a Minor tweaks to the eval endpoint, which should take both the expression and the data as one data structure. 2020-08-20 16:13:48 -04:00