Skip to content

Commit

Permalink
rearrange and add better intra-package references
Browse files Browse the repository at this point in the history
  • Loading branch information
Jermiah committed Nov 19, 2023
1 parent 1c3e285 commit f861774
Show file tree
Hide file tree
Showing 18 changed files with 29 additions and 21 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@

## v0.1.0 (19/11/2023)

- First release of `nbia_toolkit`!
- First release of `nbiatoolkit`!
8 changes: 4 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@ If you are proposing a feature:

## Get Started!

Ready to contribute? Here's how to set up `nbia_toolkit` for local development.
Ready to contribute? Here's how to set up `nbiatoolkit` for local development.

1. Download a copy of `nbia_toolkit` locally.
2. Install `nbia_toolkit` using `poetry`:
1. Download a copy of `nbiatoolkit` locally.
2. Install `nbiatoolkit` using `poetry`:

```console
$ poetry install
Expand All @@ -69,5 +69,5 @@ Before you submit a pull request, check that it meets these guidelines:

## Code of Conduct

Please note that the `nbia_toolkit` project is released with a
Please note that the `nbiatoolkit` project is released with a
Code of Conduct. By contributing to this project you agree to abide by its terms.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ See the [Wiki](https://github.com/jjjermiah/NBIA-toolkit/wiki) for more informat


### none of this works yet lol but it will soon
# nbia_toolkit
# nbiatoolkit

A python package to query the National Biomedical Imaging Archive (NBIA) database.

## Installation

```bash
$ pip install nbia_toolkit
$ pip install nbiatoolkit
```

## Usage
Expand All @@ -28,8 +28,8 @@ Interested in contributing? Check out the contributing guidelines. Please note t

## License

`nbia_toolkit` was created by Jermiah Joseph. It is licensed under the terms of the MIT license.
`nbiatoolkit` was created by Jermiah Joseph. It is licensed under the terms of the MIT license.

## Credits

`nbia_toolkit` was created with [`cookiecutter`](https://cookiecutter.readthedocs.io/en/latest/) and the `py-pkgs-cookiecutter` [template](https://github.com/py-pkgs/py-pkgs-cookiecutter).
`nbiatoolkit` was created with [`cookiecutter`](https://cookiecutter.readthedocs.io/en/latest/) and the `py-pkgs-cookiecutter` [template](https://github.com/py-pkgs/py-pkgs-cookiecutter).
2 changes: 1 addition & 1 deletion driver.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from src.nbia import NBIAClient
from nbiatoolkit import NBIAClient
import requests

Check failure on line 2 in driver.py

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 3.11)

Ruff (F401)

driver.py:2:8: F401 `requests` imported but unused

Check failure on line 2 in driver.py

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 3.10)

Ruff (F401)

driver.py:2:8: F401 `requests` imported but unused

Check failure on line 2 in driver.py

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 3.12)

Ruff (F401)

driver.py:2:8: F401 `requests` imported but unused

Check failure on line 2 in driver.py

View workflow job for this annotation

GitHub Actions / build (macos-latest, 3.12)

Ruff (F401)

driver.py:2:8: F401 `requests` imported but unused
from pprint import pprint

Expand Down
7 changes: 7 additions & 0 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tool.poetry]
name = "nbia_toolkit"
name = "nbiatoolkit"
version = "0.1.0"
description = "A python package to query the National Biomedical Imaging Archive (NBIA) database."
authors = ["Jermiah Joseph"]
Expand Down
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions src/nbia.py → src/nbiatoolkit/nbia.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from src.utils.nbia_endpoints import NBIA_ENDPOINTS
from src.auth import OAuth2
from src.utils.logger import setup_logger
from nbiatoolkit.auth import OAuth2
from nbiatoolkit.utils.nbia_endpoints import NBIA_ENDPOINTS
from nbiatoolkit.utils.logger import setup_logger
import requests
from requests.exceptions import JSONDecodeError as JSONDecodeError
class NBIAClient:
Expand Down
File renamed without changes.
6 changes: 6 additions & 0 deletions src/nbiatoolkit/utils/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
from .logger import setup_logger
from .nbia_endpoints import NBIA_ENDPOINTS
__all__ = [
"setup_logger",
"NBIA_ENDPOINTS"
]
File renamed without changes.
File renamed without changes.
5 changes: 0 additions & 5 deletions src/utils/__init__.py

This file was deleted.

File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/tests/test_auth.py → tests/test_auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# pytest -v -s

import pytest
from ..auth import OAuth2
from nbiatoolkit import OAuth2
import time


Expand Down
2 changes: 1 addition & 1 deletion src/tests/test_nbia.py → tests/test_nbia.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#####
# pytest -v -n 8
import pytest
from ..nbia import NBIAClient
from nbiatoolkit import NBIAClient

@pytest.fixture(scope="session")
def nbia_client():
Expand Down

0 comments on commit f861774

Please sign in to comment.