From ec7d07c635c487fb19e04c48ebdffa7752015330 Mon Sep 17 00:00:00 2001 From: Haejoon Lee Date: Tue, 28 Nov 2023 10:38:29 +0900 Subject: [PATCH] [SPARK-46111][DOCS][PYTHON] Add copyright to the PySpark official documentation ### What changes were proposed in this pull request? This PR proposes to add the Apache Spark Foundation copyright notice to the bottom of the PySpark official documentation. ### Why are the changes needed? Our current documentation is missing the copyright. The addition of the copyright notice is necessary to ensure compliance with the Apache Software Foundation's requirements for project documentation. ### Does this PR introduce _any_ user-facing change? No API changes, but users will now see the Apache Spark Foundation copyright notice at the bottom of each page of the PySpark documentation as below: ## Before Screenshot 2023-11-27 at 11 49 38 AM ## After Screenshot 2023-11-27 at 11 35 35 AM ### How was this patch tested? Manually build the docs and confirm. ### Was this patch authored or co-authored using generative AI tooling? No. Closes #44026 from itholic/add_copyright. Authored-by: Haejoon Lee Signed-off-by: Hyukjin Kwon --- python/docs/source/_templates/spark_footer.html | 3 +++ python/docs/source/conf.py | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 python/docs/source/_templates/spark_footer.html diff --git a/python/docs/source/_templates/spark_footer.html b/python/docs/source/_templates/spark_footer.html new file mode 100644 index 0000000000000..684482b0c2cdf --- /dev/null +++ b/python/docs/source/_templates/spark_footer.html @@ -0,0 +1,3 @@ + diff --git a/python/docs/source/conf.py b/python/docs/source/conf.py index 81083c007b346..de7ab953c5386 100644 --- a/python/docs/source/conf.py +++ b/python/docs/source/conf.py @@ -12,6 +12,7 @@ # All configuration values have a default; values that are commented out # serve to show the default. +from datetime import datetime import sys import os import shutil @@ -124,7 +125,8 @@ # General information about the project. project = 'PySpark' -copyright = '' +# We have our custom "spark_footer.html" template, using copyright for the current year. +copyright = f"Copyright @ {datetime.now().year}" # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the @@ -194,6 +196,7 @@ # further. For a list of options available for each theme, see the # documentation. html_theme_options = { + "footer_start": ["spark_footer", "sphinx-version"], "navbar_end": ["version-switcher", "theme-switcher"], "logo": { "image_light": "_static/spark-logo-light.png",