forked from galaxyproject/galaxy
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[WIP] Implement Expression tools in Galaxy.
- Tool definition languge and plumbing and datatype for expressing expressions as jobs. - Allow connecting expression tools to parameters in workflows, will delay evaluation of workflow so calculated value - Example test expression tools for testing and demonstration. - [WIP] Workflow expression module to allow users to specify arbitrary expressions.
- Loading branch information
Showing
22 changed files
with
551 additions
and
6 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,20 @@ | ||
from .evaluation import evaluate | ||
from .sandbox import execjs, interpolate | ||
from .util import jshead, find_engine | ||
from .script import ( | ||
write_evalute_script, | ||
EXPRESSION_SCRIPT_CALL, | ||
EXPRESSION_SCRIPT_NAME, | ||
) | ||
|
||
|
||
__all__ = ( | ||
'evaluate', | ||
'execjs', | ||
'EXPRESSION_SCRIPT_CALL', | ||
'EXPRESSION_SCRIPT_NAME', | ||
'find_engine', | ||
'interpolate', | ||
'jshead', | ||
'write_evalute_script', | ||
) |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import os | ||
|
||
EXPRESSION_SCRIPT_NAME = "_evaluate_expression_.py" | ||
EXPRESSION_SCRIPT_CALL = "python %s" % EXPRESSION_SCRIPT_NAME | ||
|
||
|
||
def write_evalute_script(in_directory): | ||
""" Responsible for writing the script that evaluates expressions | ||
in Galaxy jobs. | ||
""" | ||
script = os.path.join(in_directory, EXPRESSION_SCRIPT_NAME) | ||
with open(script, "w") as f: | ||
f.write('from galaxy_ext.expressions.handle_job import run; run()') | ||
|
||
return script |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.