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

Diamonds (EIP 2335) don't work perfectly in general case. #29

Closed
afalaleev opened this issue May 10, 2022 · 1 comment
Closed

Diamonds (EIP 2335) don't work perfectly in general case. #29

afalaleev opened this issue May 10, 2022 · 1 comment
Assignees
Labels
bug Something isn't working Medium

Comments

@afalaleev
Copy link

afalaleev commented May 10, 2022

Bug Description
The description of EIP-2535 - https://eips.ethereum.org/EIPS/eip-2535
There are 4 implementations of the standard:

Tests from these repositories are failed with the error:

ProviderError: Program log: Instruction: Begin or Continue Transaction from Account. Program failed to complete: Instruction passed to inner instruction is too large (2333 > 1280

Steps to Reproduce

  1. Clone repository https://github.com/afalaleev/neon-localstand
  2. Run the local neonstand: cd neon-localstand && sudo docker-compose -f docker-compose-local.yml pull && sudo docker-compose -f docker-compose-local.yml up -d
  3. Create test accounts: ./create_new_accounts.sh
  4. Clone repository https://github.com/mudgen/diamond-1-hardhat/
  5. cd diamond-1-hardhat
  6. Add the configuration for the local neon stand to hardhat.config.js
  networks: {
    neonLocal: {
      url: 'http://127.0.0.1:9090/solana',
      timeout: 10000000,
    }
  },
  mocha: {
    timeout: 1000000000
  }
  1. Increase gas limits in test/ from 800'000 to 80'000'000
  2. Run npm install
  3. Run npx hardhat --network neonLocal test
    ...

Actual Behavior
The last test is failed with the error:

1) DiamondTest
       add most functions and facets:
     ProviderError: Program log: Instruction: Begin or Continue Transaction from Account. Program failed to complete: Instruction passed to inner instruction is too large (2333 > 1280)
      at HttpProvider.request (node_modules/hardhat/src/internal/core/providers/http.ts:49:19)
      at GanacheGasMultiplierProvider.request (node_modules/hardhat/src/internal/core/providers/gas-providers.ts:181:34)
      at runMicrotasks (<anonymous>)
      at processTicksAndRejections (internal/process/task_queues.js:95:5)

Expected Behavior
Test are passed without errors.

Additional Context
The root cause of the issue is in a big-size event.
The work-around can be found there:
https://github.com/afalaleev/diamond-1-hardhat
The changes which help to resolve the issue are in these lines :
afalaleev/diamond-1-hardhat@240b2d3#diff-4a56463ac7d10bcf3b1b9064b573011568ea2e9dde2a3f1fe90c8fc3f1bf296eR74-R76

@gigimon
Copy link
Collaborator

gigimon commented Sep 18, 2023

fixed

@gigimon gigimon closed this as completed Sep 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Medium
Projects
None yet
Development

No branches or pull requests

3 participants