From a4df2c88859dc6c1742288ff8ca4f856cc74ebbd Mon Sep 17 00:00:00 2001
From: Theo Sanderson
Date: Wed, 11 Oct 2023 16:34:12 +0100
Subject: [PATCH 01/10] Update AboutOverlay.jsx
---
.../src/components/AboutOverlay.jsx | 24 ++++++++++++++++++-
1 file changed, 23 insertions(+), 1 deletion(-)
diff --git a/taxonium_website/src/components/AboutOverlay.jsx b/taxonium_website/src/components/AboutOverlay.jsx
index e0f58bc1..8d99f033 100644
--- a/taxonium_website/src/components/AboutOverlay.jsx
+++ b/taxonium_website/src/components/AboutOverlay.jsx
@@ -1,9 +1,31 @@
import React, { useRef, useEffect } from "react";
import Modal from "react-modal";
+const modalStyle = {
+ content: {
+ top: "50%",
+ left: "50%",
+ transform: "translate(-50%, -50%)",
+ backgroundColor: "#fafafa",
+ border: "1px solid #e2e8f0",
+ borderRadius: "8px",
+ padding: "20px",
+ maxWidth: "700px",
+ maxHeight: "80vh",
+ minWidth: "400px",
+ minHeight: "400px",
+ fontSize: "13px",
+ },
+ overlay: {
+ backgroundColor: "rgba(100, 100, 100, 0.3)",
+ zIndex: 1000,
+ },
+};
+
function AboutOverlay({ enabled, setEnabled, overlayContent }) {
return (
- setEnabled(false)}>
+ setEnabled(false)}
+ style={modalStyle}>
-
-
Citation
+
+
Citation
If you use Taxonium in your research, please cite:
Theo Sanderson (2022){" "}
From 38084f2510262344262ab7269ebfae0d4990c86d Mon Sep 17 00:00:00 2001
From: Theo Sanderson
Date: Wed, 11 Oct 2023 16:52:00 +0100
Subject: [PATCH 04/10] Update AboutOverlay.jsx
---
taxonium_website/src/components/AboutOverlay.jsx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/taxonium_website/src/components/AboutOverlay.jsx b/taxonium_website/src/components/AboutOverlay.jsx
index 21909172..b01df8a6 100644
--- a/taxonium_website/src/components/AboutOverlay.jsx
+++ b/taxonium_website/src/components/AboutOverlay.jsx
@@ -62,7 +62,7 @@ function AboutOverlay({ enabled, setEnabled, overlayContent }) {
project.
-
+
Citation
If you use Taxonium in your research, please cite:
From 0db8b0747cd06d08dd6e3fabd2b6794dad4cb8ae Mon Sep 17 00:00:00 2001
From: Theo Sanderson
Date: Wed, 11 Oct 2023 16:53:56 +0100
Subject: [PATCH 05/10] Rename docker-publish-frontend.yml to
docker-publish-frontend.yml_disabled
---
...-publish-frontend.yml => docker-publish-frontend.yml_disabled} | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename .github/workflows/{docker-publish-frontend.yml => docker-publish-frontend.yml_disabled} (100%)
diff --git a/.github/workflows/docker-publish-frontend.yml b/.github/workflows/docker-publish-frontend.yml_disabled
similarity index 100%
rename from .github/workflows/docker-publish-frontend.yml
rename to .github/workflows/docker-publish-frontend.yml_disabled
From 774f9a7d39c242a0ec972d874ab4c06dee1bbd9b Mon Sep 17 00:00:00 2001
From: Theo Sanderson
Date: Wed, 11 Oct 2023 16:55:16 +0100
Subject: [PATCH 06/10] Delete .github/selenium_tests directory
---
.github/selenium_tests/selenium_tests.py | 42 ------------------------
1 file changed, 42 deletions(-)
delete mode 100644 .github/selenium_tests/selenium_tests.py
diff --git a/.github/selenium_tests/selenium_tests.py b/.github/selenium_tests/selenium_tests.py
deleted file mode 100644
index 9c6a8b5a..00000000
--- a/.github/selenium_tests/selenium_tests.py
+++ /dev/null
@@ -1,42 +0,0 @@
-from selenium import webdriver
-from selenium import webdriver
-from webdriver_manager.chrome import ChromeDriverManager
-
-driver = webdriver.Chrome(ChromeDriverManager().install())
-from selenium.webdriver.chrome.options import Options
-from selenium.webdriver.chrome.service import Service
-from selenium.webdriver.support.ui import WebDriverWait
-from selenium.webdriver.support import expected_conditions as EC
-import time
-import sys
-
-url = sys.argv[1]
-
-chrome_service = Service(
- ChromeDriverManager(chrome_type=ChromeType.CHROMIUM).install())
-
-chrome_options = Options()
-options = [
- "--headless", "--disable-gpu", "--window-size=1920,1200",
- "--ignore-certificate-errors", "--disable-extensions", "--no-sandbox",
- "--disable-dev-shm-usage", "--disable-web-security"
-]
-for option in options:
- chrome_options.add_argument(option)
-
-driver = webdriver.Chrome(service=chrome_service, options=chrome_options)
-
-#driver.get('http://nytimes.com')
-
-driver.get(url)
-
-print(url)
-print("###")
-time.sleep(20)
-
-print(driver.get_log("browser"))
-
-if driver.find_elements_by_css_selector('#view-main'):
- print("Element exists")
-else:
- raise ValueError("Could not find element")
From 0d392354a4542b284c4bb002ca2df60410411c3c Mon Sep 17 00:00:00 2001
From: Theo Sanderson
Date: Wed, 11 Oct 2023 17:18:11 +0100
Subject: [PATCH 07/10] cleanup fails
---
.../docker-publish-frontend.yml_disabled | 80 -------------------
.github/workflows/integration-test.yml | 18 -----
2 files changed, 98 deletions(-)
delete mode 100644 .github/workflows/docker-publish-frontend.yml_disabled
delete mode 100644 .github/workflows/integration-test.yml
diff --git a/.github/workflows/docker-publish-frontend.yml_disabled b/.github/workflows/docker-publish-frontend.yml_disabled
deleted file mode 100644
index 466a409a..00000000
--- a/.github/workflows/docker-publish-frontend.yml_disabled
+++ /dev/null
@@ -1,80 +0,0 @@
-name: Docker publish frontend
-
-# This workflow uses actions that are not certified by GitHub.
-# They are provided by a third-party and are governed by
-# separate terms of service, privacy policy, and support
-# documentation.
-
-on:
- repository_dispatch:
- workflow_dispatch:
- schedule:
- - cron: "37 18 * * *"
- push:
- branches: [master]
- # Publish semver tags as releases.
- tags: ["v*.*.*"]
- pull_request:
- branches: [master]
-
-env:
- # Use docker.io for Docker Hub if empty
- REGISTRY: docker.io
- # github.repository as /
- IMAGE_NAME: theosanderson/taxonium_frontend
-
-jobs:
- build:
- runs-on: ubuntu-latest
- permissions:
- contents: read
- packages: write
- # This is used to complete the identity challenge
- # with sigstore/fulcio when running outside of PRs.
- id-token: write
-
- steps:
- - name: Checkout repository
- uses: actions/checkout@v3
-
- # Install the cosign tool except on PR
- # https://github.com/sigstore/cosign-installer
- - name: Install cosign
- if: github.event_name != 'pull_request'
- uses: sigstore/cosign-installer@d6a3abf1bdea83574e28d40543793018b6035605
- with:
- cosign-release: "v1.7.1"
-
- # Workaround: https://github.com/docker/build-push-action/issues/461
- - name: Setup Docker buildx
- uses: docker/setup-buildx-action@79abd3f86f79a9d68a23c75a09a9a85889262adf
-
- # Login against a Docker registry except on PR
- # https://github.com/docker/login-action
- - name: Log into registry ${{ env.REGISTRY }}
- if: github.event_name != 'pull_request'
- uses: docker/login-action@28218f9b04b4f3f62068d7b6ce6ca5b26e35336c
- with:
- registry: ${{ env.REGISTRY }}
- username: theosanderson
- password: ${{ secrets.DOCKER_TOKEN }}
-
- # Extract metadata (tags, labels) for Docker
- # https://github.com/docker/metadata-action
- - name: Extract Docker metadata
- id: meta
- uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
- with:
- images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
-
- # Build and push Docker image with Buildx (don't push on PR)
- # https://github.com/docker/build-push-action
- - name: Build and push Docker image
- id: build-and-push
- uses: docker/build-push-action@ac9327eae2b366085ac7f6a2d02df8aa8ead720a
- with:
- context: .
- file: ./Dockerfile.frontend
- push: ${{ github.event_name != 'pull_request' }}
- tags: ${{ steps.meta.outputs.tags }}
- labels: ${{ steps.meta.outputs.labels }}
diff --git a/.github/workflows/integration-test.yml b/.github/workflows/integration-test.yml
deleted file mode 100644
index 71571fbe..00000000
--- a/.github/workflows/integration-test.yml
+++ /dev/null
@@ -1,18 +0,0 @@
-name: Integration Test
-
-on:
- repository_dispatch:
- workflow_dispatch:
- push:
- pull_request:
- branches: [master]
- schedule:
- - cron: "0 0 * * *"
-jobs:
- build:
- uses: ./.github/workflows/frontend-test.yml
- python:
- uses: ./.github/workflows/python-test.yml
- # selenium:
- # needs: [build, python]
- # uses: ./.github/workflows/selenium-test.yml
From 653a53720eeb2d230db377ad3c93d9c1fca53ef7 Mon Sep 17 00:00:00 2001
From: Theo Sanderson
Date: Wed, 11 Oct 2023 17:19:01 +0100
Subject: [PATCH 08/10] only trigger electron release on.. release!
---
.github/workflows/electron-build.yml | 2 --
1 file changed, 2 deletions(-)
diff --git a/.github/workflows/electron-build.yml b/.github/workflows/electron-build.yml
index 9601e379..995f42f5 100644
--- a/.github/workflows/electron-build.yml
+++ b/.github/workflows/electron-build.yml
@@ -1,8 +1,6 @@
name: Electron build/release
on:
- push:
- pull_request:
release:
types:
- created
From 323033d478f5d168b517ff3bf428fdede67445e1 Mon Sep 17 00:00:00 2001
From: Theo Sanderson
Date: Wed, 11 Oct 2023 17:19:19 +0100
Subject: [PATCH 09/10] update
---
.github/workflows/{electron-build.yml => electron-release.yml} | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename .github/workflows/{electron-build.yml => electron-release.yml} (100%)
diff --git a/.github/workflows/electron-build.yml b/.github/workflows/electron-release.yml
similarity index 100%
rename from .github/workflows/electron-build.yml
rename to .github/workflows/electron-release.yml
From 600f36efb57d43690f66429bd2def458a380a5fc Mon Sep 17 00:00:00 2001
From: Theo Sanderson
Date: Wed, 11 Oct 2023 17:22:41 +0100
Subject: [PATCH 10/10] up
---
.github/workflows/selenium-test.yml | 43 -----------------------------
1 file changed, 43 deletions(-)
delete mode 100644 .github/workflows/selenium-test.yml
diff --git a/.github/workflows/selenium-test.yml b/.github/workflows/selenium-test.yml
deleted file mode 100644
index caf8a673..00000000
--- a/.github/workflows/selenium-test.yml
+++ /dev/null
@@ -1,43 +0,0 @@
-name: Selenium
-
-on:
- workflow_call:
-
-jobs:
- test:
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v3
- - name: Installed package list
- run: apt list --installed
- - uses: actions/download-artifact@v3
- with:
- name: tfci-taxonium-config
- path: ./data/
- - uses: actions/download-artifact@v3
- with:
- name: taxonium_website_build
- path: ./web/
- - uses: actions/setup-python@v3
- with:
- python-version: "3.8"
- - name: Start server
- run: python -m http.server &
- working-directory: ./web/
- - name: Start server
- run: |
- ls
- python -m http.server 3000 &
- working-directory: ./data/
- - name: Installed package list
- run: apt list --installed
- - name: Remove Chrome
- run: sudo apt purge google-chrome-stable
- - name: Remove default Chromium
- run: sudo apt purge chromium-browser
- - name: Install a new Chromium
- run: sudo apt install -y chromium-browser
- - name: Install all necessary packages
- run: pip install requests beautifulsoup4 pandas webdriver-manager selenium
- - name: Run the selenium script
- run: python .github/selenium_tests/selenium_tests.py "http://localhost:8000/?protoUrl=http://localhost:3000/tfci-taxonium-config.jsonl.gz"