Implement tool upgrade assistant.#18728
Conversation
b0df4a3 to
288fa1b
Compare
|
Q; do you think you can autogenerate macros given a tools suite with a lot of duplications? Maybe only the simple ones, without arguments? |
|
I haven't done any dynamic programming since leaving graduate school... a thousand years ago but LCS on XML tokens sounds really fun and fairly viable. Macros are so low-level that you'd probably not even need to understand much about our XML format. I think rather than letting an algorithm decide what should be refactored, it might be better to bake it into the IDE plugin. Allow a dev to highlight a block and extract a macro from it. This is a common thing in a lot of programming environments - https://www.jetbrains.com/help/idea/extract-variable.html. I think a human is going to have a better understanding how these things should be decomposed. |
|
The language server has support for that already. I will talk to @davelopez when he is back. Thanks @jmchilton |
b697873 to
692bb7a
Compare
Inspect a tool's XML file and provide advice on upgrading to new tool versions. It is implemented as a library in tool_util for integration with Planemo in the future but I've added a script here to run it on the command-line directly. It can also output in JSON for integration with external tools such as the galaxy language server.
fd038d3 to
835c9f5
Compare
835c9f5 to
b45c58a
Compare
Inspect a tool's XML file and provide advice on upgrading to new tool versions. It is implemented as library code in tool_util for integration with Planemo in the future but I've added a script here to run it on the command-line directly. It can also output in JSON for integration with external tools such as the galaxy language server.
I sat down to write a tool profile version upgrader to try to advance #18679... but I realized in light of macros it is impossible to do without implementing a whole new set of abstractions to track where parts of the tool XML definition are coming from. I both like my current abstractions and think those ones would be obnoxious 😆😅. Instead, I have settled for a tool that will provide advice on upgrading the tool based on its XML. It can point out things that will need to be fixed, things to consider but cannot be determined with a runtime, and things that you don't need to worry about (little bits of that planemo-green-serotonin where it makes sense).
If someone thinks they can write a tool upgrader that deals with macros or can convince ChatGPT to do it - I think having all these test cases and all the semantic data in terms of upgrade codes, messages, and such will be helpful I am sure.
How to test the changes?
License