microsoft / pxt-microbit

A Blocks / JavaScript code editor for the micro:bit built on Microsoft MakeCode
https://makecode.microbit.org
Other
710 stars 588 forks source link

Cannot open help documentation about 'Play a sound expression' in JavaScript and Python editor #5666

Closed v-katherine closed 1 week ago

v-katherine commented 4 months ago

Describe the bug Cannot open help documentation about 'Play a sound expression' in JavaScript and Python editor

Steps to reproduce the behavior 1.Navigate to https://makecode.microbit.org/beta 2.Create or open JavaScript/Python editor. 3.Toolbox->Music, open the help documentation of block 'melody at tempo 120', 'tone for duration' and 'melody'.

Actual behavior: Cannot open the documentation, shows' Oops we could not load the documentation, please check your internet connection'.

Expected behavior: Open the help documentation correctly.

Screen Recording: playsound

Additional context: 1.OS: Windows11, iMac Ventura 13.6.6 2.makecode.microbit,org version: 7.0.9 3.Microsoft MakeCode version: 10.0.21

ganicke commented 1 month ago

@abchatra - part of the problem here is that half of the music docs are sourced in the mixer lib. The //% help= path for both music lib and mixer lib is set to use ./reference/music. It seems that the lookup hierarchy is not linking in ./pxt-common-packages/libs/mixer to look for a doc when its help path is //% help=music/xxyyzz even though it placed the mixer blocks into the music namespace.

riknoll commented 1 month ago

@ganicke for historical reasons we don't actually include the mixer lib in pxt-microbit at all; long ago we redefined the melody format for pxt-microbit in pxt-common-packages and the two music implementations have been incompatible ever since.

I guess the fix here is to just copy the mixer docs into pxt-microbit. The melody and sound effect blocks will probably also require slightly different documentation since those are the two major points of differentiation between the two.

ganicke commented 1 month ago

@riknoll - yes, that's right. Had I investigated more under ./libs I would've noticed. Thanks, I'll get some micro:bit versions or those pages in there.

fionama100 commented 1 month ago

I have verified this bug in the latest build makecode microbit.org version: 7.0.16, and the help documentation of block 'melody at tempo 120' and 'tone for duration' can be open successfully. But the help documentation of block melody still Cannot be opened, shows: "Oops we could not load the documentation, please check your internet connection", so I reopen this bug.

srietkerk commented 1 week ago

This is fixed via https://github.com/microsoft/pxt-microbit/pull/5880.

Ramanan0530 commented 1 week ago

I verified this bug in the latest version: 7.0.36 and it has been fixed.