Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: prepare for 1.20.0 release #4443

Merged
merged 5 commits into from
Jul 1, 2021
Merged

feat: prepare for 1.20.0 release #4443

merged 5 commits into from
Jul 1, 2021

Conversation

bowenwang1996
Copy link
Collaborator

Stabilize multiple protocol features

Test plan

Nayduck http://nayduck.eastus.cloudapp.azure.com:3000/#/run/1711

runtime/near-vm-errors/src/lib.rs Outdated Show resolved Hide resolved
Comment on lines +129 to +135
ProtocolFeature::AccountVersions => 46,
ProtocolFeature::TransactionSizeLimit => 46,
ProtocolFeature::AllowCreateAccountOnDelete => 46,
ProtocolFeature::FixStorageUsage => 46,
ProtocolFeature::CapMaxGasPrice => 46,
ProtocolFeature::CountRefundReceiptsInGasLimit => 46,
ProtocolFeature::MathExtension => 46,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are these features documented?

@khorolets @telezhnaya please, keep in mind the AllowCreateAccountOnDelete feature.

if checked_feature!(
"protocol_feature_allow_create_account_on_delete",
AllowCreateAccountOnDelete,
current_protocol_version
) {
let sender_is_receiver = account_id == &delete_account.beneficiary_id;
let is_receiver_implicit =
is_implicit_account_creation_enabled(current_protocol_version)
&& is_account_id_64_len_hex(&delete_account.beneficiary_id);
let exec_gas = config.action_receipt_creation_config.send_fee(sender_is_receiver)
+ transfer_send_fee(
&config.action_creation_config,
sender_is_receiver,
is_receiver_implicit,
);
result.gas_burnt += exec_gas;
result.gas_used += exec_gas
+ config.action_receipt_creation_config.exec_fee()
+ transfer_exec_fee(&config.action_creation_config, is_receiver_implicit);
result.new_receipts.push(Receipt {
predecessor_id: account_id.clone(),
receiver_id: delete_account.beneficiary_id.clone(),
// Actual receipt ID is set in the Runtime.apply_action_receipt(...) in the
// "Generating receipt IDs" section
receipt_id: CryptoHash::default(),
receipt: ReceiptEnum::Action(ActionReceipt {
signer_id: action_receipt.signer_id.clone(),
signer_public_key: action_receipt.signer_public_key.clone(),
gas_price: action_receipt.gas_price,
output_data_receivers: vec![],
input_data_ids: vec![],
actions: vec![Action::Transfer(TransferAction { deposit: account_balance })],
}),
});
} else {
result
.new_receipts
.push(Receipt::new_balance_refund(&delete_account.beneficiary_id, account_balance));
}

This seem to use a regular transfer action receipt, so Indexer for Explorer should be fine.

@frol
Copy link
Collaborator

frol commented Jul 1, 2021

@bowenwang1996 I suggest we stabilize features the week before we cut a release.

@bowenwang1996 bowenwang1996 merged commit d95a1ed into master Jul 1, 2021
@bowenwang1996 bowenwang1996 deleted the prepare-for-1.20.0 branch July 1, 2021 22:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants