Skip to content

Commit

Permalink
added min registration time variable
Browse files Browse the repository at this point in the history
  • Loading branch information
Alejandro-Morales committed Apr 6, 2023
1 parent 4bdeba7 commit 828c52f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/uagents/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
CONTRACT_SERVICE,
REGISTRATION_FEE,
REGISTRATION_DENOM,
MIN_REGISTRATION_TIME,
LEDGER_PREFIX,
parse_endpoint_config,
parse_mailbox_config,
Expand Down Expand Up @@ -373,7 +374,7 @@ def start_background_tasks(self):
if self._endpoints is not None:
if (
not self._almanac_contract.is_registered(self.address)
or self._schedule_registration() < 3600
or self._schedule_registration() < MIN_REGISTRATION_TIME
):
self._loop.create_task(
_run_interval(
Expand Down
1 change: 1 addition & 0 deletions src/uagents/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ class AgentNetwork(Enum):
CONTRACT_SERVICE = "fetch1yrf4xpglq02fzj50m9wn44qdq89a5vr0ufa42qa506uhwal4n79s99sp87"
REGISTRATION_FEE = 500000000000000000
REGISTRATION_DENOM = "atestfet"
MIN_REGISTRATION_TIME = 3600
BLOCK_INTERVAL = 5
AGENT_NETWORK = AgentNetwork.FETCHAI_TESTNET

Expand Down

0 comments on commit 828c52f

Please sign in to comment.