1. Apr 16, 2024
  2. Apr 09, 2024
  3. Mar 25, 2024
  4. Mar 14, 2024
    • Ignacio Palacios's avatar
      Improve Penpal runtime + emulated tests (#3543) · cfc4050d
      Ignacio Palacios authored
      Issues addressed in this PR:
      - Improve *Penpal* runtime:
      - Properly handled received assets. Previously, it treated `(1, Here)`
      as the local native currency, whereas it should be treated as a
      `ForeignAsset`. This wasn't a great example of standard Parachain
      behaviour, as no Parachain treats the system asset as the local
      currency.
      - Remove `AllowExplicitUnpaidExecutionFrom` the system. Again, this
      wasn't a great example of standard Parachain behaviour.
      - Move duplicated
      `ForeignAssetFeeAsExistentialDepositMultiplierFeeCharger` to
      `assets_common` crate.
      - Improve emulated tests:
        - Update *Penpal* tests to new runtime.
      - To simplify tests, register the reserve transferred, teleported, and
      system assets in *Penpal* and *AssetHub* genesis. This saves us from
      having to create the assets repeatedly for each test
      - Add missing test case:
      `reserve_transfer_assets_from_para_to_system_para`.
        - Cleanup.
      - Prevent integration tests crates imports from being re-exported, as
      they were polluting the `polkadot-sdk` docs.
      
      There is still a test case missing for reserve transfers:
      - Reserve transfer of system asset from *Parachain* to *Parachain*
      trough *AssetHub*.
      - This is not yet possible with `pallet-xcm` due to the reasons
      explained in https://github.com/paritytech/polkadot-sdk/pull/3339
      
      ---------
      
      Co-authored-by: command-bot <>
      cfc4050d
  5. Jan 31, 2024
  6. Jan 23, 2024
  7. Dec 13, 2023
  8. Dec 08, 2023
    • Muharem Ismailov's avatar
      Westend: Fellowship Treasury (#2532) · da40d97a
      Muharem Ismailov authored
      
      
      Treasury Pallet Instance for the Fellowship in Westend Collectives.
      
      In this update, we present a Treasury Pallet Instance that is under the
      control of the Fellowship body, with oversight from the Root and
      Treasurer origins. Here's how it is governed:
      - the Root origin have the authority to reject or approve spend
      proposals, with no amount limit for approvals.
      - the Treasurer origin have the authority to reject or approve spend
      proposals, with approval limits of up to 10,000,000 DOT.
      - Voice of all Fellows ranked at 3 or above can reject or approve spend
      proposals, with a maximum approval limit of 10,000 DOT.
      - Voice of Fellows ranked at 4 or above can also reject or approve spend
      proposals, with a maximum approval limit of 10,000,000 DOT.
      
      Additionally, we introduce the Asset Rate Pallet Instance to establish
      conversion rates from asset A to B. This is used to determine if a
      proposed spend amount involving a non-native asset is permissible by the
      commanding origin. The rates can be set up by the Root, Treasurer
      origins, or Voice of all Fellows.
      
      ---------
      
      Co-authored-by: default avatarjoe petrowski <[email protected]>
      Co-authored-by: default avatarjoepetrowski <[email protected]>
      da40d97a
  9. Dec 06, 2023
    • Adrian Catangiu's avatar
      pallet-xcm: add new flexible `transfer_assets()` call/extrinsic (#2388) · e7651cf4
      Adrian Catangiu authored
      # Motivation (+testing)
      
      ### Enable easy `ForeignAssets` transfers using `pallet-xcm` 
      
      We had just previously added capabilities to teleport fees during
      reserve-based transfers, but what about reserve-transferring fees when
      needing to teleport some non-fee asset?
      
      This PR aligns everything under either explicit reserve-transfer,
      explicit teleport, or this new flexible `transfer_assets()` which can
      mix and match as needed with fewer artificial constraints imposed to the
      user.
      
      This will enable, for example, a (non-system) parachain to teleport
      their `ForeignAssets` assets to AssetHub while using DOT to pay fees.
      (the assets are teleported - as foreign assets should from their owner
      chain - while DOT used for fees can only be reserve-based transferred
      between said parachain and AssetHub).
      
      Added `xcm-emulator` tests for this scenario ^.
      
      # Description
      
      Reverts `(limited_)reserve_transfer_assets` to only allow reserve-based
      transfers for all `assets` including fees.
      
      Similarly `(limited_)teleport_assets` only allows teleports for all
      `assets` including fees.
          
      For complex combinations of asset transfers where assets and fees may
      have different reserves or different reserve/teleport trust
      configurations, users can use the newly added `transfer_assets()`
      extrinsic which is more flexible in allowing more complex scenarios.
      
      `assets` (excluding `fees`) must have same reserve location or otherwise
      be teleportable to `dest`.
      No limitations imposed on `fees`.
      
      - for local reserve: transfer assets to sovereign account of destination
      chain and forward a notification XCM to `dest` to mint and deposit
      reserve-based assets to `beneficiary`.
      - for destination reserve: burn local assets and forward a notification
      to `dest` chain to withdraw the reserve assets from this chain's
      sovereign account and deposit them to `beneficiary`.
      - for remote reserve: burn local assets, forward XCM to reserve chain to
      move reserves from this chain's SA to `dest` chain's SA, and forward
      another XCM to `dest` to mint and deposit reserve-based assets to
      `beneficiary`.
      - for teleports: burn local assets and forward XCM to `dest` chain to
      mint/teleport assets and deposit them to `beneficiary`.
      
      ## Review notes
      
      Only around 500 lines are prod code (see `pallet_xcm/src/lib.rs`), the
      rest of the PR is new tests and improving existing tests.
      
      ---------
      
      Co-authored-by: command-bot <>
      e7651cf4
  10. Dec 01, 2023
  11. Nov 27, 2023
  12. Nov 08, 2023
    • Ignacio Palacios's avatar
      [xcm-emulator] Chains generic over Network & Integration tests restructure (#2092) · ffa0e30e
      Ignacio Palacios authored
      Closes:
      - #1383 
      - Declared chains can be now be imported and reused in a different
      crate.
      - Chain declaration are now generic over a generic type `N` (the
      Network)
      - #1389
      - Solved #1383, chains and networks declarations can be restructure to
      avoid having to compile all chains when running integrations tests where
      are not needed.
      - Chains are now declared on its own crate (removed from
      `integration-tests-common`)
      - Networks are now declared on its own crate (removed from
      `integration-tests-common`)
          - Integration tests will import only the relevant Network crate
      - `integration-tests-common` is renamed to
      `emulated-integration-tests-common`
      
      All this is necessary to be able to implement what is described here:
      https://github.com/paritytech/roadmap/issues/56#issuecomment-1777010553
      
      ---------
      
      Co-authored-by: command-bot <>
      ffa0e30e