Joystream / joystream

Joystream Monorepo
http://www.joystream.org
GNU General Public License v3.0
1.42k stars 115 forks source link

QA plan for `Nara` #4878

Closed bedeho closed 5 months ago

bedeho commented 1 year ago

WIP: Will add link to past plan soon.

Remember to consider all apps, including CLI, where changes have been made.

┆Issue is synchronized with this Asana task by Unito

chrlschwb commented 11 months ago

Changes that need to be tested

Timeline Oct 30 ~ Nov 6

chrlschwb commented 11 months ago

Outline

1. Stage an Ephesus network complete with RPC, QN, Pioneer and Atlas (freakstatic) 2. On the staging network test the following (ivant, polikosi)

RPC

CLI

Atlas

3. Create a node with new runtime and expose RPC endpoint (freakstatic) 4. Perform a runtime upgrade from Ephesus to Nara using Pioneer Runtime Upgrade Proposal (ivant, polikosi) 5. Perform the following tests on Nara Network (ivant, polikosi)

RPC

Pioneer

CLI

Atlas

bedeho commented 11 months ago

Cover: https://github.com/Joystream/joystream/issues/4907

bedeho commented 11 months ago

Meta

Having a proper QA plan is critical now that we are on mainnet and need much greater assurance, and also when people involed are far less coordinated than when QA <=> dev relationship was much closer than today. Before mainnet, internal QA was done by mostly one person, and those plans may have reflected that.

A production level QA plan needs to be very specific about what the goals are, how success is determined and what resources are needed for a proper test. Without this, proper peer review of the plan is not going to be possible. Vague statements about goals will leave ambiguity, and there may be missed coverage of things that are critical. Also coordination and resource allocation within the QA team will be worse.

Feedback

This plan still can be significantly improved, it's still not clear to me what changes were made from the first version that received feedback, but for the benefit of next iteration please post a new entry into the thread with the new version.

  1. Why are there two seemingly identical CLI sections?
  2. Can you reorganize tests in terms of what they test, not what product is primarily used? So
    • CLI => "Multisig Functionality Still Works"
    • RPC => "Moderator Is Deletion Removed"
    • Pioneer => This is perhaps the bste example of how this does not work. Youare here grouping totally unrelated thigns, like pallet freezing and forum categories, despite them not directly having to do with each other, an reader not being able to easily understand that pallet freezing actually has to do with CRTs, not Pioneer per say. Pioneer is just a tool.
  3. "Atlas: here you just Confirm that CRT functionalities are working". This is badly underspecified, what does this mean? What features exactly are you going to test, with what test scenarios? how many people are needed, what initial state is needed? Almost everything of relevance is missing. This is lastly not really a test of Atlas, its a test of at least two distinct things. That freezinga nd unfreezing works, and that CRT functionality works, and such test will likely span multiple products, no just Atlas.
  4. It seems there is some formatting problems in this markdown, the overall structure is very confusing. Make sure that Markdown works for Github, since this is where display and reviw occurs, not in some other version of Markdown display.
bwhm commented 11 months ago

A few comments from me. In general, I would say it would be nice to add more context.

Some of this I shared on a call, and I'm sure you have though of this, but expanding/repeating it anyway as it's nice to include in the protocol. When testing that a new/changed/removed transaction behaves as intended after a runtime upgrade:

  1. Ensure you know exactly how the transaction work before the runtime upgrade.
  2. If applicable, ensure they would "behave" the same way regardless of whether the TX pointed interacts with "pre upgrade" state or "post upgrade" state.
  3. List all the edge cases you want to test.

The last point is often overlapping with integration tests, but the point also applies to testing pioneer, atlas and the CLI.

--

  1. Stage an Ephesus network complete with RPC, QN, Pioneer and Atlas (freakstatic)

If I were @freakstatic, I would have needed more context here. For testing purposes, we have typically deployed a playground-runtime first, which has only one validator, very different election and proposal periods, making testing easier. Furthermore, you will also start with a council elected, and leads hired for all roles. This is ideal for things that depends on council, proposals and working groups. It's also quick to redeploy and re-test if you happen to find any bugs.

If you haven't already, I would frequently start with a (playground) network with the "post-upgrade" runtime – in this case nara. Otherwise, you may spend time creating state on ephesus only to find you have to do it again, or you'll have to wait for some fixes on the CLI that could have been caught sooner.

For the final test, you may want to use a staging-runtime or a default one, but with some custom parameters (especially for elections and proposals).

  1. On the staging network test the following (ivant, polikosi)

Again, lots of content should be added here. For each transaction:

For the multisig tests – before the upgrade:

After the upgrade.

  1. Final approve the vesting.vest, then the balance.transfer
  2. Final approve
  3. Final approve
  4. Approve, then final approve
  5. Approve, then final approve
  6. Final approve

--

In order to test the content.x transactions (ref point 1. at the top), you need

* Probably not true on a playground-runtime

Then find out in which cases a curator can delete which channels/assets/videos before the upgrade – I don't remember exactly how does this works on ephesus, and I'm not sure how much help you'll get from the handbook...

chrlschwb commented 11 months ago

Requirements for the testing network

The usual playground-runtime wouldn't be ideal for this runtime QA testing because one of the things that need to be tested are the election parameters. Also, during 16th Oct meeting, it was decided to use a testnet with multiple validators for QA testing.

There are two separate required test networks

Scope of QA testing

Runtime upgrade from Ephesus to Nara

Council Election Cycle

Max number of subcategories

max workerNumberLimit for SWG/DWG

Content Curator Deletion power restriction

FreezePallet Proposal

Multisig-related Advanced-transactions (removed from nara scope)

Any constructed call should be successfully signed and the transaction should be performed

bedeho commented 10 months ago

@chrlschwb

In Nara meeting today we concluded that the plan could have benefited from greater specificity about how the different initial settings of each testnet will be actually achieved, for example by stating which runtime profile will be used. Also, if chainspec builder is used, also which deployment option is being used, as this determines the initial genesis configuration to be used. Take this into account for future network QA plans.

mnaamani commented 10 months ago

@freakstatic Will add details of parameters chosen for the testnet(s) here

ivanturlakov commented 10 months ago

In progress...

Tested on https://65.21.109.54.nip.io/pioneer/#/council

Max number of subcategories

✅ Forum lead creates a forum category and 10 sub categories under that.
Before the runtime upgrade, only 5 sub categories were possible.

Screenshot 2023-11-14 at 16 10 00

✅ Forum lead creates 11 sub categories.
This should lead to failure.

Screenshot 2023-11-14 at 16 16 40

max workerNumberLimit for SWG/DWG

✅ SWG Limit

  1. SWG - 25 workers(including lead)
  2. Opening(hire limit 1) created - 29 applicants
  3. Attempting to hire all 29 applicants --> Fail(MaxActiveWorkers) 54>50
  4. Attempting to hire 26 applicants --> Fail(MaxActiveWorkers) 51>50
  5. Attempting to hire 25 applicants --> Success --> Hired 25
  6. SWG - 50 workers (including lead)

✅ DWG Limit

  1. DWG - 26 workers(including lead)
  2. Opening(hire limit 1) created - 26 applicants
  3. Attempting to hire all 26 applicants --> Fail(MaxActiveWorkers) 52>50
  4. Attempting to hire 25 applicants --> Fail(MaxActiveWorkers) 51>50
  5. Attempting to hire 24 applicants --> Success --> Hired 24
  6. DWG - 50 workers (including lead)

Content Curator Deletion power restriction

✅ Extrinsics are removed.
(Extrinsics/content/deleteChannelAsModerator, Extrinsics/content/deleteVideoAsModerator)


Screenshot 2023-11-14 at 14 31 07

✅ CLI Commands are removed.
(joystream-cli content:deleteChannelAsModerator,
joystream-cli content:deleteVideoAsModerator)

Screenshot 2023-11-14 at 15 41 54

Runtime upgrade from Ephesus to Nara

Tested on https://65.108.208.60.nip.io/pioneer/#/proposals/preview/2

Proposal Executed ⚠️ The application is unable to connect to the network Network status - connecting...

Screenshot 2023-12-04 at 12 42 27 Screenshot 2023-12-04 at 12 42 59

Council Election Cycle

(Elect a council on Pioneer and confirm period lengths. This test will be performed on Testnet No.2 which is now in Nara after the Runtime upgrade from Ephesus to Nara test)

Tested on https://65.108.208.60.nip.io/pioneer/#/council

⚠️ As described in the previous step, after the update the app fails to connect to the network, but there is an option to check the data in the Polkadot app

Target - 1s

✅ Idle period should be 56 hours = 201 600 blocks

Screenshot 2023-12-04 at 12 37 24

⚠️ announcing period should be 16 hours = 57 600 blocks

Screenshot 2023-12-04 at 12 38 40

⚠️ voting period should be 24 hours = 86 400 blocks

Screenshot 2023-12-04 at 12 40 30

✅ revealing period should be 16 hours = 57 600 blocks

Screenshot 2023-12-04 at 12 41 06
chrlschwb commented 9 months ago

QA result for Atlas CRT feature testing https://github.com/Joystream/atlas/issues/5483

freakstatic commented 9 months ago

@ivanturlakov the "types" errors was expected after the runtime upgrade, it's necessary to upgrade the joystream-node after the Nara runtime upgrade. I have done that, please try again to access: https://65.108.208.60.nip.io/pioneer/#/settings?network-config=https://65.108.208.60.nip.io/network/config.json

freakstatic commented 9 months ago

@ivanturlakov also the expected council duration parameters is here: https://github.com/Joystream/joystream/issues/4866#issuecomment-1732561544 please update your tests results based on that

ivanturlakov commented 9 months ago

Tested on https://65.108.208.60.nip.io/pioneer/#/settings?network-config=https://65.108.208.60.nip.io/network/config.json

@freakstatic thank you! Works as expected 👍

Council Election Cycle

(Elect a council on Pioneer and confirm period lengths. This test will be performed on Testnet No.2 which is now in Nara after the Runtime upgrade from Ephesus to Nara test)

✅ Idle Period: 14 days = 201 600 blocks ✅ Announcing Period: 6 days = 86 400 blocks ✅ Voting Period: 4 days = 57 600 blocks ✅ Revealing Period: 4 days = 57 600 blocks

target 1s

Screenshot 2023-12-06 at 16 45 18
ivanturlakov commented 9 months ago

Tested on: Pioneer: https://65.21.109.54.nip.io/pioneer/#/proposals/past Atlas: https://65.21.109.54.nip.io/channel/

FreezePallet Proposal

freezePallet Proposal Executed

Screenshot 2023-12-14 at 15 38 53

✅ Attempting to create a token > Fail ⚠️ Attempting to buy/sell tokens > Links to channels and tokens => 404

Screenshot 2023-12-14 at 14 40 49 Screenshot 2023-12-14 at 14 46 06

UnFreezePallet Proposal Executed

Screenshot 2023-12-14 at 14 57 49

✅ Attempting to create a token > Success

switched to https://jsdao-nara-atlas.vercel.app/portfolio

Freeze again

Screenshot 2023-12-14 at 16 22 12

✅ Attempting to create a token > Fail

⚠️ Attempting to buy tokens > Success https://polkadot.js.org/apps/?rpc=wss://65.21.109.54.nip.io/ws-rpc#/explorer/query/0xff4f43177bcfd8da57028859100bb087e863c89998be5f02e6a72b729e34f919

Screenshot 2023-12-14 at 16 12 45

⚠️ Attempting to sell tokens > Success https://polkadot.js.org/apps/?rpc=wss://65.21.109.54.nip.io/ws-rpc#/explorer/query/0xed1271870a2e6d6e0c46454dda58db109153a1fe0a619f69794109a462927eb1

Screenshot 2023-12-14 at 16 14 19
ivanturlakov commented 9 months ago

freezePallet Proposal view does not allow us to understand which exact action is proposed - ON/OFF would be good to show a widget

Screenshot 2023-12-14 at 15 43 17
ivanturlakov commented 9 months ago

Tested on https://65.21.109.54.nip.io/pioneer/#/proposals/past

freezePallet Proposal Specific parameters

The toggle button is a bit confusing, maybe we should replace it with a:

Current flow

Current Status - Disabled I am trying to - Enable

Specific parameters default state - Disable, Create Proposal button is active(result will be the Proposal with the opposite state)

Screenshot 2023-12-22 at 15 21 34

If I toggle to Enable

Screenshot 2023-12-22 at 15 24 25

⚠️ Observation: no matter of toggle btn state result will be the Proposal with the opposite state, and always executes

ivanturlakov commented 8 months ago

FreezePallet Proposal retest

Atlas https://65.21.109.54.nip.io/ Dev Testnet

Pioneer https://65.21.109.54.nip.io/pioneer/#/settings wss://65.21.109.54.nip.io/ws-rpc

# Enabled Pallet Disabled Pallet
Create Channel ✅ Success ✅ Success
Create Token ✅ Success ✅ Fail
Buy Token ✅ Success ✅ Fail
Sell Token ✅ Success ⚠️ Token page error
Start Revenue Share ✅ Success ✅ Fail
Portfolio > Claim Your Share ⚠️ Button Inactive ⚠️ Button Inactive
Token Page > Stake/Claim Share ⚠️ Token page error ⚠️ Token page error

⚠️ Means there is no possibility to testMeans expected result

Token page(if it was bought at least once) opens with an error

Screenshot 2024-01-22 at 15 59 29