Backporting to beta (#4418)

* v1.5.1

* Disable notifications (#4243)

* Fix wrong token handling (#4254)

* Fixing wrong token displayed

* Linting

* Revert filtering out

* Revert the revert

* Don't panic on uknown git commit hash (#4231)

* Additional logs for own transactions (#4278)

* Integration with zgp whitelist contract (#4215)

* zgp-transactions checker

* polishing

* rename + refactor

* refuse-service-transactions cl option

* fixed tests compilation

* Renaming signAndSendTransaction to sendTransaction (#4351)

* Fixed deadlock in external_url (#4354)

* Fixing web3 in console (#4382)

* Fixing estimate gas in case histogram is not available (#4387)

* Restarting fetch client every now and then (#4399)
This commit is contained in:
Arkadiy Paronyan
2017-02-03 13:57:04 +01:00
committed by Gav Wood
parent b09cfe1885
commit c7dbd87f8e
40 changed files with 1501 additions and 734 deletions

View File

@@ -54,9 +54,6 @@ pub enum QueueAddError {
LimitReached,
}
/// Message Receiver type
pub type QueueEventReceiver = mpsc::Receiver<QueueEvent>;
// TODO [todr] to consider: timeout instead of limit?
const QUEUE_LIMIT: usize = 50;

View File

@@ -102,7 +102,7 @@ impl<C: 'static, M: 'static> Personal for PersonalClient<C, M> where C: MiningBl
}
}
fn sign_and_send_transaction(&self, request: TransactionRequest, password: String) -> Result<RpcH256, Error> {
fn send_transaction(&self, request: TransactionRequest, password: String) -> Result<RpcH256, Error> {
self.active()?;
let client = take_weak!(self.client);
let miner = take_weak!(self.miner);

View File

@@ -66,6 +66,7 @@ fn miner_service(spec: &Spec, accounts: Arc<AccountProvider>) -> Arc<Miner> {
reseal_min_period: Duration::from_secs(0),
work_queue_size: 50,
enable_resubmission: true,
refuse_service_transactions: false,
},
GasPricer::new_fixed(20_000_000_000u64.into()),
&spec,

View File

@@ -96,7 +96,7 @@ fn sign_and_send_transaction_with_invalid_password() {
let address = tester.accounts.new_account("password123").unwrap();
let request = r#"{
"jsonrpc": "2.0",
"method": "personal_signAndSendTransaction",
"method": "personal_sendTransaction",
"params": [{
"from": ""#.to_owned() + format!("0x{:?}", address).as_ref() + r#"",
"to": "0xd46e8dd67c5d32be8058bb8eb970870f07244567",
@@ -119,7 +119,7 @@ fn sign_and_send_transaction() {
let request = r#"{
"jsonrpc": "2.0",
"method": "personal_signAndSendTransaction",
"method": "personal_sendTransaction",
"params": [{
"from": ""#.to_owned() + format!("0x{:?}", address).as_ref() + r#"",
"to": "0xd46e8dd67c5d32be8058bb8eb970870f07244567",

View File

@@ -36,7 +36,7 @@ build_rpc_trait! {
fn unlock_account(&self, H160, String, Option<U128>) -> Result<bool, Error>;
/// Sends transaction and signs it in single call. The account is not unlocked in such case.
#[rpc(name = "personal_signAndSendTransaction")]
fn sign_and_send_transaction(&self, TransactionRequest, String) -> Result<H256, Error>;
#[rpc(name = "personal_sendTransaction")]
fn send_transaction(&self, TransactionRequest, String) -> Result<H256, Error>;
}
}