🐳 Ocean Protocol L1 - v4
Project description
contracts-v4
🦑 Smart contracts for Ocean Protocol v4. https://oceanprotocol.com
ocean v4 is part of the Ocean Protocol toolset.
This is in alpha state and you can expect running into problems. If you run into them, please open up a new issue.
📚 Prerequisites
- node.js (Install from here)
🏄 Quickstart
Features
-
NFT-ize base IP: a new way of representing baseIP, all newly ERC20 DTs are linked to the NFT contract
-
Roles Administration: there are now multiple roles for a more flexible administation both at NFT and ERC20 levels.
-
Safer Staking - Better IDOs: An automated DT staking and vesting contract which helps with initial DT distribution and price stability.
It also provides a customizable vesting schedule for the publisher.
-
Help Ocean community: if Ocean is not the basetoken, Ocean Community will receive 0.1% swap fee on pools or fixed price exchange
-
Flexible key-value store in the NFT contract : NFT contract can be used to store custom key-value pairs
-
Metadata is also stored in the NFT contract store (even if it still supports Metadata.sol)
-
Marketplace fees flexibility: now any marketplace runner can set more customized fees structure.
-
Multiple NFT template support: the Factory can deploy different types of NFT templates.
-
Multiple ERC20 template support: the Factory can deploy different types of ERC20 templates
Publisher Flow
Interaction flow from Publisher point of view.
Roles Diagram
This is a diagram which shows how roles are handled in the v4.
Functions you will need
Selection of most common functions.
🦑 Development
npm install
npx hardhat node
👩🔬 Testing
You can execute all tests with:
# run hardhat node each time you want to test with the current settings
npx hardhat node
npm run test:full
# same thing, but with coverage reporting
npm run test:full:cover
Unit Tests
You can execute unit tests with:
# run hardhat node each time you want to test with the current settings
npx hardhat node
npm run test:unit
Flow Tests
You can execute flow tests with:
# run hardhat node each time you want to test with the current settings
npx hardhat node
npm run test:flow
🏛 License
Copyright ((C)) 2021 Ocean Protocol Foundation
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for ocean_contracts-1.0.0a16-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 44ccf53ed352f773580dd10c4abeeeca38d0bd4d6e454e948807bdaa0dbdac80 |
|
MD5 | 6b5faa0e2d66dd98b3c2e060fc43bef8 |
|
BLAKE2b-256 | 206749298ba727ac8681b77b72fa2932961fee6caa13ee89e6583dc4bd59855b |