Skip to content
This repository has been archived by the owner on Aug 9, 2024. It is now read-only.

Commit

Permalink
ci: remove nightly branch (#593)
Browse files Browse the repository at this point in the history
  • Loading branch information
ReenigneArcher authored Oct 7, 2023
1 parent cfcd489 commit 78cedc5
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 17 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/update-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Update

on:
pull_request:
branches: [master, nightly]
branches: [master]
types: [opened, synchronize, reopened]
push:
branches: [master]
Expand Down Expand Up @@ -136,5 +136,5 @@ jobs:
author_name: ${{ secrets.GH_BOT_NAME }}
directory: gh-pages
branch: gh-pages
force: true
force: false
message: automatic-update-${{ steps.date.outputs.date }}
31 changes: 16 additions & 15 deletions updater.py
Original file line number Diff line number Diff line change
Expand Up @@ -420,22 +420,23 @@ def process_github_url(owner: str, repo: str, submission: Optional[dict] = None)
if og_data[str(github_data['id'])][k].endswith(test):
og_data[str(github_data['id'])][k] = og_data[str(github_data['id'])][k][:-t_len]

# todo - find more reliable way to test if wiki exists
# test wiki pages and overwrite value if wiki is empty
with lock: # ensure only one thread is making a request to GitHub at a time
if github_data['has_wiki']:
test_url = f'https://github.com/search?q=repo:{owner}/{repo}&type=wikis'
test_wiki = requests_loop(url=test_url, github_wait=True)
if test_wiki.status_code == requests.codes.ok:
# see if string in contents
# not logged in
if f'We couldn’t find any wiki pages matching 'repo:{owner}/{repo}'' in test_wiki.text:
og_data[str(github_data['id'])]['has_wiki'] = False
# logged in
if 'Your search did not match any <!-- -->wikis' in test_wiki.text:
og_data[str(github_data['id'])]['has_wiki'] = False
else:
og_data[str(github_data['id'])]['has_wiki'] = False
exception_writer(error=Exception(f'Unable to search wiki for {owner}/{repo}'), name='GitHub Wiki')
# with lock: # ensure only one thread is making a request to GitHub at a time
# if github_data['has_wiki']:
# test_url = f'https://github.com/search?q=repo:{owner}/{repo}&type=wikis'
# test_wiki = requests_loop(url=test_url, github_wait=True)
# if test_wiki.status_code == requests.codes.ok:
# # see if string in contents
# # not logged in
# if f'We couldn’t find any wiki pages matching &#39;repo:{owner}/{repo}&#39;' in test_wiki.text:
# og_data[str(github_data['id'])]['has_wiki'] = False
# # logged in
# if 'Your search did not match any <!-- -->wikis' in test_wiki.text:
# og_data[str(github_data['id'])]['has_wiki'] = False
# else:
# og_data[str(github_data['id'])]['has_wiki'] = False
# exception_writer(error=Exception(f'Unable to search wiki for {owner}/{repo}'), name='GitHub Wiki')

try:
args.issue_update
Expand Down

0 comments on commit 78cedc5

Please sign in to comment.