Questions tagged [openzeppelin]

OpenZeppelin provides tools to write, deploy and operate decentralized applications. It also protects leading organizations by performing security audits on their systems and products.

OpenZeppelin provides tools to write, deploy and operate decentralized applications.

It also protects leading organizations by performing security audits on their systems and products.

237 questions
0
votes
1 answer

How do we get (on Remix) the bytecode of a smart contract that has to make use of libraries?

I am using Remix for compiling a simple ERC20 smart contract, and I would love to make use of libraries such as SafeMath. Do you know how to get the bytecode for a contract like this…
0
votes
2 answers

Solidity library @openzeppelin/contracts/access/Ownable.sol is not resolving ownerOnly()

I am trying to switch my contract to use the 'import "@openzeppelin/contracts/access/Ownable.sol”’, but I am getting the following error contracts/InvoiceTracker.sol:93:9: DeclarationError: Undeclared identifier. ownerOnly() for this code: function…
DenisMP
  • 973
  • 2
  • 16
  • 31
0
votes
1 answer

How to compile older zeppelin-solidity contract implementations

I installed zeppelin-solidity package using npm, to use the erc-721 contract. But the problem is that when I use truffle compile, it gives the following…
srinivas
  • 4,778
  • 2
  • 32
  • 43
0
votes
1 answer

Deploying SampleCrowdsale with openzeppelin - Error: invalid address

I am trying to deploy this SampleCrowdsale example from open-zeppelin SampleCrowdsale It requires the following inputs to deploy: openingTime: closingTime: rate: wallet:
cap: token:
goal: What are the token and wallet addresses…
who-aditya-nawandar
  • 1,334
  • 9
  • 39
  • 89
0
votes
1 answer

Why is my ERC20 token transferring from 0x000000 when Im explicitly giving an address to transfer from?

When calling transferFrom it uses address 0x00000 instead of the address I am passing to it. I have insured the token is minted when constructed and total supply is sent to contract owner's wallet address. Right before calling transferFrom…
0
votes
1 answer

Is this a remix,compiler or an openzeplin bug?

I just wrote a simple code to test openzeplin Safemath library. I am using the latest version of remix ide and compiling for ^0.5.0. Remix is using 0.5.0_commit.1d4f565a compiler The environment is JavaScript VM EVM Version is the compiler…
Zaid Munir
  • 19
  • 3
0
votes
1 answer

No events were emitted - Exchanging ERC721 Tokens

Function to exchange ERC721 Tokens between two addresses. I am implementing this on truffle and openzeppelin 2.10. Two different tokens should be exchanged between two addresses. Here's my contract function for exchanging ERC721 tokens: function…
Sagar Atalatti
  • 486
  • 1
  • 8
  • 21
0
votes
0 answers

Questions on MinterRole contract in openzeppelin

I am using the openzeppelin for creating the ICO contract. I am concerned about the MinterRole here. After I develop Token contract, I added the sale contract as a minter using "addMinter" function. Question After the sale is over I do not see…
iappmaker
  • 2,945
  • 9
  • 35
  • 76
0
votes
1 answer

Why can't I pass these arguments in Remix?

I'm trying to deploy OpenZeppelin PaymentSplitter.sol but I'm getting the following error in Remix: creation of PaymentSplitter errored: Error encoding arguments: Error: expected array value (arg="", coderType="array", type="string",…
Median
  • 1
  • 1
  • 1
0
votes
1 answer

Deploy contract made with OpenZeppelin from Web3.py

I've followed a tutorial centered in the creation of an ICO and a Crowdsale (based on the ICO that I've created). It's a very classic tutorial, I know, but now I'm integrating the 2 contracts made with the help of OpenZeppelin and Truffle framework…
Flamel
  • 23
  • 6
0
votes
0 answers

Transaction reverted

I am a beginner in writing smart contract. I want to deploy a crowdsale and token contract on the Kovan testnet. Everything works well except when I tried to send KTH to the crowdsale contract. I always get "reverted transaction" in the end. Could…
Neo Yang
  • 111
  • 2
  • 7
-1
votes
1 answer

I am trying to check initial and final balance of owner by subtracting amount and using .subs() function in hardhat

I am using openzepplin library and trying to transfer amount from owner to 2 diffrent wallets. All is working fine but I am getting error when I am checking the initial and final balance of owners after transaction. Here is my token.sol code //…
-1
votes
1 answer

Property 'PROPOSER_ROLE' does not exist on type 'BaseContract'

TimeLock contract extends from TimelockController from OpenZeppelin Contracts. contract TimeLock is TimelockController { constructor( uint256 minDelay, address[] memory proposers, address[] memory executors, address admin )…
Sagar Atalatti
  • 486
  • 1
  • 8
  • 21
-1
votes
1 answer

How can I fix IERC20 & IAccessControl interfaces causing 'Undeclared Identifier' error?

I'm trying to use the OpenZeppelin IERC20 & and IAccessControl interfaces instead of importing the normal contracts to prevent maxing out on size. When I was using the normal contracts, everything worked fine, except the size on some of my…
-1
votes
1 answer

Deployment error in solidity while deploying ERC20 contract from OpenZeppelin

I was creating an ERC20 contract using an open zeppelin code. I was trying to declare the initial supply for my tokens and mind the initial supply in a constructor as shown in the image below. Everything was compiled perfectly without any errors.…
1 2 3
15
16