1
0
mirror of https://github.com/oceanprotocol/docs.git synced 2024-11-26 19:49:26 +01:00

npm run format + manually tweak

This commit is contained in:
Troy McConaghy 2019-04-04 11:56:56 +02:00
parent 1494176392
commit b938310816
11 changed files with 147 additions and 146 deletions

View File

@ -28,6 +28,7 @@ Otherwise you are an "external contributor" and you must do the following:
- If the first line of the file is a line beginning with `#!` (e.g. `#!/usr/bin/python3`) then leave that as the first line and add the copyright notice afterwards. - If the first line of the file is a line beginning with `#!` (e.g. `#!/usr/bin/python3`) then leave that as the first line and add the copyright notice afterwards.
- If a copyright notice is present but it says something like `Copyright 2018 Ocean Protocol Foundation` then please change it to say the above. - If a copyright notice is present but it says something like `Copyright 2018 Ocean Protocol Foundation` then please change it to say the above.
- Make sure you're using the correct syntax for comments (which varies from language to language). The example shown above is for a Python file. - Make sure you're using the correct syntax for comments (which varies from language to language). The example shown above is for a Python file.
1. Read the [Developer Certificate of Origin, Version 1.1](https://developercertificate.org/). 1. Read the [Developer Certificate of Origin, Version 1.1](https://developercertificate.org/).
1. You will be asked to include a Signed-off-by line in all your commit messages. (Instructions are given in the next step.) Make sure you understand that including a Signed-off-by line in your commits certifies that you can make the statements in the Developer Certificate of Origin. If you have questions about this, then please [ask on Gitter](https://gitter.im/oceanprotocol/Lobby) or elsewhere. Do not continue until you fully understand. 1. You will be asked to include a Signed-off-by line in all your commit messages. (Instructions are given in the next step.) Make sure you understand that including a Signed-off-by line in your commits certifies that you can make the statements in the Developer Certificate of Origin. If you have questions about this, then please [ask on Gitter](https://gitter.im/oceanprotocol/Lobby) or elsewhere. Do not continue until you fully understand.
1. Make sure that all your commit messages include a Signed-off-by line of the form: 1. Make sure that all your commit messages include a Signed-off-by line of the form:

View File

@ -7,11 +7,11 @@ description: The technical basics of Ocean Tokens.
**Ocean Tokens** are the [cryptocurrency](https://en.wikipedia.org/wiki/Cryptocurrency) associated with Ocean Protocol. They are standards-compliant [ERC-20 tokens](https://en.wikipedia.org/wiki/ERC-20). **Ocean Tokens** are the [cryptocurrency](https://en.wikipedia.org/wiki/Cryptocurrency) associated with Ocean Protocol. They are standards-compliant [ERC-20 tokens](https://en.wikipedia.org/wiki/ERC-20).
Property | Value | Property | Value |
-----------------------|--------- | ---------------------- | -------------------------------------------------------- |
Token Contract Address | [See the tutorial](/tutorials/wallets-and-ocean-tokens/) | Token Contract Address | [See the tutorial](/tutorials/wallets-and-ocean-tokens/) |
Token Symbol | OCEAN | Token Symbol | OCEAN |
Decimals of Precision | 18 | Decimals of Precision | 18 |
## Testnet Ocean Tokens ## Testnet Ocean Tokens

View File

@ -31,10 +31,10 @@ The Nile Testnet is similar to the Kovan Testnet, except all the nodes are opera
There is a Nile blockchain explorer at [https://submarine.dev-ocean.com/](https://submarine.dev-ocean.com/). You can use it to check the status of a transaction, the balance of an account, and more. It uses the following symbols for Nile Ether and Nile Ocean Tokens: There is a Nile blockchain explorer at [https://submarine.dev-ocean.com/](https://submarine.dev-ocean.com/). You can use it to check the status of a transaction, the balance of an account, and more. It uses the following symbols for Nile Ether and Nile Ocean Tokens:
Cryptocurrency | Symbol used | Cryptocurrency | Symbol used |
------------------|------------ | ----------------- | ---------------- |
Nile Ether | POA | Nile Ether | POA |
Nile Ocean Tokens | OCEAN or SBT-OCN | Nile Ocean Tokens | OCEAN or SBT-OCN |
### Ocean Components Connected to Nile ### Ocean Components Connected to Nile

View File

@ -38,7 +38,6 @@ Note that unlike traditional pocket wallets, crypto wallets don't actually store
See the [tutorials about using wallets with Ocean Protocol](http://localhost:8000/tutorials/introduction/). See the [tutorials about using wallets with Ocean Protocol](http://localhost:8000/tutorials/introduction/).
[1]: https://metamask.io/ [1]: https://metamask.io/
[2]: https://trezor.io/ [2]: https://trezor.io/
[3]: https://www.ledger.com/ [3]: https://www.ledger.com/

View File

@ -13,12 +13,12 @@ If you're using [Barge](https://github.com/oceanprotocol/barge) to run a local K
Here are the parameters you might need to connect to the [Nile Testnet](/concepts/testnets/#the-nile-testnet): Here are the parameters you might need to connect to the [Nile Testnet](/concepts/testnets/#the-nile-testnet):
Parameter | Value | Parameter | Value |
-------------------|--------------- | ------------------ | ---------------------------------------------------------- |
RPC URL (required) | [https://nile.dev-ocean.com/](https://nile.dev-ocean.com/) | RPC URL (required) | [https://nile.dev-ocean.com/](https://nile.dev-ocean.com/) |
ChainID | 8995 (decimal for MetaMask) or 0x2323 (hexadecimal) | ChainID | 8995 (decimal for MetaMask) or 0x2323 (hexadecimal) |
Symbol | Whatever you like | Symbol | Whatever you like |
Nickname | Whatever you like | Nickname | Whatever you like |
In MetaMask, click on the network name then click on `Custom RPC` in the drop-down list. Scroll down to the `New Network` section. Enter the above RPC URL. You don't need to add a port number to the end of the RPC URL. Enter the ChainID, Symbol and Nickname if you like. See the [MetaMask docs about how it uses the ChainID](https://metamask.github.io/metamask-docs/Main_Concepts/Sending_Transactions). In MetaMask, click on the network name then click on `Custom RPC` in the drop-down list. Scroll down to the `New Network` section. Enter the above RPC URL. You don't need to add a port number to the end of the RPC URL. Enter the ChainID, Symbol and Nickname if you like. See the [MetaMask docs about how it uses the ChainID](https://metamask.github.io/metamask-docs/Main_Concepts/Sending_Transactions).

View File

@ -79,8 +79,8 @@ All Squid libraries have methods to request Ocean Tokens. They work by calling t
- [OceanAccounts.requestTokens()](/references/squid-js/#OceanAccounts-requestTokens) - [OceanAccounts.requestTokens()](/references/squid-js/#OceanAccounts-requestTokens)
- [Account.requestTokens()](/references/squid-js/#Account-requestTokens) - [Account.requestTokens()](/references/squid-js/#Account-requestTokens)
- The squid-py docs for: - The squid-py docs for:
- [the squid\_py.ocean.ocean\_tokens module](https://squid-py.readthedocs.io/en/develop/api/squid_py.ocean.ocean_tokens.html): see the `request()` method. - [the `squid_py.ocean.ocean_tokens` module](https://squid-py.readthedocs.io/en/develop/api/squid_py.ocean.ocean_tokens.html): see the `request()` method.
- [the squid\_py.ocean.ocean\_accounts module](https://squid-py.readthedocs.io/en/develop/api/squid_py.ocean.ocean_accounts.html): see the `request_tokens()` method. - [the `squid_py.ocean.ocean_accounts` module](https://squid-py.readthedocs.io/en/develop/api/squid_py.ocean.ocean_accounts.html): see the `request_tokens()` method.
- [The squid-java docs](https://www.javadoc.io/doc/com.oceanprotocol/squid/): click "All Classes" then "AccountsManager" then scroll to the bottom of the Class AccountsManager page where you'll find the `requestTokens()` method. - [The squid-java docs](https://www.javadoc.io/doc/com.oceanprotocol/squid/): click "All Classes" then "AccountsManager" then scroll to the bottom of the Class AccountsManager page where you'll find the `requestTokens()` method.
The [Example Code page](/tutorials/example-code/) has links to example Squid code (in all of the languages), including examples of using the above methods. The [Example Code page](/tutorials/example-code/) has links to example Squid code (in all of the languages), including examples of using the above methods.

View File

@ -86,67 +86,67 @@ window.ethereum.enable()
const asset = { const asset = {
base: { base: {
name: "10 Monkey Species Small", name: '10 Monkey Species Small',
dateCreated: "2012-02-01T10:55:11Z", dateCreated: '2012-02-01T10:55:11Z',
author: "Mario", author: 'Mario',
license: "CC0: Public Domain", license: 'CC0: Public Domain',
contentType: "jpg/txt", contentType: 'jpg/txt',
price: 10, price: 10,
files: [ files: [
{ {
checksum: "2bf9d229d110d1976cdf85e9f3256c7f", checksum: '2bf9d229d110d1976cdf85e9f3256c7f',
checksumType: "MD5", checksumType: 'MD5',
contentLength: 12057507, contentLength: 12057507,
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/training.zip" url:
'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/training.zip'
}, },
{ {
checksum: "354d19c0733c47ef3a6cce5b633116b0", checksum: '354d19c0733c47ef3a6cce5b633116b0',
checksumType: "MD5", checksumType: 'MD5',
contentLength: 928, contentLength: 928,
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/monkey_labels.txt" url:
'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/monkey_labels.txt'
}, },
{ {
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/validation.zip" url:
'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/validation.zip'
} }
], ],
checksum: "", checksum: '',
categories: [ categories: ['image'],
"image" tags: ['image data', 'classification', 'animals'],
], type: 'dataset',
tags: [ description: 'EXAMPLE ONLY ',
"image data", size: '3.1gb',
"classification", copyrightHolder: 'Unknown',
"animals" encoding: 'UTF-8',
], compression: 'zip',
type: "dataset", workExample: 'image path, id, label',
description: "EXAMPLE ONLY ",
size: "3.1gb",
copyrightHolder: "Unknown",
encoding: "UTF-8",
compression: "zip",
workExample: "image path, id, label",
links: [ links: [
{ {
name: "example model", name: 'example model',
url: "https://drive.google.com/open?id=1uuz50RGiAW8YxRcWeQVgQglZpyAebgSM" url:
'https://drive.google.com/open?id=1uuz50RGiAW8YxRcWeQVgQglZpyAebgSM'
}, },
{ {
name: "example code", name: 'example code',
type: "example code", type: 'example code',
url: "https://github.com/slothkong/CNN_classification_10_monkey_species" url: 'https://github.com/slothkong/CNN_classification_10_monkey_species'
}, },
{ {
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/links/discovery/n5151.jpg", url:
name: "n5151.jpg", 'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/links/discovery/n5151.jpg',
type: "discovery" name: 'n5151.jpg',
type: 'discovery'
}, },
{ {
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/links/sample/sample.zip", url:
name: "sample.zip", 'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/links/sample/sample.zip',
type: "sample" name: 'sample.zip',
type: 'sample'
} }
], ],
inLanguage: "en" inLanguage: 'en'
} }
} }
@ -171,7 +171,7 @@ class App extends Component {
} }
async retrieveAssets() { async retrieveAssets() {
this.dbAssets = await this.ocean.assets.search("10 Monkey Species Small") this.dbAssets = await this.ocean.assets.search('10 Monkey Species Small')
console.log(this.dbAssets) console.log(this.dbAssets)
} }

View File

@ -18,67 +18,67 @@ To do that, we need to add the following code after `window.ethereum.enable()` l
```js ```js
const asset = { const asset = {
base: { base: {
name: "10 Monkey Species Small", name: '10 Monkey Species Small',
dateCreated: "2012-02-01T10:55:11Z", dateCreated: '2012-02-01T10:55:11Z',
author: "Mario", author: 'Mario',
license: "CC0: Public Domain", license: 'CC0: Public Domain',
contentType: "jpg/txt", contentType: 'jpg/txt',
price: 10, price: 10,
files: [ files: [
{ {
checksum: "2bf9d229d110d1976cdf85e9f3256c7f", checksum: '2bf9d229d110d1976cdf85e9f3256c7f',
checksumType: "MD5", checksumType: 'MD5',
contentLength: 12057507, contentLength: 12057507,
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/training.zip" url:
'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/training.zip'
}, },
{ {
checksum: "354d19c0733c47ef3a6cce5b633116b0", checksum: '354d19c0733c47ef3a6cce5b633116b0',
checksumType: "MD5", checksumType: 'MD5',
contentLength: 928, contentLength: 928,
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/monkey_labels.txt" url:
'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/monkey_labels.txt'
}, },
{ {
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/validation.zip" url:
'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/validation.zip'
} }
], ],
checksum: "", checksum: '',
categories: [ categories: ['image'],
"image" tags: ['image data', 'classification', 'animals'],
], type: 'dataset',
tags: [ description: 'EXAMPLE ONLY ',
"image data", size: '3.1gb',
"classification", copyrightHolder: 'Unknown',
"animals" encoding: 'UTF-8',
], compression: 'zip',
type: "dataset", workExample: 'image path, id, label',
description: "EXAMPLE ONLY ",
size: "3.1gb",
copyrightHolder: "Unknown",
encoding: "UTF-8",
compression: "zip",
workExample: "image path, id, label",
links: [ links: [
{ {
name: "example model", name: 'example model',
url: "https://drive.google.com/open?id=1uuz50RGiAW8YxRcWeQVgQglZpyAebgSM" url:
'https://drive.google.com/open?id=1uuz50RGiAW8YxRcWeQVgQglZpyAebgSM'
}, },
{ {
name: "example code", name: 'example code',
type: "example code", type: 'example code',
url: "https://github.com/slothkong/CNN_classification_10_monkey_species" url: 'https://github.com/slothkong/CNN_classification_10_monkey_species'
}, },
{ {
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/links/discovery/n5151.jpg", url:
name: "n5151.jpg", 'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/links/discovery/n5151.jpg',
type: "discovery" name: 'n5151.jpg',
type: 'discovery'
}, },
{ {
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/links/sample/sample.zip", url:
name: "sample.zip", 'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/links/sample/sample.zip',
type: "sample" name: 'sample.zip',
type: 'sample'
} }
], ],
inLanguage: "en" inLanguage: 'en'
} }
} }
``` ```
@ -105,7 +105,7 @@ Tip: Before clicking the `Register asset` button, it might help to reload the pa
When you click on the `Register asset` button, you should get four separate dialog boxes from MetaMask, in a series, i.e. the second one only appears after you accept/approve the first one, and so on. When you click on the `Register asset` button, you should get four separate dialog boxes from MetaMask, in a series, i.e. the second one only appears after you accept/approve the first one, and so on.
If you have no errors in your `console.log`, then you have successfully registered an asset. If you have no errors in your `console.log`, then you have successfully registered an asset.
## Final Result ## Final Result
@ -122,67 +122,67 @@ window.ethereum.enable()
const asset = { const asset = {
base: { base: {
name: "10 Monkey Species Small", name: '10 Monkey Species Small',
dateCreated: "2012-02-01T10:55:11Z", dateCreated: '2012-02-01T10:55:11Z',
author: "Mario", author: 'Mario',
license: "CC0: Public Domain", license: 'CC0: Public Domain',
contentType: "jpg/txt", contentType: 'jpg/txt',
price: 10, price: 10,
files: [ files: [
{ {
checksum: "2bf9d229d110d1976cdf85e9f3256c7f", checksum: '2bf9d229d110d1976cdf85e9f3256c7f',
checksumType: "MD5", checksumType: 'MD5',
contentLength: 12057507, contentLength: 12057507,
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/training.zip" url:
'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/training.zip'
}, },
{ {
checksum: "354d19c0733c47ef3a6cce5b633116b0", checksum: '354d19c0733c47ef3a6cce5b633116b0',
checksumType: "MD5", checksumType: 'MD5',
contentLength: 928, contentLength: 928,
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/monkey_labels.txt" url:
'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/monkey_labels.txt'
}, },
{ {
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/validation.zip" url:
'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/assets/validation.zip'
} }
], ],
checksum: "", checksum: '',
categories: [ categories: ['image'],
"image" tags: ['image data', 'classification', 'animals'],
], type: 'dataset',
tags: [ description: 'EXAMPLE ONLY ',
"image data", size: '3.1gb',
"classification", copyrightHolder: 'Unknown',
"animals" encoding: 'UTF-8',
], compression: 'zip',
type: "dataset", workExample: 'image path, id, label',
description: "EXAMPLE ONLY ",
size: "3.1gb",
copyrightHolder: "Unknown",
encoding: "UTF-8",
compression: "zip",
workExample: "image path, id, label",
links: [ links: [
{ {
name: "example model", name: 'example model',
url: "https://drive.google.com/open?id=1uuz50RGiAW8YxRcWeQVgQglZpyAebgSM" url:
'https://drive.google.com/open?id=1uuz50RGiAW8YxRcWeQVgQglZpyAebgSM'
}, },
{ {
name: "example code", name: 'example code',
type: "example code", type: 'example code',
url: "https://github.com/slothkong/CNN_classification_10_monkey_species" url: 'https://github.com/slothkong/CNN_classification_10_monkey_species'
}, },
{ {
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/links/discovery/n5151.jpg", url:
name: "n5151.jpg", 'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/links/discovery/n5151.jpg',
type: "discovery" name: 'n5151.jpg',
type: 'discovery'
}, },
{ {
url: "https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/links/sample/sample.zip", url:
name: "sample.zip", 'https://s3.amazonaws.com/datacommons-seeding-us-east/10_Monkey_Species_Small/links/sample/sample.zip',
type: "sample" name: 'sample.zip',
type: 'sample'
} }
], ],
inLanguage: "en" inLanguage: 'en'
} }
} }

View File

@ -8,6 +8,7 @@ description: This tutorial shows how you can build a basic [React](https://react
- `Node.js` >= 10 is installed. You can check using `node -v` - `Node.js` >= 10 is installed. You can check using `node -v`
- `npm` >= 5.2 is installed. You can check using `npm -v` - `npm` >= 5.2 is installed. You can check using `npm -v`
- Git clone the [oceanprotocol/barge](https://github.com/oceanprotocol/barge) repository, then in that directory: - Git clone the [oceanprotocol/barge](https://github.com/oceanprotocol/barge) repository, then in that directory:
- (Optional) If you want to use Azure Storage or Amazon S3 storage, then go through the tutorials to set those up: [Azure](/tutorials/azure-for-brizo/) or [Amazon](/tutorials/amazon-s3-for-brizo/). Note that if you're using Azure Storage, you must edit the `barge/brizo.env` file and set all `AZURE_`... values. - (Optional) If you want to use Azure Storage or Amazon S3 storage, then go through the tutorials to set those up: [Azure](/tutorials/azure-for-brizo/) or [Amazon](/tutorials/amazon-s3-for-brizo/). Note that if you're using Azure Storage, you must edit the `barge/brizo.env` file and set all `AZURE_`... values.
- (Optional but recommended) Clean out all your old Docker stuff using `docker system prune --all --volumes` - (Optional but recommended) Clean out all your old Docker stuff using `docker system prune --all --volumes`
- Use Barge to run a local Spree Testnet: - Use Barge to run a local Spree Testnet:

View File

@ -9,10 +9,10 @@ If you don't see any Ocean Tokens in your wallet software (e.g. MetaMask or MyEt
### Kovan or Nile Testnet ### Kovan or Nile Testnet
Testnet | Ocean Token Contract Address | Testnet | Ocean Token Contract Address |
--------------|----------------------------- | ------- | -------------------------------------------- |
Kovan | `0xB57C4D626548eB8AC0B82b086721516493E2908d` | Kovan | `0xB57C4D626548eB8AC0B82b086721516493E2908d` |
Nile | `0xcDae1AFa8025BE03Bc56D112eB4da3277913563d` | Nile | `0xcDae1AFa8025BE03Bc56D112eB4da3277913563d` |
If the above addresses are out-of-date, then you can find newer ones in the [keeper-contracts repository on GitHub](https://github.com/oceanprotocol/keeper-contracts): If the above addresses are out-of-date, then you can find newer ones in the [keeper-contracts repository on GitHub](https://github.com/oceanprotocol/keeper-contracts):