Skip to content

Commit

Permalink
Merge branch 'develop' of github.com:rainbow-me/rainbow into brody/ch…
Browse files Browse the repository at this point in the history
…ecks-language

* 'develop' of github.com:rainbow-me/rainbow: (100 commits)
  [WIP]: Swaps v2 quote fetching (#5601)
  chore: app start up spring cleaning (#5622)
  fix remote config (#5627)
  would it kill you to log this only once (#5626)
  Recents (#5625)
  wc: improvements (#5616)
  Degen chain support (#5621)
  send: check contract address (#5586)
  tx requests: metadata (#5584)
  audit: phin (#5624)
  Fix: Wallets being marked as backed up by walletLoadState() (#5593)
  NFTs: filter instead of throw error when NFT has invalid network (#5537)
  Dapp Browser: Search (#5617)
  Browser: bug fixes, animation and UI improvements (#5618)
  cleanup file imports and duplicate types (#5619)
  requests: generalize analytics (#5589)
  browser: account icon clean up (#5612)
  Fix no tab and links (#5613)
  more e2e changes (#5558)
  . (#5615)
  ...
  • Loading branch information
BrodyHughes committed Apr 17, 2024
2 parents f14b30d + 5d91d5e commit 402d75c
Show file tree
Hide file tree
Showing 509 changed files with 27,366 additions and 56,676 deletions.
14 changes: 10 additions & 4 deletions .detoxrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ module.exports = {
_: ['e2e'],
},
},

devices: {
'ios.simulator': {
type: 'ios.simulator',
Expand All @@ -23,7 +22,6 @@ module.exports = {
device: { avdName: 'Pixel_7_Pro_API_34' },
},
},

apps: {
'ios.release': {
type: 'ios.app',
Expand All @@ -48,17 +46,25 @@ module.exports = {
build: 'cd ./android && ./gradlew assembleDebug assembleAndroidTest -DtestBuildType=debug && cd ..',
},
},

configurations: {
'ios.sim.release': {
app: 'ios.release',
device: 'ios.simulator',
artifacts: {
plugins: {
screenshot: 'failing',
},
},
},
'ios.sim.debug': {
app: 'ios.debug',
device: 'ios.simulator',
artifacts: {
plugins: {
screenshot: 'failing',
},
},
},

'android.emu.release': {
app: 'android.release',
device: 'android.emulator',
Expand Down
5 changes: 4 additions & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ src/react-native-animated-charts/Example/node_modules/*
src/react-native-animated-charts/Example/*
patches/reanimated/*
ios/*
android/*
node_modules/*
./node_modules/**
**/node_modules/*
Expand All @@ -15,4 +16,6 @@ jest.config.js
.detoxrc.js
__generated__
coverage
src/browser
src/browser
src/__swaps__/README.md
InjectedJSBundle.js
2 changes: 2 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,5 +37,7 @@ module.exports = {
],
},
],
'jest/expect-expect': 'off',
'jest/no-disabled-tests': 'off',
},
};
26 changes: 15 additions & 11 deletions .github/workflows/macstadium-clear-cache-all-instances.yml
Original file line number Diff line number Diff line change
@@ -1,36 +1,40 @@
# This is a basic workflow to help you get started with Actions

name: Clear macstadium cache (All instances)

# Controls when the workflow will run
on: [ workflow_dispatch]

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
clear-cache-ci-1:
runs-on: ["CI-1"]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ./.github/actions/clear-cache
clear-cache-ci-2:
runs-on: ["CI-2"]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ./.github/actions/clear-cache
clear-cache-ci-3:
runs-on: ["CI-3"]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ./.github/actions/clear-cache
clear-cache-ci-4:
runs-on: ["CI-4"]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ./.github/actions/clear-cache
clear-cache-ci-5:
runs-on: ["CI-5"]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: ./.github/actions/clear-cache
clear-cache-ci-6:
runs-on: ["CI-6"]
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/clear-cache
clear-cache-ci-7:
runs-on: ["CI-7"]
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/clear-cache


42 changes: 21 additions & 21 deletions .github/workflows/macstadium-e2e.yml
Original file line number Diff line number Diff line change
@@ -1,47 +1,35 @@
# This is a basic workflow to help you get started with Actions

name: iOS e2e tests

# Controls when the workflow will run
on: [pull_request, workflow_dispatch]

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "ios-e2e"
ios-e2e:
# The type of runner that the job will run on
runs-on: ["self-hosted"]
# Cancel current builds if there's a newer commit on the same branch
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Set up github keys
run: echo 'hi 00' && git config core.sshCommand "ssh -i ~/.ssh/id_ed25519 -F /dev/null" && echo 'hi 0'
run: git config core.sshCommand "ssh -i ~/.ssh/id_ed25519 -F /dev/null"

- name: clean ios app step
run: yarn clean:ios > /dev/null 2>&1 || true

- name: Set up ENV vars & scripts
run: |
# read local env vars
echo 'hi'
source ~/.bashrc
echo 'hi 1'
# fetch env vars
git clone git@github.com:rainbow-me/rainbow-env.git
echo '2'
# unpack dotenv
mv rainbow-env/dotenv .env && rm -rf rainbow-env
# run CI scripts
echo 'hi 3'
eval $CI_SCRIPTS
echo 'hi 4'
# tweak dotenv for e2e
sed -i''-e "s/\IS_TESTING=false/IS_TESTING=true/" .env && rm -f .env-e
echo 'hi 5'
- name: Install deps via Yarn
run: yarn setup-ci

Expand All @@ -55,13 +43,25 @@ jobs:
run: yarn lint:ci

- name: Install Pods
run: cd ios && bundle install && pod install --repo-update && cd ..
run: yarn install-pods

- name: Rebuild detox cache
run: ./node_modules/.bin/detox clean-framework-cache && ./node_modules/.bin/detox build-framework-cache

- name: Build the app in Release mode
- name: Remove old Detox artifacts
run: rm -rf ./artifacts/

- name: Build the app in release mode
run: ./node_modules/.bin/detox build --configuration ios.sim.release

- name: Run iOS e2e tests with retry
# change the '5' here to how many times you want the tests to rerun on failure
run: ./scripts/run-retry-tests.sh 5

- name: Upload Test Artifacts
if: failure()
uses: actions/upload-artifact@v3
with:
name: detox-artifacts
path: artifacts/**

- name: Run iOS e2e tests
run: ./node_modules/.bin/detox test -R 5 --configuration ios.sim.release --forceExit --bail
9 changes: 6 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ src/screens/ExamplePage.js

#e2e output
e2e/logs/*/*.xml
artifacts/*

# android playstore credentials
pc-api-8090318172169087080-31-b8ee34328314.json
Expand All @@ -91,8 +92,7 @@ ios/Extras.json
rainbow-scripts

# Patches
patches/react-native-webview+13.2.3.patch
patches/react-native-webview+13.7.0.patch
patches/react-native-webview*

.eslintcache

Expand All @@ -114,5 +114,8 @@ coverage
# VSCode
.vscode/

# Zed
.zed/

# Webpack
src/browser/InjectedJSBundle.js.LICENSE.txt
InjectedJSBundle.js.LICENSE.txt
2 changes: 1 addition & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ rainbow-scripts
.vscode
__generated__
coverage
src/browser/InjectedJSBundle.js
InjectedJSBundle.js
58 changes: 57 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,68 @@ and this project adheres to [Semantic Versioning](http://semver.org/)

### Fixed

## [1.9.20] (https://github.com/rainbow-me/rainbow/releases/tag/v1.9.20)

### Added

- Added pending transaction indicator on nav bar (#5529)
- Swaps v2 revamp work (#5536, #5538)
- Added wallet connect v2 sessions data to state dump (#5382)

### Changed

- e2e cleanup (#5540)
- NFT offers/mints gas estimation improvements (#5448)
- Removed Apollo client in favor of @/graphql (#5555)
- Refetch balances after a transaction is confirmed (#5551)
- Hide favorites on non mainnet assets (#5565)
- Updated transaction details sheet (#5535)
- Bump Rudderstack version to v1.12.12 (#5556)
- Backups v2 (#5310)

### Fixed

- Fixed a crash that happened when tapping settings button on develop (#5544)
- Fixed token metadata issues for searching by contract address in discover (#5563)

## [1.9.19] (https://github.com/rainbow-me/rainbow/releases/tag/v1.9.19)

### Added

- Added Blast to simplehash (#5492)
- Initialize new swaps configuration (#5498)
- Initial swaps work (#5500)

### Changed

- Swipe navigator performance refactor (#5479)
- Transaction and assets cleanup (#5459)
- Migrated query persist from AsyncStorage to mmkv (#5404, #5524)
- Webview refactor (#5499)
- Replaced Segment (#5474)
- Low fee's on first estimate (#5503)
- Upgraded reservoir (#5514)
- Bump reanimated to v3.8.0 (#5517)
- Changed default theme from light to system (#5518)
- Updated logic for wallet connect SignTransactionSheet (#5471)

### Fixed

- Fixed reanimated and RNGH imports (#5480)
- Fixed layout shift for mints carousel card (#5485)
- Fixed android clipboard alerts (#5486)
- Fixed weekly earnings points breakdown (#5469)
- Fixed tappable area on wallet name (#5496)
- Fixed null deconstruction for wallet connect (#5493)
- Fixed dark mode theme which impacted ENS confirmation screen (#5502)
- Fixed initiating render on NFT offers (#5501)

## [1.9.18] (https://github.com/rainbow-me/rainbow/releases/tag/v1.9.18)

### Added

- Added ability to report NFT as spam to simplehash (#5434)
- Added fallback icons for contract interactions where we may not have nft images (#5456)
- Added fallback icons for contract interactions where we may not have nft images (#5456)
- Added support for Avalanche (#5430)
- Added support for Blast (#5463)

Expand Down
6 changes: 6 additions & 0 deletions CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -63,3 +63,9 @@ src/App.js @benisgold @skylarbarrera @jinchung
metro.config.js @skylarbarrera @benisgold
metro.transform.js @skylarbarrera @benisgold
react-native.config.js @skylarbarrera @benisgold

# DAPP BROWSER
src/browser @brunobar79 @skylarbarrera @benisgold
src/screens/dapp-browser @brunobar79 @skylarbarrera @benisgold
src/components/DappBrowser @brunobar79 @skylarbarrera @benisgold

2 changes: 2 additions & 0 deletions InjectedJSBundle.js

Large diffs are not rendered by default.

8 changes: 2 additions & 6 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ apply plugin: "com.facebook.react"


apply from: "../../node_modules/@sentry/react-native/sentry.gradle"
apply from: "../../node_modules/react-native-code-push/android/codepush.gradle"

react {
/* Folders */
Expand Down Expand Up @@ -146,14 +145,11 @@ android {

namespace 'me.rainbow'
defaultConfig {
// https://github.com/microsoft/react-native-code-push/issues/1961#issuecomment-710698621
resValue 'string', "CODE_PUSH_APK_BUILD_TIME", String.format("\"%d\"", System.currentTimeMillis())
resValue 'string', "CodePushDeploymentKey", env.get('CODE_PUSH_DEPLOYMENT_KEY_ANDROID')
applicationId "me.rainbow"
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 207
versionName "1.9.19"
versionCode 209
versionName "1.9.21"
missingDimensionStrategy 'react-native-camera', 'general'
renderscriptTargetApi 23
renderscriptSupportModeEnabled true
Expand Down
6 changes: 0 additions & 6 deletions android/app/src/main/java/me/rainbow/MainApplication.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
import me.rainbow.NativeModules.RNStartTime.RNStartTimePackage;
import me.rainbow.NativeModules.RNTextAnimatorPackage.RNTextAnimatorPackage;
import me.rainbow.NativeModules.RNZoomableButton.RNZoomableButtonPackage;
import com.microsoft.codepush.react.CodePush;
import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint;
import com.facebook.react.defaults.DefaultReactNativeHost;
import me.rainbow.BuildConfig;
Expand All @@ -42,11 +41,6 @@ public boolean getUseDeveloperSupport() {
return BuildConfig.DEBUG;
}

@Override
protected String getJSBundleFile() {
return CodePush.getJSBundleFile();
}

@Override
protected List<ReactPackage> getPackages() {
@SuppressWarnings("UnnecessaryLocalVariable")
Expand Down
2 changes: 2 additions & 0 deletions android/app/src/main/res/raw/injected_js_bundle.js

Large diffs are not rendered by default.

3 changes: 0 additions & 3 deletions android/settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@ project(':react-native-exit-app').projectDir = new File(rootProject.projectDir,
apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings)
include ':app'

include ':app', ':react-native-code-push'
project(':react-native-code-push').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-code-push/android/app')

/*include ':detox'
project(':detox').projectDir = new File(rootProject.projectDir, '../node_modules/detox/android/detox')
*/
Expand Down
5 changes: 2 additions & 3 deletions config/test/jest-setup.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-undef */
// needed to set up global translations
/* eslint-disable no-nested-ternary */
import '../../src/languages';

global.ios = false;
Expand All @@ -17,7 +16,7 @@ jest.mock('react-native-device-info', () => ({
setup: () => null,
}));

jest.mock('@segment/analytics-react-native', () => ({
jest.mock('@rudderstack/rudder-sdk-react-native', () => ({
createClient: jest.fn(),
identify: jest.fn(),
reset: jest.fn(),
Expand Down

0 comments on commit 402d75c

Please sign in to comment.