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

fix: Remove PoW and debris #8177

Merged
merged 6 commits into from
Mar 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
1 change: 0 additions & 1 deletion packages/desktop/components/popups/NodeInfoPopup.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@
nodeInfoPath: 'protocolParameters[0].parameters.tokenSupply',
},
version: { localeKey: 'protocol.version', nodeInfoPath: 'protocolParameters[0].parameters.version' },
// minPowScore: { localeKey: 'protocol.minPowScore', nodeInfoPath: 'protocol.minPowScore' },
},
[NodeInfoTab.BaseToken]: {
token: { localeKey: 'baseToken.token', nodeInfoPath: 'baseToken.name' },
Expand Down
3 changes: 0 additions & 3 deletions packages/desktop/features/settings.features.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,6 @@ const settingsFeatures: ISettingsFeatures = {
configureNodeList: {
enabled: true,
},
localProofOfWork: {
enabled: true,
},
},
advanced: {
enabled: true,
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
export { default as ConfigureNodeList } from './ConfigureNodeList.svelte'
export { default as LocalProofOfWork } from './LocalProofOfWork.svelte'
export { default as NetworkInformation } from './NetworkInformation.svelte'

export * from './network-settings.constant'
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import { NetworkSettingsRoute } from '@core/router'
import { NetworkInformation, LocalProofOfWork, ConfigureNodeList } from './'
import { NetworkInformation, ConfigureNodeList } from './'

export const NETWORK_SETTINGS = [
{ component: NetworkInformation, childRoute: NetworkSettingsRoute.NetworkInformation },
{ component: ConfigureNodeList, childRoute: NetworkSettingsRoute.ConfigureNodeList },
{ component: LocalProofOfWork, childRoute: NetworkSettingsRoute.LocalProofOfWork },
]
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ export const SETTINGS_ICON_SVG = {
[CollectiblesSettingsRoute.RefreshNftMedia]: Icon.Refresh,
[NetworkSettingsRoute.NetworkInformation]: Icon.Wifi,
[NetworkSettingsRoute.ConfigureNodeList]: Icon.Customize,
[NetworkSettingsRoute.LocalProofOfWork]: Icon.Chip,
[SecuritySettingsRoute.ExportStronghold]: Icon.Export,
[SecuritySettingsRoute.StrongholdPasswordTimeout]: Icon.Timelock,
[SecuritySettingsRoute.AppLock]: Icon.Logout,
Expand Down
1 change: 0 additions & 1 deletion packages/shared/lib/core/network/actions/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,5 @@ export * from './network-polling'
export * from './removeNodeFromClientOptions'
export * from './showNetworkIssueNotification'
export * from './toggleDisabledNodeInClientOptions'
export * from './toggleLocalPowInClientOptions'
export * from './togglePrimaryNodeInClientOptions'
export * from './updateClientOptions'

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ export const DEFAULT_NETWORK_METADATA: Readonly<{ [key in NetworkId]?: NetworkMe
version: 2,
networkName: 'shimmer',
bech32Hrp: 'smr',
minPowScore: 1500,
belowMaxDepth: 15,
rentStructure: {
vByteCost: 100,
Expand All @@ -31,7 +30,6 @@ export const DEFAULT_NETWORK_METADATA: Readonly<{ [key in NetworkId]?: NetworkMe
version: 2,
networkName: 'testnet',
bech32Hrp: 'rms',
minPowScore: 1500,
belowMaxDepth: 15,
rentStructure: {
vByteCost: 100,
Expand All @@ -50,7 +48,6 @@ export const DEFAULT_NETWORK_METADATA: Readonly<{ [key in NetworkId]?: NetworkMe
version: 2,
networkName: 'iota',
bech32Hrp: 'iota',
minPowScore: 1500,
belowMaxDepth: 15,
rentStructure: {
vByteCost: 250,
Expand All @@ -69,7 +66,6 @@ export const DEFAULT_NETWORK_METADATA: Readonly<{ [key in NetworkId]?: NetworkMe
version: 2,
networkName: 'iota-alphanet-2',
bech32Hrp: 'atoi',
minPowScore: 1500,
belowMaxDepth: 15,
rentStructure: {
vByteCost: 250,
Expand Down

This file was deleted.

1 change: 0 additions & 1 deletion packages/shared/lib/core/network/interfaces/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
export * from './chain-metadata.interface'
export * from './connected-chain.interface'
export * from './client-options.interface'
export * from './network-status.interface'
export * from './node-info-response.interface'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ export interface IProtocol {
version: number
networkName: string
bech32Hrp: string
// minPowScore: number
belowMaxDepth?: number
rentStructure: IRentStructure
tokenSupply: string
Expand Down
10 changes: 0 additions & 10 deletions packages/shared/lib/core/network/utils/buildChainFromNetwork.ts

This file was deleted.

9 changes: 0 additions & 9 deletions packages/shared/lib/core/network/utils/doesNodeHavePlugin.ts

This file was deleted.

2 changes: 0 additions & 2 deletions packages/shared/lib/core/network/utils/index.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
export * from './buildChainFromNetwork'
export * from './buildPersistedNetworkFromNodeInfoResponse'
export * from './checkNetworkId'
export * from './checkNodeUrlValidity'
export * from './doesNodeHavePlugin'
export * from './getDefaultClientOptions'
export * from './getDefaultPersistedNetwork'
export * from './getNetworkIdFromNetworkName'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,6 @@ export function checkAndMigrateChrysalisProfiles(): boolean {
}
})
}
migratedProfile.clientOptions.localPow =
chrysalisProfile.settings?.networkConfig?.localPow ?? migratedClientOptions.localPow

migrated = true
saveProfile(migratedProfile)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
export enum NetworkSettingsRoute {
NetworkInformation = 'networkInformation',
ConfigureNodeList = 'configureNodeList',
LocalProofOfWork = 'localProofOfWork',
}
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ interface ICollectiblesSettingsFeatures extends IFeatureFlag {
interface INetworkSettingsFeatures extends IFeatureFlag {
networkInformation: IFeatureFlag
configureNodeList: IFeatureFlag
localProofOfWork: IFeatureFlag
}

interface IAdvancedSettingsFeatures extends IFeatureFlag {
Expand Down
9 changes: 1 addition & 8 deletions packages/shared/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -368,10 +368,6 @@
"noNodes": "There are no nodes, unable to connect to the network",
"noNodesAuto": "There are no nodes, automatic selection will be used instead"
},
"localProofOfWork": {
"title": "Proof of work",
"description": "Complete proof of work locally on your device or outsource to the node"
},
"errorLog": {
"title": "Error log",
"description": "View errors to debug an issue"
Expand Down Expand Up @@ -948,8 +944,7 @@
"network": "Network",
"bech32Hrp": "Bech32 HRP",
"tokenSupply": "Token supply",
"version": "Version",
"minPowScore": "Min PoW Score"
"version": "Version"
cpl121 marked this conversation as resolved.
Show resolved Hide resolved
},
"baseToken": {
"tab": "Base token",
Expand Down Expand Up @@ -1359,7 +1354,6 @@
"enableDeveloperMode": "Enable developer mode",
"enableSystemNotifications": "Enable system notifications",
"exportTransactionHistory": "Export transaction history",
"localProofOfWork": "Local proof of work",
"unlock": "Unlock",
"updateFirefly": "Update Firefly",
"restartNow": "Restart now",
Expand Down Expand Up @@ -1601,7 +1595,6 @@
"transferRemainderAddress": "Generating remainder address",
"transferPreparedTransaction": "Preparing transaction",
"transferSigning": "Signing the transaction",
"transferPow": "Performing PoW",
"transferBroadcasting": "Broadcasting transaction",
"transferComplete": "Transfer complete",
"generatingReceiveAddress": "Generating receive address",
Expand Down
5 changes: 0 additions & 5 deletions packages/shared/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,9 @@
// files included below should have no ts-errors
"files": [
"lib/core/network/constants/default-seconds-per-slot.constant.ts",
"./lib/core/network/utils/buildChainFromNetwork.ts",
"./lib/core/network/utils/buildPersistedNetworkFromNodeInfoResponse.ts",
"./lib/core/network/utils/checkNetworkId.ts",
"./lib/core/network/utils/checkNodeUrlValidity.ts",
"./lib/core/network/utils/doesNodeHavePlugin.ts",
"./lib/core/network/utils/getDefaultClientOptions.ts",
"./lib/core/network/utils/getDefaultPersistedNetwork.ts",
"./lib/core/network/utils/getNetworkIdFromNetworkName.ts",
Expand All @@ -25,17 +23,14 @@
"./lib/core/utils/constants/default-exchange-rates.constant.ts",
"./lib/core/utils/constants/hex.constants.ts",
"./lib/core/utils/constants/index.ts",
"./lib/core/utils/constants/iota-unit-map.constant.ts",
"./lib/core/utils/constants/max-bytes.constant.ts",
"./lib/core/utils/constants/max-number-of-iotas.constant.ts",
"./lib/core/utils/constants/pin-length.constant.ts",
"./lib/core/utils/constants/time.constants.ts",
"./lib/core/utils/enums/exchange-rate.enum.ts",
"./lib/core/utils/enums/iota-unit.enum.ts",
"./lib/core/utils/enums/past-time-unit.enum.ts",
"./lib/core/utils/interfaces/date-difference.interface.ts",
"./lib/core/utils/types/exchange-rates.type.ts",
"./lib/core/utils/types/iota-unit-map.type.ts",
"./lib/core/utils/date.ts",
"./lib/core/utils/ui.ts"
]
Expand Down
Loading