Skip to content

Fix #513: add local interfaces#534

Open
riccardopersiani wants to merge 2 commits intomasterfrom
fix/issue-513-local-interfaces
Open

Fix #513: add local interfaces#534
riccardopersiani wants to merge 2 commits intomasterfrom
fix/issue-513-local-interfaces

Conversation

@riccardopersiani
Copy link
Member

@riccardopersiani riccardopersiani commented Mar 17, 2026

Description

Closes Issue #513

Updated interfaces locally with:

  • UsdsJoin: cast interface 0x3C0f895007CA717Aa01c8693e59DF1e8C3777FEB.

Please note that:

interface UsdsJoinLike is DaiJoinAbstract {}

was incorrect. As:

interface DaiJoinAbstract {
    function wards(address) external view returns (uint256);
    function rely(address usr) external;
    function deny(address usr) external;
    function vat() external view returns (address);
    function dai() external view returns (address);
    function live() external view returns (uint256);
    function cage() external;
    function join(address, uint256) external;
    function exit(address, uint256) external;
}

is different from:

interface UsdsJoinLike {
    function dai() external view returns (address);
    function exit(address usr, uint256 wad) external;
    function join(address usr, uint256 wad) external;
    function usds() external view returns (address);
    function vat() external view returns (address);
}

@coderabbitai
Copy link

coderabbitai bot commented Mar 17, 2026

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 2c7a0fe1-a2dd-48c8-9f28-227bdae91036

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/issue-513-local-interfaces
📝 Coding Plan
  • Generate coding plan for human review comments

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Tip

CodeRabbit can approve the review once all CodeRabbit's comments are resolved.

Enable the reviews.request_changes_workflow setting to automatically approve the review once all CodeRabbit's comments are resolved.

Comment on lines +168 to +171
function deny(address usr) external;
function exec(uint256 lot) external;
function file(bytes32 what, uint256 data) external;
function file(bytes32 what, address data) external;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We usually declare only the methods that are actually used from inline interfaces.
The argument against that is that manually editing interfaces is error-prone.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Many interfaces actually declare more inline methods than they are actually used.

Maybe it is worth deciding how to approach this once for all.

@riccardopersiani riccardopersiani force-pushed the fix/issue-513-local-interfaces branch from 01a289e to b6f7586 Compare March 18, 2026 10:16
Copy link
Contributor

@amusingaxl amusingaxl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While this interface is not directly used in any of the files, so do many others declared here.
It's better to have the most commonly used ones that can be eventually used in a test than extending a mostly incompatible interface such as DaiJoinAbstract.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants