console shows warnings

579 views
Skip to first unread message

Liz Looney

unread,
Jul 21, 2017, 10:07:23 PM7/21/17
to blo...@googlegroups.com
I just noticed the following warnings in the chrome console. What am I doing wrong?


blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ARITHMETIC_TOOLTIP_ADD}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ARITHMETIC_TOOLTIP_MINUS}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ARITHMETIC_TOOLTIP_MULTIPLY}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ARITHMETIC_TOOLTIP_DIVIDE}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ARITHMETIC_TOOLTIP_POWER}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_SINGLE_TOOLTIP_ROOT}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_SINGLE_TOOLTIP_ABS}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_SINGLE_TOOLTIP_NEG}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_SINGLE_TOOLTIP_LN}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_SINGLE_TOOLTIP_LOG10}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_SINGLE_TOOLTIP_EXP}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_SINGLE_TOOLTIP_POW10}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_TRIG_TOOLTIP_SIN}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_TRIG_TOOLTIP_COS}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_TRIG_TOOLTIP_TAN}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_TRIG_TOOLTIP_ASIN}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_TRIG_TOOLTIP_ACOS}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_TRIG_TOOLTIP_ATAN}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ONLIST_TOOLTIP_SUM}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ONLIST_TOOLTIP_MIN}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ONLIST_TOOLTIP_MAX}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ONLIST_TOOLTIP_AVERAGE}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ONLIST_TOOLTIP_MEDIAN}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ONLIST_TOOLTIP_MODE}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ONLIST_TOOLTIP_STD_DEV}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_MATH_ONLIST_TOOLTIP_RANDOM}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_CONTROLS_WHILEUNTIL_TOOLTIP_WHILE}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_CONTROLS_WHILEUNTIL_TOOLTIP_UNTIL}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_CONTROLS_FLOW_STATEMENTS_TOOLTIP_BREAK}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_CONTROLS_FLOW_STATEMENTS_TOOLTIP_CONTINUE}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_LOGIC_COMPARE_TOOLTIP_EQ}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_LOGIC_COMPARE_TOOLTIP_NEQ}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_LOGIC_COMPARE_TOOLTIP_LT}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_LOGIC_COMPARE_TOOLTIP_LTE}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_LOGIC_COMPARE_TOOLTIP_GT}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_LOGIC_COMPARE_TOOLTIP_GTE}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_LOGIC_OPERATION_TOOLTIP_AND}.
blockly_compressed.js:1076 WARNING: No message string for %{BKY_LOGIC_OPERATION_TOOLTIP_OR}.

Erik Pasternak

unread,
Jul 24, 2017, 12:42:48 PM7/24/17
to Blockly
Hey Liz,

We've recently made all of the messages use references in JSON. The %{MSG_NAME} is the message format we're using, and anything that has BKY_ at the start is assumed to be in the Blockly.Msg array. So BKY_MATH_TRIG_TOOLTIP_SIN should be at Blockly.Msg.MATH_TRIG_TOOLTIP_SIN. If those messages exist in your build you should make sure you're including the messages.js script before blocks_compressed.js so that the messages exist when the blocks are loaded.

Cheers,
Erik

Liz Looney

unread,
Jul 24, 2017, 4:46:15 PM7/24/17
to blo...@googlegroups.com
OK. I think that's the problem. Thanks!

This brings up another question. If I'm using blockly_compressed.js, what other files (besides messages.js) do I need to include in my html and what other files (if any) need to be served by my web server (but not explicitly included in my html)?



--
You received this message because you are subscribed to the Google Groups "Blockly" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blockly+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Neil Fraser

unread,
Jul 24, 2017, 5:14:00 PM7/24/17
to blo...@googlegroups.com
A set of blocks is needed.  The standard library is blocks_compressed.js, but you can create your own.
That's the third and final item that needs to be included in the HTML.

Beyond this, some of the files in the media directory are referenced.  Which ones depend on your settings.  The location of the media directory can be set using the startup configuration.

ding

unread,
Jan 7, 2020, 4:41:02 AM1/7/20
to Blockly
have you solved this problem? 

在 2017年7月22日星期六 UTC+8上午10:07:23,Liz Looney写道:

Ludvig Linse

unread,
Jul 21, 2020, 9:42:29 AM7/21/20
to Blockly
I'm getting these warning printouts using the latest Q2 2020 Blockly in a React application importing blockly with ES6 import (import Blockly from "blockly/browser") and then injecting Blockly as is done here:  https://developers.google.com/blockly/guides/configure/web/resizable

Not sure how to work-around this in this setup, does anyone have ideas? 

Best,

Ludvig

Ludvig Linse

unread,
Jul 21, 2020, 9:57:33 AM7/21/20
to blo...@googlegroups.com
I managed to solve it myself with this additional import: 

import Blockly from "blockly/browser"
import 'blockly/msg/en'

--
You received this message because you are subscribed to the Google Groups "Blockly" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blockly+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/blockly/8dadacba-f6ff-45d0-8939-ea03ee50858fn%40googlegroups.com.


--
The dialog-first tool to build scalable chat and voice apps
https://narratory.io

Eric Edem

unread,
Jul 24, 2020, 7:21:48 PM7/24/20
to Blockly
Hey I am trying to solve this as well using the npm module on version `^3.20200625.2`.

The first response in this thread seems indicates that you need to import message before blocky, however it doesn't seem like this is an option if you are using the npm module.

Does anyone have a recommendation on what to do here? The following seems to follow the recommendation most closely but does not resolve the issue:

```
import "blockly/msg/en";
import * as Blockly from "blockly";
```

Best,
Eric

PIERRE LABROCHE

unread,
Aug 3, 2022, 1:12:04 AM8/3/22
to Blockly
For me, putting messages.js and en.js after worked

Christopher Allen

unread,
Aug 8, 2022, 10:13:09 AM8/8/22
to blo...@googlegroups.com
On Wed, 3 Aug 2022 at 06:12, PIERRE LABROCHE <labrochep...@gmail.com> wrote:
For me, putting messages.js and en.js after worked
 
For anyone (in 2022) having this issue with Blockly v8.0.4, please note that there was an unexpected regression in that version.  Please see this recent thread and in particular my reply here where you will find a better workaround.  A full fix should be available soon either as a patch or with the delayed 2022Q2 release.
Reply all
Reply to author
Forward
0 new messages