-
Notifications
You must be signed in to change notification settings - Fork 7
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 HTTP POST route (/gen_pgt) that will accept and translate a JSON logical graph submitted from EAGLE #9
Conversation
…N logical graph submitted from EAGLE.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Could you add a small unit test thought? I think that's why the coverage dropped. There are already some tests for this code under https://github.com/ICRAR/daliuge/blob/master/test/dropmake/test_lgweb.py so I would expect this not to be too difficult.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry James! It just occurred to me that there is a bit of logic duplicated actually across both methods that would be good to remove. Again, having a unit test to double-check that nothing gets broken would be great.
…_partition_with_params()). Fixed bug where json.loads() was called twice on incoming JSON because the string was not unescaped. Added unit test for new POST route.
…t hopefully works in python 2 and 3.
…oding that was not required.
Looking good! Merged now into |
I'd be open to making any refinements you suggest.
The new function (gen_pgt_post) is similar to the existing one (gen_pgt). I've only factored out the duplicated list of translation algorithm parameters, since there was a minor inconsistency between the daliuge list and the eagle list ('max_load_imb').