Skip to content

Commit 5f9638e

Browse files
Merge pull request #11 from opentensor/tensordot-v1.4.0-fixes/balances_type_adjust
Adjust AccountData type to preserve old data layout
2 parents fcfdb98 + 345cc6a commit 5f9638e

File tree

8 files changed

+37
-36
lines changed

8 files changed

+37
-36
lines changed

.config/lychee.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,11 @@ exclude = [
2525
"http://visitme/",
2626
"https://visitme/",
2727

28-
# TODO <https://github.com/paritytech/polkadot-sdk/issues/134>
28+
# TODO <https://github.com/opentensor/polkadot-sdk/issues/134>
2929
"https://docs.substrate.io/main-docs/build/custom-rpc/#public-rpcs",
3030
"https://docs.substrate.io/rustdocs/latest/sp_api/macro.decl_runtime_apis.html",
3131
"https://github.com/ipfs/js-ipfs-bitswap/blob/",
32-
"https://github.com/paritytech/polkadot-sdk/substrate/frame/timestamp",
32+
"https://github.com/opentensor/polkadot-sdk/substrate/frame/timestamp",
3333
"https://github.com/paritytech/substrate/frame/fast-unstake",
3434
"https://github.com/zkcrypto/bls12_381/blob/e224ad4ea1babfc582ccd751c2bf128611d10936/src/test-data/mod.rs",
3535
"https://polkadot.network/the-path-of-a-parachain-block/",

.config/zepter.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,5 +39,5 @@ help:
3939
It looks like one more more checks failed; please check the console output. You can try to automatically address them by running `zepter`.
4040
Otherwise please ask directly in the Merge Request, GitHub Discussions or on Matrix Chat, thank you.
4141
links:
42-
- "https://github.com/paritytech/polkadot-sdk/issues/1831"
42+
- "https://github.com/opentensor/polkadot-sdk/issues/1831"
4343
- "https://github.com/ggwpez/zepter"

.gitlab/pipeline/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -504,7 +504,7 @@ cargo-hfuzz:
504504
- for target in $(cargo read-manifest | jq -r '.targets | .[] | .name'); do
505505
cargo hfuzz run "$target" || { printf "fuzzing failure for %s\n" "$target"; exit 1; }; done
506506

507-
# cf https://github.com/paritytech/polkadot-sdk/issues/1652
507+
# cf https://github.com/opentensor/polkadot-sdk/issues/1652
508508
test-syscalls:
509509
stage: test
510510
extends:

Cargo.lock

Lines changed: 25 additions & 25 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[workspace.package]
22
authors = ["Parity Technologies <[email protected]>"]
33
edition = "2021"
4-
repository = "https://github.com/paritytech/polkadot-sdk.git"
4+
repository = "https://github.com/opentensor/polkadot-sdk.git"
55
license = "GPL-3.0-only"
66

77
[workspace]

substrate/frame/balances/src/lib.rs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -688,7 +688,7 @@ pub mod pallet {
688688
origin: OriginFor<T>,
689689
who: Vec<T::AccountId>,
690690
) -> DispatchResultWithPostInfo {
691-
ensure_signed(origin)?;
691+
/*ensure_signed(origin)?;
692692
if who.is_empty() {
693693
return Ok(Pays::Yes.into())
694694
}
@@ -704,7 +704,8 @@ pub mod pallet {
704704
Ok(Pays::No.into())
705705
} else {
706706
Ok(Pays::Yes.into())
707-
}
707+
}*/
708+
Ok(Pays::No.into())
708709
}
709710

710711
/// Set the regular balance of a given account.
@@ -756,10 +757,10 @@ pub mod pallet {
756757
/// Returns `true` if the account did get upgraded, `false` if it didn't need upgrading.
757758
pub fn ensure_upgraded(who: &T::AccountId) -> bool {
758759
let mut a = T::AccountStore::get(who);
759-
if a.flags.is_new_logic() {
760+
if /*a.flags.is_new_logic()*/ true {
760761
return false
761762
}
762-
a.flags.set_new_logic();
763+
//a.flags.set_new_logic();
763764
if !a.reserved.is_zero() && a.frozen.is_zero() {
764765
if system::Pallet::<T>::providers(who) == 0 {
765766
// Gah!! We have no provider refs :(

substrate/frame/balances/src/types.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ pub struct AccountData<Balance> {
105105
pub frozen: Balance,
106106
/// Extra information about this account. The MSB is a flag indicating whether the new ref-
107107
/// counting logic is in place for this account.
108-
pub flags: ExtraFlags,
108+
pub fee_frozen: Balance,
109109
}
110110

111111
const IS_NEW_LOGIC: u128 = 0x80000000_00000000_00000000_00000000u128;

substrate/primitives/consensus/sassafras/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ description = "Primitives for Sassafras consensus"
66
edition = "2021"
77
license = "Apache-2.0"
88
homepage = "https://substrate.io"
9-
repository = "https://github.com/paritytech/polkadot-sdk/"
9+
repository = "https://github.com/opentensor/polkadot-sdk/"
1010
documentation = "https://docs.rs/sp-consensus-sassafras"
1111
readme = "README.md"
1212
publish = false

0 commit comments

Comments
 (0)