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

add respondToTask() to IIncredibleSquaringTaskManager #104

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
34 changes: 29 additions & 5 deletions contracts/src/IIncredibleSquaringTaskManager.sol
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,38 @@
pragma solidity ^0.8.9;

import "@eigenlayer-middleware/src/libraries/BN254.sol";
import "@eigenlayer-middleware/src/interfaces/IBLSSignatureChecker.sol";

interface IIncredibleSquaringTaskManager {
// EVENTS
event NewTaskCreated(uint32 indexed taskIndex, Task task);

event TaskResponded(TaskResponse taskResponse, TaskResponseMetadata taskResponseMetadata);
event TaskResponded(
TaskResponse taskResponse,
TaskResponseMetadata taskResponseMetadata
);

event TaskCompleted(uint32 indexed taskIndex);

event TaskChallengedSuccessfully(uint32 indexed taskIndex, address indexed challenger);
event TaskChallengedSuccessfully(
uint32 indexed taskIndex,
address indexed challenger
);

event TaskChallengedUnsuccessfully(uint32 indexed taskIndex, address indexed challenger);
event TaskChallengedUnsuccessfully(
uint32 indexed taskIndex,
address indexed challenger
);

event AggregatorUpdated(address indexed oldAggregator, address indexed newAggregator);
event AggregatorUpdated(
address indexed oldAggregator,
address indexed newAggregator
);

event GeneratorUpdated(address indexed oldGenerator, address indexed newGenerator);
event GeneratorUpdated(
address indexed oldGenerator,
address indexed newGenerator
);

// STRUCTS
struct Task {
Expand Down Expand Up @@ -58,6 +74,14 @@ interface IIncredibleSquaringTaskManager {
bytes calldata quorumNumbers
) external;

// NOTE: this function responds to a created task.
function respondToTask(
Task calldata task,
TaskResponse calldata taskResponse,
IBLSSignatureChecker.NonSignerStakesAndSignature
memory nonSignerStakesAndSignature
) external;

/// @notice Returns the current 'taskNumber' for the middleware
function taskNumber() external view returns (uint32);

Expand Down