certora-cli-alpha-master 20250913.0.7.15157__tar.gz → 20250914.16.54.139374__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {certora_cli_alpha_master-20250913.0.7.15157/certora_cli_alpha_master.egg-info → certora_cli_alpha_master-20250914.16.54.139374}/PKG-INFO +2 -2
- certora_cli_alpha_master-20250914.16.54.139374/README.md +1 -0
- certora_cli_alpha_master-20250914.16.54.139374/certora_cli/CertoraProver/certoraBuildSui.py +112 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374/certora_cli_alpha_master.egg-info}/PKG-INFO +2 -2
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_jars/ASTExtraction.jar +0 -0
- certora_cli_alpha_master-20250914.16.54.139374/certora_jars/CERTORA-CLI-VERSION-METADATA.json +1 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_jars/Typechecker.jar +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/setup.py +2 -2
- certora_cli_alpha_master-20250913.0.7.15157/README.md +0 -1
- certora_cli_alpha_master-20250913.0.7.15157/certora_cli/CertoraProver/certoraBuildSui.py +0 -68
- certora_cli_alpha_master-20250913.0.7.15157/certora_jars/CERTORA-CLI-VERSION-METADATA.json +0 -1
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/LICENSE +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/MANIFEST.in +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_bins/__init__.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/Compiler/CompilerCollector.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/Compiler/CompilerCollectorFactory.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/Compiler/CompilerCollectorSol.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/Compiler/CompilerCollectorSolBased.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/Compiler/CompilerCollectorVy.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/Compiler/CompilerCollectorYul.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/Compiler/__init__.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/__init__.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraApp.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraBuild.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraBuildCacheManager.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraBuildDataClasses.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraBuildRust.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraCloudIO.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraCollectConfigurationLayout.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraCollectRunMetadata.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraCompilerParameters.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraConfigIO.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraContext.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraContextAttributes.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraContextClass.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraContextValidator.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraContractFuncs.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraExtensionInfo.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraJobList.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraMiniSpecParser.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraNodeFilters.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraParseBuildScript.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraProjectScanner.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraSourceFinders.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraType.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/certoraVerifyGenerator.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/erc7201.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/splitRules.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/CertoraProver/storageExtension.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/EquivalenceCheck/Eq_default.conf +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/EquivalenceCheck/Eq_mc_no_out_template.spec +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/EquivalenceCheck/Eq_mc_template.spec +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/EquivalenceCheck/Eq_sanity.conf +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/EquivalenceCheck/Eq_template.spec +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/EquivalenceCheck/__init__.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/EquivalenceCheck/equivCheck.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/EquivalenceCheck/sanity.spec +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Mutate/__init__.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Mutate/mutateApp.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Mutate/mutateAttributes.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Mutate/mutateConstants.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Mutate/mutateUtil.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Mutate/mutateValidate.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Shared/ExpectedComparator.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Shared/__init__.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Shared/certoraAttrUtil.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Shared/certoraLogging.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Shared/certoraUtils.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Shared/certoraValidateFuncs.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/Shared/proverCommon.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/__init__.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/certoraCVLFormatter.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/certoraConcord.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/certoraEVMProver.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/certoraEqCheck.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/certoraMutate.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/certoraRanger.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/certoraRun.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/certoraSolanaProver.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/certoraSorobanProver.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli/rustMutator.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli_alpha_master.egg-info/SOURCES.txt +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli_alpha_master.egg-info/dependency_links.txt +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli_alpha_master.egg-info/entry_points.txt +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli_alpha_master.egg-info/requires.txt +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_cli_alpha_master.egg-info/top_level.txt +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/certora_jars/__init__.py +0 -0
- {certora_cli_alpha_master-20250913.0.7.15157 → certora_cli_alpha_master-20250914.16.54.139374}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.2
|
2
2
|
Name: certora-cli-alpha-master
|
3
|
-
Version:
|
3
|
+
Version: 20250914.16.54.139374
|
4
4
|
Summary: Runner for the Certora Prover
|
5
5
|
Home-page: https://pypi.org/project/certora-cli-alpha-master
|
6
6
|
Author: Certora
|
@@ -39,4 +39,4 @@ Dynamic: requires-dist
|
|
39
39
|
Dynamic: requires-python
|
40
40
|
Dynamic: summary
|
41
41
|
|
42
|
-
Commit
|
42
|
+
Commit b6ca649. Build and Run scripts for executing the Certora Prover on Solidity smart contracts.
|
@@ -0,0 +1 @@
|
|
1
|
+
Commit b6ca649. Build and Run scripts for executing the Certora Prover on Solidity smart contracts.
|
@@ -0,0 +1,112 @@
|
|
1
|
+
# The Certora Prover
|
2
|
+
# Copyright (C) 2025 Certora Ltd.
|
3
|
+
#
|
4
|
+
# This program is free software: you can redistribute it and/or modify
|
5
|
+
# it under the terms of the GNU General Public License as published by
|
6
|
+
# the Free Software Foundation, version 3 of the License.
|
7
|
+
#
|
8
|
+
# This program is distributed in the hope that it will be useful,
|
9
|
+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
10
|
+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
11
|
+
# GNU General Public License for more details.
|
12
|
+
#
|
13
|
+
# You should have received a copy of the GNU General Public License
|
14
|
+
# along with this program. If not, see <https://www.gnu.org/licenses/>.
|
15
|
+
|
16
|
+
from __future__ import annotations
|
17
|
+
|
18
|
+
import subprocess
|
19
|
+
import sys
|
20
|
+
from pathlib import Path
|
21
|
+
|
22
|
+
scripts_dir_path = Path(__file__).parent.parent.resolve() # containing directory
|
23
|
+
sys.path.insert(0, str(scripts_dir_path))
|
24
|
+
|
25
|
+
import shutil
|
26
|
+
import time
|
27
|
+
import logging
|
28
|
+
from pathlib import Path
|
29
|
+
from typing import Set, Dict
|
30
|
+
|
31
|
+
from CertoraProver.certoraBuild import build_source_tree
|
32
|
+
from CertoraProver.certoraContextClass import CertoraContext
|
33
|
+
from Shared import certoraUtils as Util
|
34
|
+
|
35
|
+
|
36
|
+
log = logging.getLogger(__name__)
|
37
|
+
|
38
|
+
|
39
|
+
def build_sui_project(context: CertoraContext, timings: Dict) -> None:
|
40
|
+
"""
|
41
|
+
Compile the Sui artefact and record elapsed time in *timings*.
|
42
|
+
|
43
|
+
Args:
|
44
|
+
context: The CertoraContext object containing the configuration.
|
45
|
+
timings: A dictionary to store timing information.
|
46
|
+
"""
|
47
|
+
log.debug("Build Sui target")
|
48
|
+
start = time.perf_counter()
|
49
|
+
set_sui_build_directory(context)
|
50
|
+
timings["buildTime"] = round(time.perf_counter() - start, 4)
|
51
|
+
if context.test == str(Util.TestValue.AFTER_BUILD):
|
52
|
+
raise Util.TestResultsReady(context)
|
53
|
+
|
54
|
+
|
55
|
+
def set_sui_build_directory(context: CertoraContext) -> None:
|
56
|
+
sources: Set[Path] = set()
|
57
|
+
|
58
|
+
# If no move_path was specified, try to build the package
|
59
|
+
if not context.move_path:
|
60
|
+
move_toml_file = Util.find_file_in_parents("Move.toml")
|
61
|
+
if not move_toml_file:
|
62
|
+
raise Util.CertoraUserInputError("Could not find Move.toml, and no move_path was specified.")
|
63
|
+
sources.add(move_toml_file.absolute())
|
64
|
+
run_sui_build(context, move_toml_file.parent)
|
65
|
+
|
66
|
+
assert context.move_path, "expecting move_path to be set after build"
|
67
|
+
move_dir = Path(context.move_path)
|
68
|
+
assert move_dir.exists(), f"Output path '{move_dir}' does not exist"
|
69
|
+
assert move_dir.is_dir(), f"Output path '{move_dir}' is not a directory"
|
70
|
+
|
71
|
+
# Add all source files. We get these from the Sui build output, because it includes dependencies as well, and is
|
72
|
+
# available even if we didn't run the build ourselves.
|
73
|
+
sources.update(move_dir.rglob("*.move"))
|
74
|
+
|
75
|
+
# Add conf file if it exists
|
76
|
+
if getattr(context, 'conf_file', None) and Path(context.conf_file).exists():
|
77
|
+
sources.add(Path(context.conf_file).absolute())
|
78
|
+
|
79
|
+
# Copy the binary modules and source maps
|
80
|
+
shutil.copytree(move_dir,
|
81
|
+
Util.get_build_dir() / move_dir.name,
|
82
|
+
ignore=shutil.ignore_patterns('*.move'))
|
83
|
+
|
84
|
+
try:
|
85
|
+
# Create generators
|
86
|
+
build_source_tree(sources, context)
|
87
|
+
|
88
|
+
except Exception as e:
|
89
|
+
raise Util.CertoraUserInputError(f"Collecting build files failed with the exception: {e}")
|
90
|
+
|
91
|
+
def run_sui_build(context: CertoraContext, package_dir: Path) -> None:
|
92
|
+
assert not context.move_path, "run_sui_build: expecting move_path to be empty"
|
93
|
+
|
94
|
+
build_cmd = ["sui", "move", "build", "--test", "--path", str(package_dir)]
|
95
|
+
|
96
|
+
try:
|
97
|
+
build_cmd_text = ' '.join(build_cmd)
|
98
|
+
log.info(f"Building by calling `{build_cmd_text}`")
|
99
|
+
result = subprocess.run(build_cmd, capture_output=False)
|
100
|
+
|
101
|
+
# Check if the script executed successfully
|
102
|
+
if result.returncode != 0:
|
103
|
+
raise Util.CertoraUserInputError(f"Error running `{build_cmd_text}`")
|
104
|
+
|
105
|
+
context.move_path = str(package_dir / "build")
|
106
|
+
|
107
|
+
except Util.TestResultsReady as e:
|
108
|
+
raise e
|
109
|
+
except Util.CertoraUserInputError as e:
|
110
|
+
raise e
|
111
|
+
except Exception as e:
|
112
|
+
raise Util.CertoraUserInputError(f"An unexpected error occurred: {e}")
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.2
|
2
2
|
Name: certora-cli-alpha-master
|
3
|
-
Version:
|
3
|
+
Version: 20250914.16.54.139374
|
4
4
|
Summary: Runner for the Certora Prover
|
5
5
|
Home-page: https://pypi.org/project/certora-cli-alpha-master
|
6
6
|
Author: Certora
|
@@ -39,4 +39,4 @@ Dynamic: requires-dist
|
|
39
39
|
Dynamic: requires-python
|
40
40
|
Dynamic: summary
|
41
41
|
|
42
|
-
Commit
|
42
|
+
Commit b6ca649. Build and Run scripts for executing the Certora Prover on Solidity smart contracts.
|
Binary file
|
@@ -0,0 +1 @@
|
|
1
|
+
{"name": "certora-cli-alpha-master", "tag": "", "branch": "master", "commit": "b6ca649", "timestamp": "20250914.16.54.139374", "version": "20250914.16.54.139374+b6ca649"}
|
Binary file
|
@@ -3,11 +3,11 @@ import setuptools
|
|
3
3
|
|
4
4
|
setuptools.setup(
|
5
5
|
name="certora-cli-alpha-master",
|
6
|
-
version="
|
6
|
+
version="20250914.16.54.139374",
|
7
7
|
author="Certora",
|
8
8
|
author_email="support@certora.com",
|
9
9
|
description="Runner for the Certora Prover",
|
10
|
-
long_description="Commit
|
10
|
+
long_description="Commit b6ca649. Build and Run scripts for executing the Certora Prover on Solidity smart contracts.",
|
11
11
|
long_description_content_type="text/markdown",
|
12
12
|
url="https://pypi.org/project/certora-cli-alpha-master",
|
13
13
|
packages=setuptools.find_packages(),
|
@@ -1 +0,0 @@
|
|
1
|
-
Commit e448c2c. Build and Run scripts for executing the Certora Prover on Solidity smart contracts.
|
@@ -1,68 +0,0 @@
|
|
1
|
-
# The Certora Prover
|
2
|
-
# Copyright (C) 2025 Certora Ltd.
|
3
|
-
#
|
4
|
-
# This program is free software: you can redistribute it and/or modify
|
5
|
-
# it under the terms of the GNU General Public License as published by
|
6
|
-
# the Free Software Foundation, version 3 of the License.
|
7
|
-
#
|
8
|
-
# This program is distributed in the hope that it will be useful,
|
9
|
-
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
10
|
-
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
11
|
-
# GNU General Public License for more details.
|
12
|
-
#
|
13
|
-
# You should have received a copy of the GNU General Public License
|
14
|
-
# along with this program. If not, see <https://www.gnu.org/licenses/>.
|
15
|
-
|
16
|
-
from __future__ import annotations
|
17
|
-
|
18
|
-
import sys
|
19
|
-
from pathlib import Path
|
20
|
-
|
21
|
-
scripts_dir_path = Path(__file__).parent.parent.resolve() # containing directory
|
22
|
-
sys.path.insert(0, str(scripts_dir_path))
|
23
|
-
|
24
|
-
import shutil
|
25
|
-
import time
|
26
|
-
import logging
|
27
|
-
from pathlib import Path
|
28
|
-
from typing import Set, Dict
|
29
|
-
|
30
|
-
from CertoraProver.certoraBuild import build_source_tree
|
31
|
-
from CertoraProver.certoraContextClass import CertoraContext
|
32
|
-
from Shared import certoraUtils as Util
|
33
|
-
|
34
|
-
|
35
|
-
log = logging.getLogger(__name__)
|
36
|
-
|
37
|
-
|
38
|
-
def build_sui_project(context: CertoraContext, timings: Dict) -> None:
|
39
|
-
"""
|
40
|
-
Compile the Rust artefact and record elapsed time in *timings*.
|
41
|
-
|
42
|
-
Args:
|
43
|
-
context: The CertoraContext object containing the configuration.
|
44
|
-
timings: A dictionary to store timing information.
|
45
|
-
"""
|
46
|
-
log.debug("Build Rust target")
|
47
|
-
start = time.perf_counter()
|
48
|
-
set_sui_build_directory(context)
|
49
|
-
timings["buildTime"] = round(time.perf_counter() - start, 4)
|
50
|
-
if context.test == str(Util.TestValue.AFTER_BUILD):
|
51
|
-
raise Util.TestResultsReady(context)
|
52
|
-
|
53
|
-
|
54
|
-
def set_sui_build_directory(context: CertoraContext) -> None:
|
55
|
-
assert context.move_path, "build_sui_project: expecting move_path to link to a build directory"
|
56
|
-
|
57
|
-
shutil.copytree(context.move_path, Util.get_build_dir() / Path(context.move_path).name)
|
58
|
-
|
59
|
-
sources: Set[Path] = set()
|
60
|
-
if getattr(context, 'conf_file', None) and Path(context.conf_file).exists():
|
61
|
-
sources.add(Path(context.conf_file).absolute())
|
62
|
-
|
63
|
-
try:
|
64
|
-
# Create generators
|
65
|
-
build_source_tree(sources, context)
|
66
|
-
|
67
|
-
except Exception as e:
|
68
|
-
raise Util.CertoraUserInputError(f"Collecting build files failed with the exception: {e}")
|
@@ -1 +0,0 @@
|
|
1
|
-
{"name": "certora-cli-alpha-master", "tag": "", "branch": "master", "commit": "e448c2c", "timestamp": "20250913.0.7.015157", "version": "20250913.0.7.015157+e448c2c"}
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|