nsidc / granule-metgen

Metadata generator for direct-to-Cumulus era
Other
0 stars 0 forks source link

Create granule-metgen CLI app with configuration #30

Closed eigenbeam closed 1 month ago

eigenbeam commented 1 month ago

Create a granule-metgen CLI app that:

  1. Is installable
  2. Can be invoked with individual commandline arguments for configuration
  3. Can be invoked with a commandline argument for the file where configuration exists
  4. Starts up, summarizes the current configuration, stop
lisakaser commented 1 month ago

Acceptance criteria:

Scenario: pre-Installation

Operator needs to install python and poetry (instructions will be in App's readme file)

Scenario: installation Given: python and poetry are installed When: operator follows apps install instructions in readme file Then: operator can run app with --help and it shows app name ect.

Scenario: example ini file Given: the app is insalled When: operator runs app with example ini file Then: App shows summary of example ini

lisakaser commented 1 month ago

@eigenbeam please add additional acceptance criteria/scenarios that will be use cases for Amy to test once this issue is handed to her for testing.

eigenbeam commented 1 month ago

@afitzgerrell The instructions in the README in the Requirements, Installation, and Usage sections should give the concrete steps to test this issue. See: https://github.com/nsidc/granule-metgen/blob/main/README.md

afitzgerrell commented 1 month ago

Hi Kevin, here are my suggestions to alleviate the pain-points I encountered, they started at the Poetry install section in the README.md:

Next, install Poetry either by using the official installer if you’re comfortable with the instructions, or by installing it using a package manager (like Homebrew) if this is more familiar to you. When successfully installed, the version of Poetry that’s running should be returned:

$ poetry --version
Poetry (version 1.8.3)

Installation and Running Instameta Make a local directory (i.e., on your computer), and then cd into that directory. Therein, clone the granule-metgen repository:

$ mkdir -p ~/my-projects; cd ~/my-projects
$ git clone https://github.com/nsidc/granule-metgen.git

cd into the granule-metgen directory, install granule-metgen’s Poetry dependencies, and then start the Poetry shell:

$ cd granule-metgen
$ poetry install
$ poetry shell

With the Poetry shell running, start the instameta tool and verify that it’s working by requesting its usage options and having them returned:

$ instameta --help
Usage: instameta [OPTIONS] COMMAND [ARGS]...

Options:
  --help  Show this message and exit.

Commands:
  info
  init
  process
afitzgerrell commented 1 month ago

I re-read the README.md this morning after you spiffed it up. I have one more suggestion: in the Usage section, following the second bullet, i think it'd be helpful to add a bullet to say:

...and one further question: with it installed/runnable on my laptop, is this something that once in production, i'd want to so any sort of $ git "refresh" (inserting the actual command there) to make sure i have the latest version of the tool running? if so, that would be another bullet i'd suggest adding to the Usage section.

eigenbeam commented 1 month ago

Done!

Regarding production, we will have (at that time) a different--and easier--way to install it, upgrade versions, etc. When we get to that ticket(s) we'll update the install and usage instructions.