Skip to content
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

fix: Use circleci API v1.1 to avoid login error #80

Merged
merged 2 commits into from
May 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/bot.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
runs-on: ubuntu-22.04
env:
IMAGE_NAME: bot
IMAGE_VERSION: '1.3.0'
IMAGE_VERSION: '1.3.1'

steps:
- uses: actions/checkout@v2
Expand Down
2 changes: 1 addition & 1 deletion images/bot/setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = bioconda-bot
version = 0.0.4
version = 0.0.5

[options]
python_requires = >=3.8
Expand Down
6 changes: 3 additions & 3 deletions images/bot/src/bioconda_bot/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -160,13 +160,13 @@ async def fetch_circleci_artifacts(session: ClientSession, workflowId: str) -> [
for job in res_wf_object["items"]:
if job["name"].startswith(f"build_and_test-"):
circleci_job_num = job["job_number"]
url = f"https://circleci.com/api/v2/project/gh/bioconda/bioconda-recipes/{circleci_job_num}/artifacts"
url = f"https://circleci.com/api/v1.1/project/gh/bioconda/bioconda-recipes/{circleci_job_num}/artifacts"

async with session.get(url) as response:
response.raise_for_status()
res = await response.text()

res_object = safe_load(res)
for artifact in res_object["items"]:
for artifact in res_object:
zipUrl = artifact["url"]
pkg = artifact["path"]
if zipUrl.endswith((".conda", ".tar.bz2")): # (currently excluding container images) or zipUrl.endswith(".tar.gz"):
Expand Down
Loading