Cleaning up polluted namespaces (#3143)

* Renaming ethcore_ to parity_

* Renaming files

* Renaming poluted EthSigning

* Tidy up the namespaces

* Renaming files to match new structure

* Splitting EthSigning into separate traits

* jsapi move ethcore.* -> parity.*

* Move jsonrpc parity definitions

* Update UI API calls for parity interfaces

* Move jsapi signer interfaces from personal to signer

* Update UI to use signer.* where applicable

* Updsate jsapi subscriptions for signer

* Fix dodgy merge.

* Update README.

* Fix some tests.

* Move parity-only personal.* to parity.*

* Update UI for personal -> parity API moves

* Update subscription APIs after personal -> parity move

* personal. generateAuthorizationToken -> parity. generateAuthorizationToken (UI)

* enode, dappsPort & signerPort (UI)

* Update subscription tests (accountsInfo)

* subscription update

* personal -> parity

* Additional error logging on method failures

* move postTransaction to parity

* Additional debug info with method failures

* Fix personal tests.

* Console wrning shows parameters, error object does not

* Include parity_ signing methods.

* Console log http transport info

* Fix failing tests

* Add RPC stubs for parity_accounts.

* Allow some secure built-in dapps

* Use parity_accounts in place of accountsInfo

* Improve error reporting

* Cleanup GHH error handling
This commit is contained in:
Tomasz Drwięga
2016-11-06 12:51:53 +01:00
committed by Gav Wood
parent 78f2d88182
commit 9c4979681c
101 changed files with 1899 additions and 1466 deletions

View File

@@ -208,13 +208,13 @@ export default class CreateAccount extends Component {
});
if (createType === 'fromNew' || createType === 'fromPhrase') {
return api.personal
return api.parity
.newAccountFromPhrase(this.state.phrase, this.state.password)
.then((address) => {
this.setState({ address });
return api.personal
return api.parity
.setAccountName(address, this.state.name)
.then(() => api.personal.setAccountMeta(address, {
.then(() => api.parity.setAccountMeta(address, {
timestamp: Date.now(),
passwordHint: this.state.passwordHint
}));
@@ -233,13 +233,13 @@ export default class CreateAccount extends Component {
this.newError(error);
});
} else if (createType === 'fromRaw') {
return api.personal
return api.parity
.newAccountFromSecret(this.state.rawKey, this.state.password)
.then((address) => {
this.setState({ address });
return api.personal
return api.parity
.setAccountName(address, this.state.name)
.then(() => api.personal.setAccountMeta(address, {
.then(() => api.parity.setAccountMeta(address, {
timestamp: Date.now(),
passwordHint: this.state.passwordHint
}));
@@ -258,13 +258,13 @@ export default class CreateAccount extends Component {
this.newError(error);
});
} else if (createType === 'fromGeth') {
return api.personal
return api.parity
.importGethAccounts(this.state.gethAddresses)
.then((result) => {
console.log('result', result);
return Promise.all(this.state.gethAddresses.map((address) => {
return api.personal.setAccountName(address, 'Geth Import');
return api.parity.setAccountName(address, 'Geth Import');
}));
})
.then(() => {
@@ -282,16 +282,16 @@ export default class CreateAccount extends Component {
});
}
return api.personal
return api.parity
.newAccountFromWallet(this.state.json, this.state.password)
.then((address) => {
this.setState({
address: address
});
return api.personal
return api.parity
.setAccountName(address, this.state.name)
.then(() => api.personal.setAccountMeta(address, {
.then(() => api.parity.setAccountMeta(address, {
timestamp: Date.now(),
passwordHint: this.state.passwordHint
}));