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

Rc/8.7.0 #1675

Merged
merged 32 commits into from
Oct 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
dcfc1c5
Merge pull request #1636 from novasamatech/master
valentunn Aug 21, 2024
9bd2e3f
Working build instructions (#1642)
valentunn Aug 26, 2024
f553140
Fix MD formatting (#1643)
valentunn Aug 26, 2024
39f010a
Update README.md
valentunn Aug 26, 2024
9723eaf
Fix CI
valentunn Aug 30, 2024
21809c7
Merge pull request #1647 from novasamatech/fix/ci
antonijzelinskij Aug 30, 2024
6bfbb8e
Bump substrate lib version
antonijzelinskij Sep 3, 2024
42179dc
Merge pull request #1649 from novasamatech/fix/substrate-lib-version
antonijzelinskij Sep 4, 2024
86dd3e8
set format to html (#1655)
stepanLav Sep 16, 2024
3d83a30
Base tindergov (#1656)
antonijzelinskij Sep 17, 2024
9befa65
Fix/tinder gov bug fix (#1658)
antonijzelinskij Sep 19, 2024
bc181c8
Fixed voting list bugs
antonijzelinskij Sep 19, 2024
018d534
feat: adding POLKASSEMBLY_SUMMARY_API_KEY (#1664)
stepanLav Sep 19, 2024
997dadf
Awaite while all voted referenda update their state to voted
antonijzelinskij Sep 19, 2024
e6726bc
Update AssetSearchInteractor.kt (#1662)
antonijzelinskij Sep 19, 2024
4ff73cd
Merge pull request #1663 from novasamatech/fix/swipe-gov-vote-list
antonijzelinskij Sep 19, 2024
3970dea
Fixed negative amount in failure
antonijzelinskij Sep 19, 2024
fccb326
Merge pull request #1665 from novasamatech/fix/swipe-gov-update-refer…
antonijzelinskij Sep 19, 2024
88ac696
Merge pull request #1666 from novasamatech/fix/negative-amount-in-fai…
antonijzelinskij Sep 19, 2024
4e7baec
Added confirm state for placeholder
antonijzelinskij Sep 19, 2024
493cb19
Merge pull request #1667 from novasamatech/fix/confirm-placeholder-state
antonijzelinskij Sep 19, 2024
2ed4580
SwipeGov: Fixed revalidation after use max
antonijzelinskij Sep 20, 2024
7bed410
Update text resources
antonijzelinskij Sep 20, 2024
93ff83d
Merge pull request #1668 from novasamatech/fix/use-max-for-revalidate…
antonijzelinskij Sep 20, 2024
e658f23
Merge pull request #1669 from novasamatech/fix/swipe-gov-text
antonijzelinskij Sep 20, 2024
e44a049
Fix/abstain votes constant loading (#1670)
antonijzelinskij Sep 23, 2024
1494cde
Treasury spend support (#1671)
valentunn Sep 24, 2024
d9c5aa3
Add SwipeGov localisation (#1672)
leohar Sep 25, 2024
e07cfe3
Merge branch 'master' into master_dev
valentunn Sep 26, 2024
76d7695
Merge pull request #1674 from novasamatech/master_dev
valentunn Sep 26, 2024
8c997f9
Bump version
valentunn Sep 26, 2024
efd94b6
Merge pull request #1682 from novasamatech/feature/swipe-gov-backend
antonijzelinskij Oct 4, 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
2 changes: 2 additions & 0 deletions .github/workflows/android_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,8 @@ env:
CI_DEVELOP_GOOGLE_SERVICES_FILE: ${{ secrets.CI_DEVELOP_GOOGLE_SERVICES }}
CI_PRODUCTION_GOOGLE_SERVICES_FILE: ${{ secrets.CI_PRODUCTION_GOOGLE_SERVICES }}

POLKASSEMBLY_SUMMARY_API_KEY: ${{ secrets.POLKASSEMBLY_SUMMARY_API_KEY }}

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-${{inputs.upload-name}}
cancel-in-progress: true
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/balances_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ jobs:
with:
to: ${{ secrets.TELEGRAM_TO }}
token: ${{ secrets.TELEGRAM_TOKEN }}
format: markdown
format: html
message: |
💸 Balances tests failed.

Expand Down
59 changes: 59 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,65 @@ Next gen application for Polkadot & Kusama ecosystem, transparent & community-or
Nova Wallet aims to provide as many Polkadot ecosystem features as possible in a form of mobile app, unbiased to any network & without any restrictions/limits to the users.
Developed by the former Fearless Wallet team & based on open-source work under Apache 2.0 license.

### Build instructions

#### Clone repo

```
git clone git@github.com:novasamatech/nova-wallet-android.git
```

#### Install NDK

Instal NDK version `26.1.10909125` from SDK Manager by going to Tools -> SDK Mmanager -> Sdk Tools -> NDK (Side by Side)

#### Instal Rust

Install Rust by following [official instruction](https://www.rust-lang.org/tools/install). Use "Using rustup" option. On MacOS you can also install rust with [brew](https://formulae.brew.sh/formula/rust)

Run the following commands to add Android build targets to rustup:

```
rustup target add armv7-linux-androideabi
rustup target add i686-linux-android
rustup target add x86_64-linux-android
rustup target add aarch64-linux-android
```

#### Update local.properties

Add the following lines to your local.properties

```
ACALA_PROD_AUTH_TOKEN=mock
ACALA_TEST_AUTH_TOKEN=mock
CI_KEYSTORE_KEY_ALIAS=mock
CI_KEYSTORE_KEY_PASS=mock
CI_KEYSTORE_PASS=mock
DEBUG_GOOGLE_OAUTH_ID=mock
RELEASE_GOOGLE_OAUTH_ID=mock
DWELLIR_API_KEY=mock
EHTERSCAN_API_KEY_ETHEREUM=mock
EHTERSCAN_API_KEY_MOONBEAM=mock
EHTERSCAN_API_KEY_MOONRIVER=mock
INFURA_API_KEY=mock
MERCURYO_PRODUCTION_SECRET=mock
MERCURYO_TEST_SECRET=mock
MOONBEAM_PROD_AUTH_TOKEN=mock
MOONBEAM_TEST_AUTH_TOKEN=mock
MOONPAY_PRODUCTION_SECRET=mock
MOONPAY_TEST_SECRET=mock
WALLET_CONNECT_PROJECT_ID=mock
```
Note, that Firebase and Google related features (Notifications, Cloud Backups) wont work properly with this setup.

If you face `Secret X is not found` error, it means that README is not up-to-date. Add `X=mock` line to local.properties as well

#### Setup build type

In Nova Wallet, `debug` build type use fixed key, not publickly shared keystore to fix fingerprint to make Google-related features work
To use your local debug keystore switch to `debugLocal` build type.

## License
Nova Wallet Android is available under the Apache 2.0 license. See the LICENSE file for more info.
© Novasama Technologies GmbH 2023
9 changes: 8 additions & 1 deletion app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ android {
keyAlias readRawSecretOrNull('CI_KEYSTORE_KEY_ALIAS')
keyPassword readRawSecretOrNull('CI_KEYSTORE_KEY_PASS')
}
debug {
debugFixedKey {
storeFile file('develop_key.jks')
storePassword readRawSecretOrNull('CI_KEYSTORE_PASS')
keyAlias readRawSecretOrNull('CI_KEYSTORE_KEY_ALIAS')
Expand All @@ -46,11 +46,18 @@ android {
}
buildTypes {
debug {
signingConfig signingConfigs.debugFixedKey

applicationIdSuffix '.debug'
versionNameSuffix '-debug'

buildConfigField "String", "BuildType", "\"debug\""
}
debugLocal {
initWith buildTypes.debug
matchingFallbacks = ['debug']
signingConfig signingConfigs.debug
}
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@ import io.novafoundation.nova.app.root.navigation.NavigationHolder
import io.novafoundation.nova.app.root.navigation.Navigator
import io.novafoundation.nova.app.root.navigation.governance.GovernanceNavigator
import io.novafoundation.nova.app.root.navigation.governance.SelectTracksCommunicatorImpl
import io.novafoundation.nova.app.root.navigation.governance.TinderGovVoteCommunicatorImpl
import io.novafoundation.nova.common.di.scope.ApplicationScope
import io.novafoundation.nova.feature_account_api.presenatation.account.wallet.list.SelectTracksCommunicator
import io.novafoundation.nova.feature_governance_impl.presentation.GovernanceRouter
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.setup.tindergov.TinderGovVoteCommunicator

@Module
class GovernanceNavigationModule {
Expand All @@ -26,4 +28,11 @@ class GovernanceNavigationModule {
router: GovernanceRouter,
navigationHolder: NavigationHolder
): SelectTracksCommunicator = SelectTracksCommunicatorImpl(router, navigationHolder)

@Provides
@ApplicationScope
fun provideTinderGovVoteCommunicator(
router: GovernanceRouter,
navigationHolder: NavigationHolder
): TinderGovVoteCommunicator = TinderGovVoteCommunicatorImpl(router, navigationHolder)
}
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,14 @@ import io.novafoundation.nova.feature_governance_impl.presentation.delegation.de
import io.novafoundation.nova.feature_governance_impl.presentation.delegation.delegation.revoke.confirm.RevokeDelegationConfirmPayload
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.details.ReferendumDetailsFragment
import io.novafoundation.nova.feature_governance_api.presentation.referenda.details.ReferendumDetailsPayload
import io.novafoundation.nova.feature_governance_impl.presentation.common.info.ReferendumInfoFragment
import io.novafoundation.nova.feature_governance_impl.presentation.common.info.ReferendumInfoPayload
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.full.ReferendumFullDetailsFragment
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.full.ReferendumFullDetailsPayload
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.confirm.ConfirmReferendumVoteFragment
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.confirm.ConfirmVoteReferendumPayload
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.setup.SetupVoteReferendumFragment
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.setup.SetupVoteReferendumPayload
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.setup.common.SetupVoteFragment
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.setup.common.SetupVotePayload
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.voters.ReferendumVotersFragment
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.voters.ReferendumVotersPayload

Expand Down Expand Up @@ -65,9 +67,14 @@ class GovernanceNavigator(
args = ReferendumVotersFragment.getBundle(payload)
)

override fun openSetupVoteReferendum(payload: SetupVoteReferendumPayload) = performNavigation(
override fun openSetupReferendumVote(payload: SetupVotePayload) = performNavigation(
actionId = R.id.action_referendumDetailsFragment_to_setupVoteReferendumFragment,
args = SetupVoteReferendumFragment.getBundle(payload)
args = SetupVoteFragment.getBundle(payload)
)

override fun openSetupTinderGovVote(payload: SetupVotePayload) = performNavigation(
actionId = R.id.action_tinderGovCards_to_setupTinderGovVoteFragment,
args = SetupVoteFragment.getBundle(payload)
)

override fun backToReferendumDetails() = performNavigation(R.id.action_confirmReferendumVote_to_referendumDetailsFragment)
Expand Down Expand Up @@ -122,6 +129,30 @@ class GovernanceNavigator(
performNavigation(R.id.action_open_select_governance_tracks, args = bundle)
}

override fun openTinderGovCards() {
performNavigation(R.id.action_openTinderGovCards)
}

override fun openTinderGovBasket() {
performNavigation(R.id.action_tinderGovCards_to_tinderGovBasket)
}

override fun openConfirmTinderGovVote() {
performNavigation(R.id.action_setupTinderGovBasket_to_confirmTinderGovVote)
}

override fun backToTinderGovCards() = performNavigation(
actionId = R.id.action_confirmTinderGovVote_to_tinderGovCards
)

override fun openReferendumInfo(payload: ReferendumInfoPayload) = performNavigation(
cases = arrayOf(
R.id.tinderGovCards to R.id.action_tinderGovCards_to_referendumInfo,
R.id.setupTinderGovBasketFragment to R.id.action_setupTinderGovBasket_to_referendumInfo
),
args = ReferendumInfoFragment.getBundle(payload)
)

override fun openReferendaSearch() {
performNavigation(R.id.action_open_referenda_search)
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
package io.novafoundation.nova.app.root.navigation.governance

import io.novafoundation.nova.app.root.navigation.NavStackInterScreenCommunicator
import io.novafoundation.nova.app.root.navigation.NavigationHolder
import io.novafoundation.nova.common.sequrity.verification.PinCodeTwoFactorVerificationResponder.Response
import io.novafoundation.nova.feature_governance_impl.presentation.GovernanceRouter
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.setup.common.SetupVotePayload
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.setup.tindergov.TinderGovVoteCommunicator
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.setup.tindergov.TinderGovVoteRequester
import io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.setup.tindergov.TinderGovVoteResponder
import kotlinx.coroutines.flow.Flow

class TinderGovVoteCommunicatorImpl(private val router: GovernanceRouter, navigationHolder: NavigationHolder) :
NavStackInterScreenCommunicator<TinderGovVoteRequester.Request, TinderGovVoteResponder.Response>(navigationHolder),
TinderGovVoteCommunicator {

override val responseFlow: Flow<TinderGovVoteResponder.Response>
get() = clearedResponseFlow()

override fun openRequest(request: TinderGovVoteRequester.Request) {
super.openRequest(request)

router.openSetupTinderGovVote(SetupVotePayload(request.referendumId))
}
}
10 changes: 10 additions & 0 deletions app/src/main/res/navigation/main_nav_graph.xml
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,14 @@
app:popEnterAnim="@anim/fragment_close_enter"
app:popExitAnim="@anim/fragment_close_exit" />

<action
android:id="@+id/action_openTinderGovCards"
app:destination="@id/tinder_gov_graph"
app:enterAnim="@anim/fragment_open_enter"
app:exitAnim="@anim/fragment_open_exit"
app:popEnterAnim="@anim/fragment_close_enter"
app:popExitAnim="@anim/fragment_close_exit" />

<fragment
android:id="@+id/mainFragment"
android:name="io.novafoundation.nova.app.root.presentation.main.MainFragment"
Expand Down Expand Up @@ -994,4 +1002,6 @@

<include app:graph="@navigation/network_management_graph" />

<include app:graph="@navigation/tinder_gov_graph" />

</navigation>
2 changes: 1 addition & 1 deletion app/src/main/res/navigation/referendum_details_graph.xml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@

<fragment
android:id="@+id/setupVoteReferendumFragment"
android:name="io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.setup.SetupVoteReferendumFragment"
android:name="io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.setup.referenda.SetupReferendumVoteFragment"
android:label="SetupVoteReferendumFragment">

<action
Expand Down
96 changes: 96 additions & 0 deletions app/src/main/res/navigation/tinder_gov_graph.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
<?xml version="1.0" encoding="utf-8"?>
<navigation xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/tinder_gov_graph"
app:startDestination="@id/tinderGovCards">

<fragment
android:id="@+id/tinderGovCards"
android:name="io.novafoundation.nova.feature_governance_impl.presentation.tindergov.cards.TinderGovCardsFragment"
android:label="TinderGovCardsFragment"
tools:layout="@layout/fragment_tinder_gov_cards">

<action
android:id="@+id/action_tinderGovCards_to_setupTinderGovVoteFragment"
app:destination="@id/setupTinderGovVoteFragment"
app:enterAnim="@anim/fragment_open_enter"
app:exitAnim="@anim/fragment_open_exit"
app:popEnterAnim="@anim/fragment_close_enter"
app:popExitAnim="@anim/fragment_close_exit" />

<action
android:id="@+id/action_tinderGovCards_to_tinderGovBasket"
app:destination="@id/setupTinderGovBasketFragment"
app:enterAnim="@anim/fragment_open_enter"
app:exitAnim="@anim/fragment_open_exit"
app:popEnterAnim="@anim/fragment_close_enter"
app:popExitAnim="@anim/fragment_close_exit" />

<action
android:id="@+id/action_tinderGovCards_to_referendumInfo"
app:destination="@id/referendumInfoFragment"
app:enterAnim="@anim/fragment_close_enter"
app:exitAnim="@anim/fragment_close_exit"
app:popEnterAnim="@anim/fragment_open_enter"
app:popExitAnim="@anim/fragment_open_exit" />

</fragment>

<fragment
android:id="@+id/setupTinderGovVoteFragment"
android:name="io.novafoundation.nova.feature_governance_impl.presentation.referenda.vote.setup.tindergov.SetupTinderGovVoteFragment"
android:label="SetupTinderGovVoteFragment"
app:useAdd="true"
tools:layout="@layout/fragment_setup_vote" />

<fragment
android:id="@+id/setupTinderGovBasketFragment"
android:name="io.novafoundation.nova.feature_governance_impl.presentation.tindergov.basket.TinderGovBasketFragment"
android:label="TinderGovBasketFragment"
app:useAdd="true"
tools:layout="@layout/fragment_tinder_gov_basket">

<action
android:id="@+id/action_setupTinderGovBasket_to_confirmTinderGovVote"
app:destination="@id/confirmTinderGovVoteFragment"
app:enterAnim="@anim/fragment_open_enter"
app:exitAnim="@anim/fragment_open_exit"
app:popEnterAnim="@anim/fragment_close_enter"
app:popExitAnim="@anim/fragment_close_exit" />

<action
android:id="@+id/action_setupTinderGovBasket_to_referendumInfo"
app:destination="@id/referendumInfoFragment"
app:enterAnim="@anim/fragment_close_enter"
app:exitAnim="@anim/fragment_close_exit"
app:popEnterAnim="@anim/fragment_open_enter"
app:popExitAnim="@anim/fragment_open_exit" />

</fragment>

<fragment
android:id="@+id/confirmTinderGovVoteFragment"
android:name="io.novafoundation.nova.feature_governance_impl.presentation.tindergov.confirm.ConfirmTinderGovVoteFragment"
android:label="ConfirmTinderGovVoteFragment"
app:useAdd="true">

<action
android:id="@+id/action_confirmTinderGovVote_to_tinderGovCards"
app:destination="@id/tinderGovCards"
app:enterAnim="@anim/fragment_close_enter"
app:exitAnim="@anim/fragment_close_exit"
app:popEnterAnim="@anim/fragment_open_enter"
app:popExitAnim="@anim/fragment_open_exit"
app:popUpTo="@id/tinderGovCards"
app:popUpToInclusive="true" />

</fragment>

<fragment
android:id="@+id/referendumInfoFragment"
android:name="io.novafoundation.nova.feature_governance_impl.presentation.common.info.ReferendumInfoFragment"
android:label="ConfirmTinderGovVoteFragment"
app:useAdd="true" />

</navigation>
10 changes: 7 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
buildscript {
ext {
// App version
versionName = '8.6.0'
versionCode = 154
versionName = '8.7.0'
versionCode = 155

applicationId = "io.novafoundation.nova"
releaseApplicationSuffix = "market"
Expand Down Expand Up @@ -51,7 +51,7 @@ buildscript {

web3jVersion = '4.9.5'

substrateSdkVersion = '2.1.2'
substrateSdkVersion = '2.1.4'

gifVersion = '1.2.19'

Expand Down Expand Up @@ -92,6 +92,8 @@ buildscript {
googleApiClientVersion = "1.32.1"
googleDriveVersion = "v3-rev20210919-1.32.1"

cardStackVersion = "2.3.4"

withoutTransitiveAndroidX = {
exclude group: "androidx.appcompat", module: "appcompat"
exclude group: "androidx.fragment", module: "fragment-ktx"
Expand Down Expand Up @@ -213,6 +215,8 @@ buildscript {
firebaseAppCheck = "com.google.firebase:firebase-appcheck-playintegrity"

kotlinReflect = "org.jetbrains.kotlin:kotlin-reflect:$kotlinVersion"

cardStackView = "com.github.yuyakaido:cardstackview:$cardStackVersion"
}

repositories {
Expand Down
Loading
Loading