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

Improve connection speed/reliability and add more logging around connections #2550

Draft
wants to merge 48 commits into
base: develop
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
bc34b16
Fix: Not initializing on reconnection when general channel was delete…
Apr 4, 2024
0e587b1
Publish
Apr 4, 2024
7786e26
Update packages CHANGELOG.md
Apr 4, 2024
c35ec3c
fix: hanging process functionality killing wrong processes (#2419)
Apr 8, 2024
595d896
fix: Adds a quick fix for the iOS sync issue after suspend (#2414)
Apr 8, 2024
c089c68
fix: Remove unused dmPublicKey to prevent UI delay during joining (#2…
Apr 10, 2024
7855f00
refactor: Remove SET_COMMUNITY_METADATA event (#2408)
Apr 10, 2024
e4f945f
Better peer sorting and updated initial diallng (#2427)
Apr 12, 2024
a7ca0df
Remove only (#2429)
Apr 12, 2024
3929124
Publish
Apr 12, 2024
ef0e2c6
Update packages CHANGELOG.md
Apr 12, 2024
2aa2e3e
fix: Wait for community data in registerUsernameSaga (#2444)
Apr 15, 2024
9f04bdf
fix: Wait for channels to be initialized before sending messages (#2448)
Apr 16, 2024
b3eb281
Publish
Apr 16, 2024
ce027b2
Update packages CHANGELOG.md
Apr 16, 2024
0966478
Fix(2321): No Duplicate CSRs (#2460)
Apr 18, 2024
87ed565
fix: postpone restore connection saga (#2462)
siepra Apr 19, 2024
e2f0204
fix: change ci emulator name configuration (#2463)
siepra Apr 19, 2024
2af0531
fix: Various fixes related to peers, CSRs and backend startup (#2455)
Apr 29, 2024
2ad2778
Publish
Apr 30, 2024
5e5e2fc
Update packages CHANGELOG.md
Apr 30, 2024
d3b822b
fix: start websocket connection on react init (#2481)
siepra May 6, 2024
00a0605
Fix(2424): Fix issue with connecting on resume on ios (#2506)
May 6, 2024
47b7550
chore: improve self hosted runner (Detox) (#2453)
siepra Apr 24, 2024
2c11121
Fix(2496): Random fixes for leave community on mobile (#2498)
May 7, 2024
dde5d34
Update required contextual actions to run and exit early when no rele…
May 7, 2024
0495c38
Publish
May 8, 2024
e5c7559
Update packages CHANGELOG.md
May 8, 2024
6225d97
Create utils-tests.yml
islathehut May 9, 2024
bcbc20a
Revert "Create utils-tests.yml"
islathehut May 9, 2024
c51d29a
Chore: Use macos-12 on 2.2.0 (#2515)
May 9, 2024
134fbcb
fix: Reorder the closing of services, prevent sagas running multiple …
May 9, 2024
c317ffb
Fix queue processing (#2525)
May 13, 2024
c293ccb
Publish
May 14, 2024
18d5e7d
Update packages CHANGELOG.md
May 14, 2024
c24c730
Use xcode 15 to get ios 17 sdk on builds (#2535)
May 16, 2024
da26e8a
Publish
May 16, 2024
d20f2b6
Update packages CHANGELOG.md
May 16, 2024
40b0c4d
Wait to dial peers until tor is fully connected, attempt to deduplica…
islathehut May 17, 2024
4fe11c4
Better deduplication
islathehut May 17, 2024
b46934e
Add packages that error out on bootstrap
islathehut May 17, 2024
f5c63b4
Add extra libp2p logging
islathehut May 17, 2024
c726a9c
Update max dials and tie together chunksize and maxparalleldials
islathehut May 17, 2024
7f1bce6
More logging and improvements to connections
islathehut May 17, 2024
75818c8
Code consolidation
islathehut May 17, 2024
c9c7836
Use CryptoJS import for MD5
islathehut May 17, 2024
97719b2
Fix tests
islathehut May 17, 2024
c745690
Tor improvements and better test fix
islathehut May 23, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .github/actions/setup-env/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,21 @@ runs:
- uses: actions/setup-node@master
with:
node-version: 18.12.1

- name: Set up Python 3.12
uses: actions/setup-python@v5
if: runner.os == 'macOS'
with:
python-version: 3.12

- name: Print python version
run: which python3
if: runner.os == 'macOS'
shell: bash

- name: Install setuptools
run: python3 -m pip install setuptools
shell: bash

- name: Print OS name
run: echo ${{ runner.os }}
Expand Down
52 changes: 49 additions & 3 deletions .github/workflows/backend-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,29 +2,43 @@ name: Backend unit tests

on:
pull_request:
paths:
- packages/backend/**

jobs:
unit-tests:
runs-on: ${{ matrix.os }}

strategy:
matrix:
os: [ubuntu-20.04, macos-latest, windows-2019]
os: [ubuntu-20.04, macos-12, windows-2019]

steps:
- uses: dorny/paths-filter@v3
id: filter
with:
filters: |
backend:
- 'packages/backend/**'
- name: "Skip tests"
if: steps.filter.outputs.backend == 'false'
run: |
echo "Skipping test run"
exit 0

- name: "Print OS"
if: steps.filter.outputs.backend == 'true'
run: echo ${{ matrix.os }}

- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
if: steps.filter.outputs.backend == 'true'

- name: "Setup environment"
if: steps.filter.outputs.backend == 'true'
uses: ./.github/actions/setup-env
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,backend-bundle"

- name: "Unit tests"
if: steps.filter.outputs.backend == 'true'
run: lerna run test-ci --scope @quiet/backend --stream

long-running-tests:
Expand All @@ -35,17 +49,33 @@ jobs:
os: [ubuntu-20.04]

steps:
- uses: dorny/paths-filter@v3
id: filter
with:
filters: |
backend:
- 'packages/backend/**'
- name: "Skip tests"
if: steps.filter.outputs.backend == 'false'
run: |
echo "Skipping test run"
exit 0

- name: "Print OS"
if: steps.filter.outputs.backend == 'true'
run: echo ${{ matrix.os }}

- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
if: steps.filter.outputs.backend == 'true'

- name: "Setup environment"
if: steps.filter.outputs.backend == 'true'
uses: ./.github/actions/setup-env
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,backend-bundle"

- name: "Unit tests"
if: steps.filter.outputs.backend == 'true'
run: lerna run test-ci-long-running --scope @quiet/backend --stream

unit-tests-with-tor:
Expand All @@ -56,15 +86,31 @@ jobs:
os: [ubuntu-20.04]

steps:
- uses: dorny/paths-filter@v3
id: filter
with:
filters: |
backend:
- 'packages/backend/**'
- name: "Skip tests"
if: steps.filter.outputs.backend == 'false'
run: |
echo "Skipping test run"
exit 0

- name: "Print OS"
if: steps.filter.outputs.backend == 'true'
run: echo ${{ matrix.os }}

- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
if: steps.filter.outputs.backend == 'true'

- name: "Setup environment"
if: steps.filter.outputs.backend == 'true'
uses: ./.github/actions/setup-env
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,backend-bundle"

- name: "Unit tests"
if: steps.filter.outputs.backend == 'true'
run: lerna run test-ci-tor --scope @quiet/backend --stream
18 changes: 16 additions & 2 deletions .github/workflows/check-desktop-visual-regression.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ name: Desktop visual regressions

on:
pull_request:
paths:
- packages/desktop/**

jobs:
chromatic-deployment:
Expand All @@ -14,20 +12,36 @@ jobs:
os: [ubuntu-20.04]

steps:
- uses: dorny/paths-filter@v3
id: filter
with:
filters: |
desktop:
- 'packages/desktop/**'
- name: "Skip tests"
if: steps.filter.outputs.desktop == 'false'
run: |
echo "Skipping test run"
exit 0

- name: "Print OS"
if: steps.filter.outputs.desktop == 'true'
run: echo ${{ matrix.os }}

- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
if: steps.filter.outputs.desktop == 'true'
with:
fetch-depth: 0 # Required to retrieve git history

- name: Setup environment
uses: ./.github/actions/setup-env
if: steps.filter.outputs.desktop == 'true'
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle"

- name: "Publish to Chromatic"
uses: chromaui/action@355e2a05a179e9e89c2b237dcd55adbeb89e577e # v1
if: steps.filter.outputs.desktop == 'true'
with:
workingDir: ./packages/desktop
token: ${{ secrets.GH_TOKEN }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/desktop-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ jobs:

build-macos:
# needs: run-e2e-tests-mac
runs-on: macos-latest
runs-on: macos-12
if: |
startsWith(github.ref, 'refs/tags/@quiet/desktop')

Expand Down
22 changes: 18 additions & 4 deletions .github/workflows/desktop-rtl-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@ name: Desktop - state-manager bracket tests (RTL)

on:
pull_request:
paths:
- packages/desktop/**
- packages/state-manager/**

jobs:
desktop-tests:
Expand All @@ -13,19 +10,36 @@ jobs:

strategy:
matrix:
os: [ubuntu-20.04, macos-latest]
os: [ubuntu-20.04, macos-12]

steps:
- uses: dorny/paths-filter@v3
id: filter
with:
filters: |
validFiles:
- 'packages/desktop/**'
- 'packages/state-manger/**'
- name: "Skip tests"
if: steps.filter.outputs.validFiles == 'false'
run: |
echo "Skipping test run"
exit 0

- name: "Print OS"
if: steps.filter.outputs.validFiles == 'true'
run: echo ${{ matrix.os }}

- uses: actions/checkout@v3
if: steps.filter.outputs.validFiles == 'true'

- name: "Setup environment"
uses: ./.github/actions/setup-env
if: steps.filter.outputs.validFiles == 'true'
with:
cachePrefix: "desktop-tests"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle"

- name: "Desktop - state-manager bracket tests"
if: steps.filter.outputs.validFiles == 'true'
run: lerna run rtl-test --scope @quiet/desktop --stream
22 changes: 19 additions & 3 deletions .github/workflows/desktop-test-scroll.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ name: Desktop scroll regression tests

on:
pull_request:
paths:
- packages/desktop/**

jobs:
regression-tests:
Expand All @@ -15,31 +13,49 @@ jobs:
os: [ubuntu-20.04]

steps:
- uses: dorny/paths-filter@v3
id: filter
with:
filters: |
desktop:
- 'packages/desktop/**'
- name: "Skip tests"
if: steps.filter.outputs.desktop == 'false'
run: |
echo "Skipping test run"
exit 0

- name: "Print OS"
if: steps.filter.outputs.desktop == 'true'
run: echo ${{ matrix.os }}

- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
if: steps.filter.outputs.desktop == 'true'

- name: Setup environment
uses: ./.github/actions/setup-env
if: steps.filter.outputs.desktop == 'true'
with:
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle"

- name: "Install libs"
if: steps.filter.outputs.desktop == 'true'
run: sudo apt-get update && sudo apt-get install -y libgtk2.0-0 libgtk-3-0 libnotify-dev libgconf-2-4 libnss3 libxss1 libasound2 libxtst6 xauth xvfb

- name: "Remove test files workaround"
if: steps.filter.outputs.desktop == 'true'
run: find packages/desktop/src -name '*.test.*' -delete && find packages/backend/src -name '*.test.*' -delete

- uses: cypress-io/github-action@1b70233146622b69e789ccdd4f9452adc638d25a # v6.6.1
if: steps.filter.outputs.desktop == 'true'
with:
install: false
command: npm run regression-test:ci
working-directory: packages/desktop

- name: Archive test screenshots
if: steps.filter.outputs.desktop == 'true'
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
if: always()
with:
name: test-screenshots-linux
path: packages/desktop/cypress/snapshots
20 changes: 17 additions & 3 deletions .github/workflows/desktop-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ name: Desktop tests

on:
pull_request:
paths:
- packages/desktop/**

jobs:
desktop-tests:
Expand All @@ -12,19 +10,35 @@ jobs:

strategy:
matrix:
os: [ubuntu-20.04, macos-latest]
os: [ubuntu-20.04, macos-12]

steps:
- uses: dorny/paths-filter@v3
id: filter
with:
filters: |
desktop:
- 'packages/desktop/**'
- name: "Skip tests"
if: steps.filter.outputs.desktop == 'false'
run: |
echo "Skipping test run"
exit 0

- name: "Print OS"
if: steps.filter.outputs.desktop == 'true'
run: echo ${{ matrix.os }}

- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
if: steps.filter.outputs.desktop == 'true'

- name: "Setup environment"
uses: ./.github/actions/setup-env
if: steps.filter.outputs.desktop == 'true'
with:
cachePrefix: "desktop-tests"
bootstrap-packages: "@quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/desktop,backend-bundle"

- name: "Unit tests"
if: steps.filter.outputs.desktop == 'true'
run: lerna run test --scope @quiet/desktop --stream
11 changes: 4 additions & 7 deletions .github/workflows/e2e-android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,22 +10,19 @@ on:

jobs:
detox-android:
timeout-minutes: 10
runs-on: [self-hosted, macOS, ARM64, android]
timeout-minutes: 25
runs-on: [macos-14-xlarge]

steps:
- uses: actions/checkout@v4
with:
lfs: true

- name: Install dependencies
run: |
npm i
npm run lerna bootstrap --scope @quiet/eslint-config,@quiet/logger,@quiet/common,@quiet/types,@quiet/state-manager,@quiet/backend,@quiet/identity,@quiet/mobile,backend-bundle

- name: Pull binaries
run: |
git lfs install
git lfs pull

- name: Pass local config
run : |
cat << EOF >> packages/mobile/android/local.properties
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/e2e-crossplatform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:
- packages/state-manager/**
- packages/identity/**
- packages/common/**
- .github/workflows/e2e**

jobs:
mac:
Expand Down
Loading
Loading