Skip to main content

PEPhub command line interface.

Project description

PEPHubClient

PEP compatible Run pytests pypi-badge pypi-version Coverage Github badge Code style: black

PEPHubClient is a tool to provide Python API and CLI for PEPhub.


Documentation: https://pep.databio.org

Source Code: https://github.com/pepkit/pephubclient


Installation

To install pepdbagent use this command:

pip install pephubclient

or install the latest version from the GitHub repository:

pip install git+https://github.com/pepkit/pephubclient.git

pephubclient features:

  1. push (upload) projects)
  2. pull (download projects)

Additionally, our client supports pephub authorization. The authorization process is based on pephub device authorization protocol. To upload projects or to download private projects, user must be authorized through pephub.

If you want to use your own pephub instance, you can specify it by setting PEPHUB_BASE_URL environment variable. e.g. export PEPHUB_BASE_URL=https://pephub.databio.org/ (This is original pephub instance)

To login, use the login argument; to logout, use logout.


$ phc --help
                                                                                                                   
 Usage: pephubclient [OPTIONS] COMMAND [ARGS]...                                                                   
                                                                                                                   
╭─ Options ───────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ --version             -v                                                                                        │
│ --install-completion            Install completion for the current shell.                                       │
│ --show-completion               Show completion for the current shell, to copy it or customize the              │
│                                 installation.                                                                   │
│ --help                          Show this message and exit.                                                     │
╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─ Commands ──────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ login               Login to PEPhub                                                                             │
│ logout              Logout                                                                                      │
│ pull                Download and save project locally.                                                          │
│ push                Upload/update project in PEPhub                                                             │
╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
$ phc pull --help
                                                                                                                   
 Usage: pephubclient pull [OPTIONS] PROJECT_REGISTRY_PATH                                                          
                                                                                                                   
 Download and save project locally.                                                                                
                                                                                                                   
╭─ Arguments ─────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ *    project_registry_path      TEXT  [default: None] [required]                                                │
╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─ Options ───────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ --force    --no-force      Overwrite project if it exists. [default: no-force]                                  │
│ --help                     Show this message and exit.                                                          │
╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
$ phc push --help
                                                                                                                   
 Usage: pephubclient push [OPTIONS] CFG                                                                            
                                                                                                                   
 Upload/update project in PEPhub                                                                                   
                                                                                                                   
╭─ Arguments ─────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ *    cfg      TEXT  Project config file (YAML) or sample table (CSV/TSV)with one row per sample to constitute   │
│                     project                                                                                     │
│                     [default: None]                                                                             │
│                     [required]                                                                                  │
╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─ Options ───────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ *  --namespace                        TEXT  Project namespace [default: None] [required]                        │
│ *  --name                             TEXT  Project name [default: None] [required]                             │
│    --tag                              TEXT  Project tag [default: None]                                         │
│    --force         --no-force               Force push to the database. Use it to update, or upload project.    │
│                                             [default: no-force]                                                 │
│    --is-private    --no-is-private          Upload project as private. [default: no-is-private]                 │
│    --help                                   Show this message and exit.                                         │
╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯

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

pephubclient-0.5.1.tar.gz (25.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pephubclient-0.5.1-py3-none-any.whl (27.1 kB view details)

Uploaded Python 3

File details

Details for the file pephubclient-0.5.1.tar.gz.

File metadata

  • Download URL: pephubclient-0.5.1.tar.gz
  • Upload date:
  • Size: 25.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pephubclient-0.5.1.tar.gz
Algorithm Hash digest
SHA256 41a8b7af90477c027f0f9205383178381a2bd042d2da18d9e047be81d9597b7a
MD5 2a0cbcc8ec8da32e5780e1263e23eb45
BLAKE2b-256 55dc91e9444c87c7124a612d7d942fcfc7c57daef2d3b2017275e9ec231c474a

See more details on using hashes here.

Provenance

The following attestation bundles were made for pephubclient-0.5.1.tar.gz:

Publisher: python-publish.yml on pepkit/pephubclient

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pephubclient-0.5.1-py3-none-any.whl.

File metadata

  • Download URL: pephubclient-0.5.1-py3-none-any.whl
  • Upload date:
  • Size: 27.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pephubclient-0.5.1-py3-none-any.whl
Algorithm Hash digest
SHA256 9b5a4ab4ae4fb8e4f3fa80681a274f758f7c0678e1caa41aed4067a495ff0653
MD5 a0d3f34c4cff91c88db9f265eec58387
BLAKE2b-256 ed3db47e0d16d6db6c51a3953b1c31f7c8356ebd783b8bb137dc4a20803818bb

See more details on using hashes here.

Provenance

The following attestation bundles were made for pephubclient-0.5.1-py3-none-any.whl:

Publisher: python-publish.yml on pepkit/pephubclient

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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