Skip to main content

Argparse Wrapper for Galaxy

Project description

You write stuff that looks like this, containing all of the information you would ever need about a tool; options, test cases, metadata

from galaxygetopt.ggo import GalaxyGetOpt as GGO
c = GGO(
    options=[
        ['int', 'An integer parameter', {'required': True, 'validate':
                                         'Int', 'default': 10}],
        ['float', 'A float', {'required': True, 'validate': 'Float',
                              'default': 1e-4}],
        ['string', 'A string value', {'required': True, 'multiple': True,
                                      'default': ['Hello', 'World'],
                                      'validate': 'String'}],

And you get data back in a nice dict

{'int': 40, 'float': '1e-4', 'string': ['Hello', 'World'] }

Known Bugs

Currently there is a known bug in the galaxy XML, under highly specific circumstances. If you define a parameter that is

  • required

  • hidden

  • validate String (probably not a hard req)

  • _galaxy_specific

and expect it to properly generate the value, it will not. See lines 206/207 of galaxygetopt/ggo.py for the current hack I use to get around this.

Other

This library features a number of subclasses of galaxygetopt.parameter.parameter, all of which have myriad numbers of options. In order to brutally test these, I have added a class galaxygetopt/tests/parameter_generator.py which can generate every single possible combination of functional calls, given rules you specify. You can then generate hundreds of objects with different sets of options, which you can filter a subset out and test at will. See that classes’s documentation for more information.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

galaxygetopt-0.9.6.tar.gz (16.2 kB view details)

Uploaded Source

Built Distributions

galaxygetopt-0.9.6.linux-x86_64.tar.gz (38.0 kB view details)

Uploaded Source

galaxygetopt-0.9.6-py2.7.egg (61.1 kB view details)

Uploaded Source

File details

Details for the file galaxygetopt-0.9.6.tar.gz.

File metadata

File hashes

Hashes for galaxygetopt-0.9.6.tar.gz
Algorithm Hash digest
SHA256 0224b863171804597697744d92ad0e6f6a58a524533a28143cb6b0f817587c5a
MD5 9e4c806f2c17e7cfdb0f213027968acd
BLAKE2b-256 a6f87b30b8b24743ab24dfa4e5cc48b6e2726d01dc7b53a309ab114d8cb38840

See more details on using hashes here.

File details

Details for the file galaxygetopt-0.9.6.linux-x86_64.tar.gz.

File metadata

File hashes

Hashes for galaxygetopt-0.9.6.linux-x86_64.tar.gz
Algorithm Hash digest
SHA256 2fc4aeb13b5d3a53e563dae391cd7a238b17bb7240d1c579260849d6a3a7420e
MD5 af31447629ee84215bd07805321640ef
BLAKE2b-256 0604f1967f622cf8095c6f00f471512453c2a57f87eb86c9157961b3cbb466a2

See more details on using hashes here.

File details

Details for the file galaxygetopt-0.9.6-py2.7.egg.

File metadata

File hashes

Hashes for galaxygetopt-0.9.6-py2.7.egg
Algorithm Hash digest
SHA256 ed361d82c6594ea2cf48ca0bef992d43e84e198a4fd8b769b5a1c1b9485547ec
MD5 c074552e91887cb0a9e500fb0523d59c
BLAKE2b-256 a59c6258c0f58e5ef44f7ceb6455c834e355e9bd94b79756fee0bf48995a4232

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page