# IERC20 is ^0.8.0 but upgrade safe stuff is ^0.6.0 and they don't mix

**URL:** <https://forum.openzeppelin.com/t/ierc20-is-0-8-0-but-upgrade-safe-stuff-is-0-6-0-and-they-dont-mix/10482>\
**Category:** Support\
**Created:** [June 14, 2021, 2:37am UTC](https://forum.openzeppelin.com/t/ierc20-is-0-8-0-but-upgrade-safe-stuff-is-0-6-0-and-they-dont-mix/10482 "2021-06-14T02:37:11Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![NickKan](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/nickkan/32/6736_2.png) [@NickKan](https://forum.openzeppelin.com/u/NickKan)\
**Post date:** [June 14, 2021, 2:37am UTC](https://forum.openzeppelin.com/t/ierc20-is-0-8-0-but-upgrade-safe-stuff-is-0-6-0-and-they-dont-mix/10482/1 "2021-06-14T02:37:12Z")

</div>

I got compilation error from the source code below. IERC20 is ^0.8.0 but the rests are ^0.6.0. What is my choice here? Should I just copy IERC20 to another file and made it ^0.6.0 with pragma?

Thanks You.

```auto
$npx hardhat compile

Solidity 0.8.0 is not fully supported yet. You can still use Hardhat, but some features, like stack traces, might not work correctly.

Learn more at https://hardhat.org/reference/solidity-support"

Error HH606: The project cannot be compiled, see reasons below.

These files import other files that use a different and incompatible version of Solidity:

  * contracts/Hexo.sol (^0.6.0) imports @openzeppelin/contracts/token/ERC20/IERC20.sol (^0.8.0) and @openzeppelin/contracts/proxy/utils/Initializable.sol (^0.8.0)

```

#### 🔢 Code to reproduce

```auto
pragma solidity ^0.8.0;

import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/proxy/utils/Initializable.sol";
import "@openzeppelin/contracts-ethereum-package/contracts/access/Ownable.sol";

contract Boxo is Initializable, OwnableUpgradeSafe {
    
    address xyz;

    function initialize(address _xyz) public initializer {
        xyz =_xyz
    }
}   

```

#### 💻 Environment

I'm using the latest version hardhat.

---

<div class="post-metadata">

**Author:** ![Yoshiko](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/yoshiko/32/6858_2.png) [@Yoshiko](https://forum.openzeppelin.com/u/Yoshiko)\
**Post date:** [June 14, 2021, 3:53am UTC](https://forum.openzeppelin.com/t/ierc20-is-0-8-0-but-upgrade-safe-stuff-is-0-6-0-and-they-dont-mix/10482/2 "2021-06-14T03:53:17Z")

</div>

Hi Nick, welcome to Open Zeppelin.

You should update your code to match the most recent versions. (0.8.5)

You might get some errors, but you will need to figure them out. If you have issues or questions when updating to new versions please ask and we can help!

---

<div class="post-metadata">

**Author:** ![frangio](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/frangio/32/15251_2.png) [@frangio](https://forum.openzeppelin.com/u/frangio)\
**Post date:** [June 14, 2021, 7:26pm UTC](https://forum.openzeppelin.com/t/ierc20-is-0-8-0-but-upgrade-safe-stuff-is-0-6-0-and-they-dont-mix/10482/3 "2021-06-14T19:26:04Z")

</div>

`@openzeppelin/contracts-ethereum-package` is an older version not available for Solidity 0.8.

Install and use `@openzeppelin/contracts-upgradeable`.

```auto
import "@openzeppelin/contracts-upgradeable/contracts/access/OwnableUpgradeable.sol";

```
