[BugFix] - Update GitHub workflows (#6418)

* Fix technical example

* Remove blocking wf command

* rename wf file

* rename wf file

* fix: gh pages wf

* gh pages

* pip install toml

* toml

* activate venv?

* activate venv?

* simpler?

* ^

* install toml in venv

* install the full project first

* Update poetry after venv

* setuptools & venvs

* install requests instead

* package-lock.json -> yarn.lock

* wf name

---------

Co-authored-by: Henrique Joaquim <henriquecjoaquim@gmail.com>
This commit is contained in:
montezdesousa
2024-05-15 12:28:52 +01:00
committed by GitHub
parent 74652ece6e
commit 83990431f8
8 changed files with 9227 additions and 16242 deletions

View File

@@ -2,6 +2,10 @@
This directory contains the workflows for the OpenBB 🦋 Project. The workflows are:
## 📑 Deploy to GitHub Pages
This GitHub Actions workflow is responsible for building the documentation and deploying it to GitHub Pages. This workflow is triggered when a new change is pushed to the `main` or `release` branch of the repository, and the documentation is published to GitHub Pages.
## Branch Name Check
Objective: To check if pull request branch names follow the GitFlow naming convention before merging.
@@ -58,7 +62,7 @@ Note: The code uses the `pypa/build` package for building the binary wheel and s
This GitHub Actions workflow is designed to automatically generate and update draft releases in a GitHub repository. The workflow is triggered when it is manually dispatched, allowing you to control when the draft releases are updated.
## General Linting
## 🧹 General Linting
This GitHub Actions workflow is responsible for running linting checks on the codebase. This workflow is triggered on pull request events such as `opened`, `synchronize`, and `edited`, and push events on branches with names that start with `feature/`, `hotfix/`, or `release/`. The workflow also sets a number of environment variables and uses Github Actions caching to improve performance.
@@ -79,11 +83,7 @@ The first job, `code-linting`, runs on an Ubuntu machine and performs several li
The second job, `markdown-link-check`, runs on an Ubuntu machine and performs linting of the markdown files in the repository. It uses a Docker container `avtodev/markdown-lint` to perform the linting.
## Deploy to GitHub Pages
This GitHub Actions workflow is responsible for building the documentation and deploying it to GitHub Pages. This workflow is triggered when a new change is pushed to the `main` or `release` branch of the repository, and the documentation is published to GitHub Pages.
## Pull Request Labels
## 🏷️ Pull Request Labels
Automatic labelling of pull requests.

View File

@@ -1,4 +1,4 @@
name: Deploy to GitHub Pages
name: 📑 Deploy to GitHub Pages
on:
push:
@@ -48,27 +48,25 @@ jobs:
libgtk-3-dev \
libwebkit2gtk-4.0-dev
- name: Install dependencies
run: poetry install --no-interaction --no-root
- name: Generate Platform Markdown
run: |
source .venv/bin/activate
poetry install -C openbb_platform --no-interaction
source openbb_platform/.venv/bin/activate
pip install -U poetry
poetry run python openbb_platform/dev_install.py -e all
poetry run python -c "import openbb; openbb.build()"
pip uninstall nbmake -y
poetry run python website/generate_platform_v4_markdown.py
pip install toml
python openbb_platform/dev_install.py -e all
python -c "import openbb; openbb.build()"
python website/generate_platform_v4_markdown.py
- name: Generate Excel Docs
run: |
source .venv/bin/activate
poetry run python website/generate_excel_markdown.py
pip install requests
python website/generate_excel_markdown.py
- name: Generate Widgets Library
run: |
source .venv/bin/activate
poetry run python website/generate_widgets_library.py
pip install requests
python website/generate_widgets_library.py
- name: Setup Node
uses: actions/setup-node@v3

View File

@@ -1,4 +1,4 @@
name: General Linting
name: 🧹 General Linting
env:
PIP_DEFAULT_TIMEOUT: 100

View File

@@ -1,4 +1,4 @@
name: Pull Request Labels
name: 🏷️ Pull Request Labels
on:
pull_request:
@@ -18,8 +18,8 @@ jobs:
mode: exactly
count: 0
labels: "do not merge"
- name: 🏷️ Label OpenBB Platform PRs
uses: srvaroa/labeler@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

View File

@@ -53,7 +53,7 @@ router = Router(prefix="", description="Technical Analysis tools.")
code=[
"crypto_data = obb.crypto.price.historical("
+ " symbol='BTCUSD,ETHUSD,SOLUSD', start_date='2021-01-01', provider='yfinance')",
"rr_data = obb.technical.relative_rotation(data=crypto_data.results, benchmark='BTCUSD',"
"rr_data = obb.technical.relative_rotation(data=crypto_data.results, benchmark='BTC-USD',"
+ " long_period=365, short_period=30, window=30, trading_periods=365)",
],
),
@@ -146,7 +146,6 @@ async def relative_rotation(
rs_momentum : list[Data]
The normalized relative strength momentum data.
"""
params = RelativeRotationQueryParams(
data=data,
benchmark=benchmark,

16217
website/package-lock.json generated vendored

File diff suppressed because it is too large Load Diff

9205
website/yarn.lock vendored Normal file

File diff suppressed because it is too large Load Diff