From 6689a20b9292426e20fac8c5f4ce12d8308f9dfa Mon Sep 17 00:00:00 2001 From: crosschainer Date: Wed, 2 Oct 2024 17:46:00 +0000 Subject: [PATCH] remove rand --- src/contracting/execution/tracer.py | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/contracting/execution/tracer.py b/src/contracting/execution/tracer.py index 499981f2..9b957293 100644 --- a/src/contracting/execution/tracer.py +++ b/src/contracting/execution/tracer.py @@ -27,9 +27,6 @@ # Define maximum stamps MAX_STAMPS = 6500000 -CRYPTO_MODULE_NAME = "contracting.stdlib.bridge.crypto" -RANDOMX_FUNCTION_NAME = "randomx_hash" - class Tracer: def __init__(self): self.cost = 0 @@ -101,10 +98,6 @@ def trace_func(self, frame, event, arg): globals_dict = frame.f_globals module_name = globals_dict.get('__name__', '') - if (current_function_name == RANDOMX_FUNCTION_NAME and - module_name == CRYPTO_MODULE_NAME): - self.cost += 100000 # Increment the cost by a specific value - # Only trace code within contracts (if '__contract__' in globals) if '__contract__' not in globals_dict: return