Skip to content

Commit

Permalink
chore(core): release v0.15.0 (#488)
Browse files Browse the repository at this point in the history
  • Loading branch information
jrriehl authored Aug 7, 2024
1 parent 728b8ba commit f82a50a
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def in_service_region(

@cleaning_proto.on_message(model=ServiceRequest, replies=ServiceResponse)
async def handle_query_request(ctx: Context, sender: str, msg: ServiceRequest):
provider = await Provider.filter(name=ctx.name).first()
provider = await Provider.filter(name=ctx.agent.name).first()
availability = await Availability.get(provider=provider)
services = [int(service.type) for service in await provider.services]
markup = provider.markup
Expand Down Expand Up @@ -94,7 +94,7 @@ async def handle_query_request(ctx: Context, sender: str, msg: ServiceRequest):

@cleaning_proto.on_message(model=ServiceBooking, replies=BookingResponse)
async def handle_book_request(ctx: Context, sender: str, msg: ServiceBooking):
provider = await Provider.filter(name=ctx.name).first()
provider = await Provider.filter(name=ctx.agent.name).first()
availability = await Availability.get(provider=provider)
services = [int(service.type) for service in await provider.services]

Expand Down
6 changes: 4 additions & 2 deletions python/examples/13-agent-name-service/agent1.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from cosmpy.aerial.wallet import LocalWallet
from uagents import Agent, Context, Model
from uagents.network import get_faucet, get_name_service_contract
from uagents.network import get_faucet, get_name_service_contract, logger

# NOTE: Run agent1.py before running agent2.py

Expand All @@ -22,10 +22,12 @@ class Message(Model):
faucet = get_faucet()
DOMAIN = "example.agent"

logger.info(f"Adding testnet funds to {my_wallet.address()}...")
faucet.get_wealth(my_wallet.address())
logger.info(f"Adding testnet funds to {my_wallet.address()}...complete")


@bob.on_event("startup")
@bob.on_interval(10)
async def register_agent_name(ctx: Context):
await name_service_contract.register(
bob.ledger, my_wallet, bob.address, bob.name, DOMAIN
Expand Down
2 changes: 1 addition & 1 deletion python/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "uagents"
version = "0.14.0"
version = "0.15.0"
description = "Lightweight framework for rapid agent-based development"
authors = [
"Ed FitzGerald <[email protected]>",
Expand Down

0 comments on commit f82a50a

Please sign in to comment.