-
Notifications
You must be signed in to change notification settings - Fork 3
Start of v2 platform changes. Update workflow. closes #40. #42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
bbelderbos
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, I think we can remove uv venv, also maybe remove tox and just run pytest against 3.12 or 3.13? Should be pretty reliable. Let me work on the back-end ...
README.md
Outdated
| pixi run test39 | ||
| pixi run test310 | ||
| pixi run test311 | ||
| (search) √ search (main) $ tox |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not with uv?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shall we keep tox or just run pytest?
README.md
Outdated
| (venv) √ search (main) $ python -m pip install . | ||
| (venv) √ search (main) $ python -m pip install ".[test,tools]" | ||
| $ cd search | ||
| √ search (main) $ uv venv |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would remove this step altogether and just go with uv sync + uv run
| requires = ["hatchling"] | ||
| build-backend = "hatchling.build" | ||
| requires = ["uv_build>=0.8.9,<0.9.0"] | ||
| build-backend = "uv_build" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice, can't wait to try this (or see it in GH action)
| "requests", | ||
| "requests-cache", | ||
| "typer[all]", | ||
| "typer", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice
| description = "A search engine for Pybites content" | ||
| readme = "README.md" | ||
| requires-python = ">=3.9" | ||
| requires-python = ">=3.12" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
better
src/pybites_search/bite.py
Outdated
| BITES_ENDPOINT = "https://codechalleng.es/api/bites/" | ||
| PLATFORM_BASE_URL = "https://codechalleng.es/bites/" | ||
| BITES_ENDPOINT = "https://pybitesplatform.com/api/bites/" | ||
| PLATFORM_BASE_URL = "https://pybitesplatform.com/bites/" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems we have codechalleng.es hardcoded in all search modules:
$ ag codechall src
src/pybites_search/youtube.py
3:YOUTUBE_ENDPOINT = "https://codechalleng.es/api/videos/"
src/pybites_search/tip.py
3:TIPS_ENDPOINT = "https://codechalleng.es/api/pytips/"
src/pybites_search/podcast.py
3:PODCAST_ENDPOINT = "https://codechalleng.es/api/podcasts/"
src/pybites_search/bite.py
3:BITES_ENDPOINT = "https://codechalleng.es/api/bites/"
4:PLATFORM_BASE_URL = "https://codechalleng.es/bites/"
src/pybites_search/article.py
3:ARTICLE_ENDPOINT = "https://codechalleng.es/api/articles/"
What about setting the base url once in base.py and import it here?
bbelderbos
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, thanks. I will try it locally and then push a new tag which kicks off a new release.
|
Great work, no on PyPI as 1.1.0 |
This addresses issue 40 and updates the workflow.
The bite channel has been updated to reflect the new platform.
Other channels still need to be updated in line with the backend platform changes.