Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: allow renaming the EigenLayer deployment output #214

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 14 additions & 1 deletion kurtosis_package/deployers/eigenlayer.star
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ utils = import_module("./utils.star")


def deploy(plan, context, deployment):
el_args = get_version_args(deployment) | deployment
el_args = add_version_args(deployment)
el_name = el_args["name"]
plan.print("Initiating {} deployment".format(el_name))

Expand Down Expand Up @@ -63,6 +63,19 @@ def generate_addresses_arg(el_output, strategies):
return addresses


def add_version_args(deployment):
output = deployment.get("output")
version_args = get_version_args(deployment)
result = version_args | deployment
# If `output` is a string, we use the default version output config,
# but renaming the file with the specified name
if output != None and type(output) == type(""):
result["output"] = version_args["output"]
result["output"]["eigenlayer_addresses"]["rename"] = output

return result


def get_version_args(deployment):
ref = deployment.get("ref", "dev")
deployment_version = deployment.get("version", ref)
Expand Down
Loading