leonardocustodio / polkadart

Polkadart provides developers the ability to query a node and interact with the Polkadot based chains using Dart.
https://polkadart.dev
Apache License 2.0
39 stars 16 forks source link

polkadart_cli exception: Type not found for `MinInflation` #490

Closed StepanUsynin closed 3 weeks ago

StepanUsynin commented 1 month ago

polkadart_cli throws an exception for Polkadot.

Building package executable... Built polkadart_cli:generate. output directory: ".../packages/substrate/lib/src/generated/polkadart" Unhandled exception: Exception: Type not found for MinInflation

0 Registry._parseCodec (package:polkadart_scale_codec/core/registry.dart:218:7)

1 Registry._parseTuple (package:polkadart_scale_codec/core/registry.dart:272:11)

2 Registry._parseCodec (package:polkadart_scale_codec/core/registry.dart:198:16)

3 Registry._parseComplexEnum (package:polkadart_scale_codec/core/registry.dart:629:15)

4 Registry._parseEnum (package:polkadart_scale_codec/core/registry.dart:573:15)

5 Registry._parseCodec (package:polkadart_scale_codec/core/registry.dart:223:16)

6 Registry._parseCodec (package:polkadart_scale_codec/core/registry.dart:210:23)

7 Registry._parseComplexEnum (package:polkadart_scale_codec/core/registry.dart:629:15)

8 Registry._parseEnum (package:polkadart_scale_codec/core/registry.dart:573:15)

9 Registry._parseCodec (package:polkadart_scale_codec/core/registry.dart:223:16)

10 Registry.parseSpecificCodec (package:polkadart_scale_codec/core/registry.dart:83:13)

11 V14Parser.getChainInfo (package:substrate_metadata/parsers/v14_parser.dart:119:46)

12 ChainInfo.fromMetadata (package:substrate_metadata/models/chain_info.dart:21:32)

13 new RuntimeMetadata.fromHex (package:polkadart/primitives/runtime_metadata.dart:16:28)

14 StateApi.getMetadata (package:polkadart/apis/state.dart:152:28)

#15 chainProperties (file:///.../.pub-cache/hosted/pub.dev/polkadart_cli-0.4.3/bin/generate.dart:38:27) #16 main (file:///.../.pub-cache/hosted/pub.dev/polkadart_cli-0.4.3/bin/generate.dart:73:40) # pubspeck.yaml environment: sdk: ">=3.0.0 <4.0.0" flutter: ">=3.0.0 <4.0.0" dependencies: flutter: sdk: flutter internet_connection_checker: ^1.0.0+1 Substrate polkadart: ^0.4.7 polkadart_cli: ^0.4.3 polkadart_keyring: ^0.4.4 polkadart_scale_codec: ^1.2.1 ss58: ^1.1.3 substrate_bip39: ^0.4.1 substrate_metadata: ^1.2.2 sr25519: ^0.4.1 dependency_overrides: intl: ^0.19.0 http: ^1.1.0 dev_dependencies: flutter_test: sdk: flutter flutter_lints: ^4.0.0 build_runner: any polkadart: output_dir: lib/src/generated/polkadart chains: polkadot: wss://rpc.polkadot.io # Flutter Doctor [✓] Flutter (Channel stable, 3.24.3, on macOS 15.0 24A335 darwin-arm64, locale en-RU) [✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0) [✓] Xcode - develop for iOS and macOS (Xcode 16.0) [✓] Chrome - develop for the web [✓] Android Studio (version 2024.1) [✓] VS Code (version 1.94.2) [✓] Connected device (4 available)
leonardocustodio commented 1 month ago

This is a working progress in here https://github.com/leonardocustodio/polkadart/pull/487 Any ETA @Lohann ?

leonardocustodio commented 3 weeks ago

Fixed with #491 , please update your substrate_metadata package to v1.2.3