Coverage details
\n\n\n")
- f.write("```\n")
-
- f.writelines(coverage_content)
-
- # Close collapsible section
- f.write("```\n\n")
- f.write("
\n \n\n")
-
-
-def diff_coverage(args):
- """diff-coverage entry point."""
- diff_cover_file_path = Path(args.diff_cover_output).resolve()
- diff_cover_content = None
-
- with open(diff_cover_file_path, "r", encoding="utf-8") as f:
- diff_cover_content = f.readlines()
-
- write_coverage_file(diff_cover_file_path, args.diff_cover_exit_code, diff_cover_content)
-
-
-def global_coverage(args):
- """global-coverage entry point."""
- global_coverage_json_path = Path(args.global_coverage_json_file).resolve()
- global_coverage_infos = None
- with open(global_coverage_json_path, "r", encoding="utf-8") as f:
- global_coverage_infos = json.load(f)
-
- exit_code = global_coverage_infos["exit_code"]
- coverage_content = global_coverage_infos["content"]
- global_coverage_output_file_path = Path(args.global_coverage_output_file).resolve()
- write_coverage_file(global_coverage_output_file_path, exit_code, coverage_content)
-
-
-def main(args):
- """Entry point"""
- args.entry_point(args)
-
-
-if __name__ == "__main__":
- main_parser = argparse.ArgumentParser(allow_abbrev=False)
-
- sub_parsers = main_parser.add_subparsers(dest="sub-command", required=True)
-
- parser_diff_coverage = sub_parsers.add_parser("diff-coverage")
-
- parser_diff_coverage.add_argument("--diff-cover-exit-code", type=int, required=True)
- parser_diff_coverage.add_argument("--diff-cover-output", type=str, required=True)
- parser_diff_coverage.set_defaults(entry_point=diff_coverage)
-
- parser_global_coverage = sub_parsers.add_parser("global-coverage")
-
- parser_global_coverage.add_argument("--global-coverage-output-file", type=str, required=True)
- parser_global_coverage.add_argument("--global-coverage-json-file", type=str, required=True)
- parser_global_coverage.set_defaults(entry_point=global_coverage)
-
- cli_args = main_parser.parse_args()
-
- main(cli_args)
diff --git a/frontends/concrete-python/script/actions_utils/generate_test_matrix.py b/frontends/concrete-python/script/actions_utils/generate_test_matrix.py
deleted file mode 100644
index 61bc26184..000000000
--- a/frontends/concrete-python/script/actions_utils/generate_test_matrix.py
+++ /dev/null
@@ -1,95 +0,0 @@
-"""Script to generate custom GitHub actions test matrices."""
-
-import argparse
-import itertools
-import json
-from pathlib import Path
-
-WEEKLY = "weekly"
-RELEASE = "release"
-PR = "pr"
-PUSH_TO_MAIN = "push_to_main"
-
-LINUX = "linux"
-MACOS = "macos"
-
-OSES = {LINUX, MACOS}
-
-PR_OSES = {LINUX: "ubuntu-22.04"}
-PR_PYTHON_VERSIONS = ["3.7"]
-PR_CONF = {"os": PR_OSES, "python": PR_PYTHON_VERSIONS}
-
-PUSH_TO_MAIN_OSES = {LINUX: "ubuntu-22.04"}
-PUSH_TO_MAIN_PYTHON_VERSIONS = ["3.7"]
-PUSH_TO_MAIN_CONF = {"os": PUSH_TO_MAIN_OSES, "python": PUSH_TO_MAIN_PYTHON_VERSIONS}
-
-WEEKLY_OSES = {
- LINUX: "ubuntu-22.04",
- MACOS: "macos-11",
-}
-WEEKLY_PYTHON_VERSIONS = ["3.7", "3.8", "3.9", "3.10"]
-WEEKLY_CONF = {"os": WEEKLY_OSES, "python": WEEKLY_PYTHON_VERSIONS}
-
-# The OSes here are to indicate the OSes used for runners during release
-RELEASE_OSES = {
- LINUX: "ubuntu-22.04",
- # TODO: https://github.com/zama-ai/concrete-numpy-internal/issues/1340
- # Re-enable macOS for release once we have the duration of the tests
- # MACOS: "macos-10.15",
-}
-# The python versions will be used to build packages during release
-RELEASE_PYTHON_VERSIONS = ["3.7", "3.8", "3.9", "3.10"]
-RELEASE_CONF = {"os": RELEASE_OSES, "python": RELEASE_PYTHON_VERSIONS}
-
-CONFIGURATIONS = {
- PR: PR_CONF,
- WEEKLY: WEEKLY_CONF,
- RELEASE: RELEASE_CONF,
- PUSH_TO_MAIN: PUSH_TO_MAIN_CONF,
-}
-
-
-def main(args):
- """Entry point."""
-
- matrix_conf = CONFIGURATIONS[args.build_type]
-
- github_action_matrix = []
-
- for (os_kind, os_name), python_version in itertools.product(
- matrix_conf["os"].items(), matrix_conf["python"]
- ):
- github_action_matrix.append(
- {
- "os_kind": os_kind,
- "runs_on": os_name,
- "python_version": python_version,
- }
- )
-
- print(json.dumps(github_action_matrix, indent=4))
-
- output_json_path = Path(args.output_json).resolve()
-
- with open(output_json_path, "w", encoding="utf-8") as f:
- json.dump(github_action_matrix, f)
-
-
-if __name__ == "__main__":
- parser = argparse.ArgumentParser("Generate GHA test matrices", allow_abbrev=False)
-
- parser.add_argument(
- "--build-type",
- type=str,
- required=True,
- choices=[WEEKLY, RELEASE, PR, PUSH_TO_MAIN],
- help="The type of build for which the matrix generation is required",
- )
-
- parser.add_argument(
- "--output-json", type=str, required=True, help="Where to output the matrix as json data"
- )
-
- cli_args = parser.parse_args()
-
- main(cli_args)
diff --git a/frontends/concrete-python/script/actions_utils/generate_versions_html.py b/frontends/concrete-python/script/actions_utils/generate_versions_html.py
deleted file mode 100644
index fa50c3433..000000000
--- a/frontends/concrete-python/script/actions_utils/generate_versions_html.py
+++ /dev/null
@@ -1,163 +0,0 @@
-"""Tool to manage the versions.html file at the root of our docs sites."""
-
-import argparse
-from pathlib import Path
-
-from bs4 import BeautifulSoup
-from bs4.element import Tag
-from semver import VersionInfo
-
-VERSIONS_LIST_ID = "versions-list"
-
-
-def strip_leading_v(version_str: str):
- """Strip leading v of a version which is not SemVer compatible."""
- return version_str[1:] if version_str.startswith("v") else version_str
-
-
-def create_list_element(soup: BeautifulSoup, contents: Tag) -> Tag:
- """Create a list element for links.
-
- Args:
- soup (BeautifulSoup): The soup to use to create the tag.
-
- Returns:
- Tag: tag containing