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

[SMRT] Fix warnings in VRFCoordinatorV2Mock (and all solidity warnings) #8971

Open
PatrickAlphaC opened this issue Apr 14, 2023 · 0 comments
Labels
investigating Needs someone to take a deeper look. Has been viewed and someone will figure out the procedure.

Comments

@PatrickAlphaC
Copy link
Contributor

Description
Fix warnings in VRFCoordinatorV2Mock.

Warnings are critical for developers to pay attention to, so cluttering up the solidity compiler output creates headaches for devs. Please fix these warnings. (Most of them are "unused parameter", so either use the parameter or comment them out)

(Note, chainlink-brownie-contracts is a minimal package that includes just the contracts of @chainlink/contracts, so it's quicker and smaller to download)

warning[5667]: Warning: Unused function parameter. Remove or comment out the variable name to silence this warning.
   --> lib/chainlink-brownie-contracts/contracts/src/v0.8/mocks/VRFCoordinatorV2Mock.sol:306:45:
    |
306 |   function requestSubscriptionOwnerTransfer(uint64 _subId, address _newOwner) external pure override {
    |                                             ^^^^^^^^^^^^^



warning[5667]: Warning: Unused function parameter. Remove or comment out the variable name to silence this warning.
   --> lib/chainlink-brownie-contracts/contracts/src/v0.8/mocks/VRFCoordinatorV2Mock.sol:306:60:
    |
306 |   function requestSubscriptionOwnerTransfer(uint64 _subId, address _newOwner) external pure override {
    |                                                            ^^^^^^^^^^^^^^^^^



warning[5667]: Warning: Unused function parameter. Remove or comment out the variable name to silence this warning.
   --> lib/chainlink-brownie-contracts/contracts/src/v0.8/mocks/VRFCoordinatorV2Mock.sol:310:44:
    |
310 |   function acceptSubscriptionOwnerTransfer(uint64 _subId) external pure override {
    |                                            ^^^^^^^^^^^^^



warning[5667]: Warning: Unused function parameter. Remove or comment out the variable name to silence this warning.
   --> lib/chainlink-brownie-contracts/contracts/src/v0.8/mocks/VRFCoordinatorV2Mock.sol:314:33:
    |
314 |   function pendingRequestExists(uint64 subId) public view override returns (bool) {
    |                                 ^^^^^^^^^^^^



warning[2018]: Warning: Function state mutability can be restricted to pure
   --> lib/chainlink-brownie-contracts/contracts/src/v0.8/mocks/VRFCoordinatorV2Mock.sol:261:3:
    |
261 |   function getConfig()
    |   ^ (Relevant source part starts here and spans across multiple lines).



warning[2018]: Warning: Function state mutability can be restricted to pure
   --> lib/chainlink-brownie-contracts/contracts/src/v0.8/mocks/VRFCoordinatorV2Mock.sol:274:3:
    |
274 |   function getFeeConfig()
    |   ^ (Relevant source part starts here and spans across multiple lines).



warning[2018]: Warning: Function state mutability can be restricted to pure
   --> lib/chainlink-brownie-contracts/contracts/src/v0.8/mocks/VRFCoordinatorV2Mock.sol:302:3:
    |
302 |   function getFallbackWeiPerUnitLink() external view returns (int256) {
    |   ^ (Relevant source part starts here and spans across multiple lines).



warning[2018]: Warning: Function state mutability can be restricted to pure
   --> lib/chainlink-brownie-contracts/contracts/src/v0.8/mocks/VRFCoordinatorV2Mock.sol:314:3:
    |
314 |   function pendingRequestExists(uint64 subId) public view override returns (bool) {
    |   ^ (Relevant source part starts here and spans across multiple lines).
@zeuslawyer zeuslawyer added the investigating Needs someone to take a deeper look. Has been viewed and someone will figure out the procedure. label Apr 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
investigating Needs someone to take a deeper look. Has been viewed and someone will figure out the procedure.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants