question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

createType(StorageKey):: Derived TypedArray constructor created an array which was too small

See original GitHub issue

Unable to creates a unsigned extrinsic:

import Decorated from '@polkadot/metadata/Decorated'
import { TypeRegistry } from '@polkadot/types/create'
import ExtrinsicV4 from '@polkadot/types/extrinsic/v4/Extrinsic'
import metadataStatic from '@polkadot/metadata/Metadata/static'

const registry = new TypeRegistry()
const decorated = new Decorated(registry, metadataStatic)

new ExtrinsicV4(
    registry,
    decorated.tx.balances.transfer('5HpLdCTNBQDjFomqpG2XWadgB4zHTuqQqNHhUyYbett7k1RR', 0),
  ).toHex()

error message:

createType(StorageKey):: Derived TypedArray constructor created an array which was too small

version:

"@polkadot/metadata": "1.10.1",
"@polkadot/types": "1.10.1",

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:11 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
xwartzcommented, Apr 17, 2020

fixed on RN 0.59.10

  1. rm -rf node_modules && yarn install
  2. NODE_OPTIONS=–max_old_space_size=8192 npm start
0reactions
polkadot-js-botcommented, Jun 4, 2021

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue if you think you have a related problem or query.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error Connecting to Substrate: Unable to initialize the API
Anyway, I bound the @polkadot/api to my node via the command: ... the API: createType(StorageKey):: Derived TypedArray constructor created ...
Read more >
TypedArray - JavaScript - MDN Web Docs
The constructor function used to create derived objects. All TypedArray subclasses also have the following static properties: TypedArray.
Read more >
20. Typed Arrays - Exploring JS
ArrayBuffers store the data, views (Typed Arrays and DataViews) let you read and change it. In order to create a DataView, you need...
Read more >
How to work with buffers in Duktape 1.x
Up to Duktape 1.2 all buffer values (plain buffers and Duktape. ... Khronos and ES2015 typed array specifications (ArrayBuffer constructor, typed array ......
Read more >
TypedArray Introduction - GeeksforGeeks
Constructor : This object cannot be instantiated directly. Instead, you have to create an instance of an array of a particular type, such...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found