diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 7eba2cf81..735ad5a6b 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -67,11 +67,11 @@ jobs: uses: actions/checkout@v3 with: path: functions - # Install python 3.9 - - name: Install python 3.9 - uses: actions/setup-python@v3 + # Install python 3.10.17 + - name: Install python 3.10.17 + uses: actions/setup-python@v4 with: - python-version: 3.9 + python-version: 3.10.17 # Install dependencies - uses: actions/cache@v3 id: cache diff --git a/.github/workflows/test-all.yaml b/.github/workflows/test-all.yaml index a09ba17a2..3d2e7d7b1 100644 --- a/.github/workflows/test-all.yaml +++ b/.github/workflows/test-all.yaml @@ -14,7 +14,7 @@ jobs: shell: bash run: echo "::set-output name=branch::${GITHUB_REF#refs/heads/}" id: myref - + - uses: actions/checkout@v4 - id: set-matrix # This is very hacky, but it goes like that: @@ -66,11 +66,11 @@ jobs: uses: actions/checkout@v4 with: path: functions - # Install python 3.9 - - name: Install python 3.9 - uses: actions/setup-python@v3 + # Install python 3.10.17 + - name: Install python 3.10.17 + uses: actions/setup-python@v4 with: - python-version: 3.9 + python-version: 3.10.17 # Install dependencies - uses: actions/cache@v3 id: cache @@ -99,7 +99,7 @@ jobs: runs-on: ubuntu-latest needs: run_monorepo_tests continue-on-error: false - + steps: - name: Get the current branch name shell: bash @@ -114,10 +114,10 @@ jobs: with: repository: mlrun/marketplace path: marketplace - - name: Install python 3.9 - uses: actions/setup-python@v3 + - name: Install python 3.10.17 + uses: actions/setup-python@v4 with: - python-version: 3.9 + python-version: 3.10.17 - name: Install requirements run: | cd functions diff --git a/cli/marketplace/_static/css/custom.css b/cli/marketplace/_static/css/custom.css index a0e9ad337..0912e00cd 100644 --- a/cli/marketplace/_static/css/custom.css +++ b/cli/marketplace/_static/css/custom.css @@ -1,12 +1,49 @@ -.bd-sidebar { - display: none; +html:root { + --sd-color-primary: #2750ff; + --pst-color-primary: var(--sd-color-primary); + --pst-color-link-hover: var(--sd-color-primary); + --pst-color-secondary: var(--sd-color-primary); + --sd-color-secondary: #6c757d; + --sd-color-success: #28a745; + --sd-color-info: #2750ff; + --sd-color-warning: #e3781a; + --sd-color-danger: #dc3545; + --sd-color-light: #f8f9fa; + --sd-color-muted: #6c757d; + --sd-color-dark: #212529; + --sd-color-primary-highlight: var(--sd-color-primary); + --sd-color-secondary-highlight: #5c636a; + --sd-color-success-highlight: #228e3b; + --sd-color-info-highlight: var(--sd-color-primary); + --sd-color-warning-highlight: #cc986b; + --sd-color-danger-highlight: #bb2d3b; + --sd-color-light-highlight: #d3d4d5; + --sd-color-muted-highlight: #5c636a; + --sd-color-dark-highlight: #1c1f23; + --sd-color-primary-text: #fff; + --sd-color-secondary-text: #fff; + --sd-color-success-text: #fff; + --sd-color-info-text: #fff; + --sd-color-warning-text: #fff; + --sd-color-danger-text: #fff; + --sd-color-light-text: #212529; + --sd-color-muted-text: #fff; + --sd-color-dark-text: #fff; + --pst-color-accent: var(--sd-color-primary); + --pst-color-secondary-highlight: var(--sd-color-primary); + --pst-color-table-row-hover-bg: #d8dfff; + --bs-dropdown-min-width: 8rem; } -.header-article { - height: 0; - background-color: transparent; +.bd-sidebar, +.header-article-items__start, +.theme-switch-button, +.search-button, +.footer-content{ + display: none !important; } -.footer-content { - display: none; +.bd-header-article { + position: relative; + box-shadow: none !important; } diff --git a/cli/marketplace/conf.template b/cli/marketplace/conf.template index b35bef65e..714a885ce 100644 --- a/cli/marketplace/conf.template +++ b/cli/marketplace/conf.template @@ -13,6 +13,7 @@ import re import sys +import os sys.path.insert(0, "{{sphinx_docs_target}}") @@ -28,7 +29,7 @@ master_doc = "index" # The short X.Y version version = "{{version}}" release = "{{release}}" - +master_doc = "index" # -- General configuration --------------------------------------------------- @@ -72,6 +73,8 @@ source_suffix = { ".md": "myst-nb", } +# If you want to mock imports during autodoc +autodoc_mock_imports = [{{mock_imports}}] # -- Options for HTML output ------------------------------------------------- @@ -86,22 +89,33 @@ html_theme = "sphinx_book_theme" html_static_path = ["_static"] html_css_files = ["css/custom.css"] +# conf.py + +html_context = { + "default_mode": "light", # Enforces light mode on page load +} + html_theme_options = { "repository_url": "{{repository_url}}", - "use_repository_button": True, - "use_issues_button": True, - "use_edit_page_button": True, + "repository_branch": "{{repository_branch}}", + "path_to_docs": "docs", "use_repository_button": False, "use_issues_button": False, "use_edit_page_button": False, - "path_to_docs": "docs", - "repository_branch": "{{repository_branch}}", - "single_page": True, + "home_page_in_toc": False, "navigation_with_keys": False, - "use_download_button": False, "use_fullscreen_button": False, + "show_navbar_depth": 1, + "theme_dev_mode": False, + "launch_buttons": {}, + "switcher": False, + "search_bar_text": "", + "search_bar_position": "none", } +# Prevents generation of searchindex.js +html_search = False + html_title = "{{html_title}}" html_logo = "{{html_logo}}" html_favicon = "{{html_favicon}}" @@ -124,3 +138,12 @@ def copy_doc(src, dest, title=""): changed = True out.write(line) {% endraw %} + +# -- Post-build cleanup ------------------------------------------------------ +def remove_searchtools(app, exception): + searchtools_path = os.path.join(app.outdir, '_static', 'searchtools.js') + if os.path.exists(searchtools_path): + os.remove(searchtools_path) + +def setup(app): + app.connect("build-finished", remove_searchtools) diff --git a/cli/marketplace/python.html b/cli/marketplace/python.html index a2928d85f..307959f49 100644 --- a/cli/marketplace/python.html +++ b/cli/marketplace/python.html @@ -5,9 +5,22 @@ - - - + + + Source @@ -19,4 +32,4 @@ - \ No newline at end of file + diff --git a/cli/marketplace/yaml.html b/cli/marketplace/yaml.html index 376bbc9b9..9fd08f945 100644 --- a/cli/marketplace/yaml.html +++ b/cli/marketplace/yaml.html @@ -5,9 +5,22 @@ - - - + + + Source @@ -19,4 +32,4 @@ - \ No newline at end of file + diff --git a/requirements.txt b/requirements.txt index faa20126f..0c3470959 100644 --- a/requirements.txt +++ b/requirements.txt @@ -6,11 +6,11 @@ pipenv myst_nb black~=22.0 isort~=5.7 -sphinx==4.0.2 -sphinx-book-theme==0.3.3 -sphinx-togglebutton==0.3.1 -sphinxcontrib-applehelp<=1.0.7 -sphinxcontrib.devhelp<=1.0.5 -sphinxcontrib-htmlhelp<=2.0.4 -sphinxcontrib-serializinghtml<=1.1.9 -sphinxcontrib-qthelp<=1.0.6 \ No newline at end of file +sphinx~=8.1.0 +sphinx-book-theme~=1.1.3 +sphinx-togglebutton==0.3.2 +sphinxcontrib-applehelp==1.0.8 +sphinxcontrib-devhelp==1.0.6 +sphinxcontrib-htmlhelp==2.0.6 +sphinxcontrib-serializinghtml==1.1.10 +sphinxcontrib-qthelp==1.0.7