Skip to content

Commit

Permalink
Migrating from setup.py to pyproject.toml (#35)
Browse files Browse the repository at this point in the history
* Moved from hardcoded version to importlib.metadata

* Added paperscraper import to README.md

* Migrated from setup.py to pyproject.toml for packaging
  • Loading branch information
jamesbraza authored Mar 13, 2024
1 parent b1807cc commit 6b49bd9
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 28 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ pip install git+https://github.com/blackadad/paper-scraper.git
## Usage

```python
import paperscraper

papers = paperscraper.search_papers('bayesian model selection',
limit=10,
pdir='downloaded-papers')
Expand Down
4 changes: 3 additions & 1 deletion paperscraper/version.py
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
__version__ = "1.3.2"
from importlib.metadata import version

__version__ = version("paper-scraper")
37 changes: 37 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,37 @@
[project]
authors = [
{email = "hello@futureforecasts.io", name = "blackadad"},
]
# Full list: https://pypi.python.org/pypi?%3Aaction=list_classifiers
classifiers = [
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python",
]
dependencies = [
"aiohttp",
"pybtex",
"pypdf",
]
description = "LLM Chain for answering questions from docs"
keywords = ["question answering"]
license = {file = "LICENSE"}
maintainers = [
{email = "hello@futureforecasts.io", name = "blackadad"},
{email = "jamesbraza@gmail.com", name = "James Braza"},
]
name = "paper-scraper"
readme = "README.md"
requires-python = ">=3.8"
urls = {repository = "https://github.com/blackadad/paper-scraper"}
version = "1.3.2"

[tool.codespell]
check-filenames = true
check-hidden = true
Expand Down Expand Up @@ -91,6 +125,9 @@ max-doc-length = 97 # Match line-length
# defaults when analyzing docstring sections.
convention = "google"

[tool.setuptools.packages.find]
include = ["paperscraper*"]

[tool.tomlsort]
all = true
in_place = true
Expand Down
27 changes: 0 additions & 27 deletions setup.py

This file was deleted.

0 comments on commit 6b49bd9

Please sign in to comment.