Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Jun 4, 2024. It is now read-only.

Error: Missing required POST parameters: un key origin when passing array of text #24

Closed
markogresak opened this issue Jun 4, 2015 · 1 comment

Comments

@markogresak
Copy link

This is my setup for trace:

(It's TypeScript - ES6 syntax)

    x: this.users.map((u) => u.followerCount),
    y: this.users.map((u) => u.postCount),
    text: this.users.map((u) => u.username),
    // ...

The rest is just copied off the Colored and Styled Scatter Plot example.

When I run this, error from title is reported: Error: Missing required POST parameters: un key origin.
Although if I remove text: ..., it runs successfully.
I have checked the lengths and they match, all usernames are strings and there is also no falsy values.

Although if I change value mapped value to some fixed string, it runs. I'm unsure why it won't work for dynamic strings.
There are some special characters (emojis, etc.), could this be a problem, same as in #15?


Update 1: removing all non-ascii characters didn't help either. It repots a different error:
Error: Hm... Plotly had some trouble decoding your 'args'. ...
Which is as unhelpful as the first one.

Update 2: using regex [^a-zA-Z] as .replace(/[^a-zA-Z]/g, "") on each name finally worked. This is very dirty hack and I'm disappointed on that I had to use it.

@alexander-daniel
Copy link
Contributor

@markogresak : Should be resolved in this PR, please let me know if it works for you

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants