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

fix: agToken update #205

Merged
merged 35 commits into from
Jan 23, 2024
Merged

fix: agToken update #205

merged 35 commits into from
Jan 23, 2024

Conversation

sogipec
Copy link
Contributor

@sogipec sogipec commented Mar 21, 2023

No description provided.

@sogipec sogipec changed the title Ag token update fix: agToken update Mar 21, 2023
@GuillaumeNervoXS
Copy link
Contributor

I only see format update on this PR

}

/// @inheritdoc IAgToken
function setTreasury(address _treasury) external onlyTreasury {

Check notice

Code scanning / Slither

Missing zero address validation Low

/// @notice Reference to the treasury contract which can grant minting rights
address public treasury;
/// @notice Boolean used to check whether the contract had been reinitialized after an upgrade
bool public treasuryInitialized;

Check warning

Code scanning / Slither

State variables that could be declared constant Warning

AgEUR.treasuryInitialized should be constant
// ================================= REFERENCES ================================

/// @notice Reference to the `StableMaster` contract associated to agEUR
address public stableMaster;

Check warning

Code scanning / Slither

State variables that could be declared constant Warning

AgEUR.stableMaster should be constant
isMinter[minter] = false;
emit MinterToggled(minter);
}

/// @inheritdoc IAgToken
function setTreasury(address _treasury) external onlyTreasury {
function setTreasury(address _treasury) external virtual onlyTreasury {

Check notice

Code scanning / Slither

Missing zero address validation Low

Copy link
Contributor

@GuillaumeNervoXS GuillaumeNervoXS left a comment

Choose a reason for hiding this comment

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

For the tests it worth a codecov run to check that we are still at 100%


export const immutableCreate2Factory = '0x0000000000FFe8B47B3e2130213B802212439497';

export const OFTs: OFTsStructure = {
Copy link
Contributor

Choose a reason for hiding this comment

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

We can do a call to our sdk for that

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We can, only reason why I'm fine not doing it now is because when you deploy it's often a pain to have to wait for the SDK update to get all the addresses here

Copy link
Contributor

Choose a reason for hiding this comment

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

I am not sure I understand your point?

deploy/newChain/2_agTokenImplementation.ts Show resolved Hide resolved
deploy/newStable/0_coreBorrow.ts Show resolved Hide resolved
scripts/foundry/utils/Constants.s.sol Outdated Show resolved Hide resolved
scripts/foundry/utils/Utils.s.sol Outdated Show resolved Hide resolved
Copy link
Contributor

@GuillaumeNervoXS GuillaumeNervoXS left a comment

Choose a reason for hiding this comment

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

Also for the vanity logic, as we will surely have it on multiple repos, best is to have a specific repo implementing this logic (with parameters) that will be imported where needed


export const immutableCreate2Factory = '0x0000000000FFe8B47B3e2130213B802212439497';

export const OFTs: OFTsStructure = {
Copy link
Contributor

Choose a reason for hiding this comment

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

I am not sure I understand your point?

Comment on lines +16 to +18
function _getQuoteAmount() internal view virtual returns (uint256) {
return 10 ** 18;
}

Check warning

Code scanning / Slither

Dead-code Warning

BaseOracleChainlinkOneFeed._getQuoteAmount() is never used and should be removed
@sogipec sogipec enabled auto-merge (squash) January 19, 2024 16:09
import { parseAmount } from '../../utils/bignumber';

const flashLoanParams = {
// 3m at the moment, should not be too big with respect to the total agEUR in circulation
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe lower with stUSD as we don't know the growth yet

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Adjusted


export const interestRate5 = BigNumber.from('1547125982881425408');

export const vaultManagers = {
Copy link
Contributor

Choose a reason for hiding this comment

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

Why is it in this repo and not the sdk one?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Because we removed the parameters from the sdk

@sogipec sogipec merged commit 0a857de into main Jan 23, 2024
6 checks passed
@sogipec sogipec deleted the agToken-update branch January 24, 2024 10:41
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.

3 participants