Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: JScript Panel (Read 296917 times) previous topic - next topic
0 Members and 3 Guests are viewing this topic.

Re: JScript Panel

Reply #1300
I can't trigger a crash. I don't know what I'm supposed to search for with the search element in the layout. Everything I try has length. And dragging the url you linked comes up with an entry that has a length.

If you make a fresh portable foobar2000 install without involving any skins and just install JScript panel and youtube-dl, can you make things crash?

If you have a way to reproduce the crash easily I really don't understand why you don't provide a simple config that shows it. Should be super simple to make a minimal foobar with the required components and configs that crashes just by clicking the playlist entry. Then just zip/7zip/rar that dir up and share.
I managed to trigger the crash (it wasn't easy since there are quite a few prerequisities...) It was logged in the Windows Event Viewer:

Code: [Select]
Faulting application name: foobar2000.exe, version: 2.1.0.0, time stamp: 0x65292aa0
Faulting module name: jscript9.dll, version: 11.0.19041.3570, time stamp: 0x8ebdb297
Exception code: 0xc0000602
Fault offset: 0x0019803c
Faulting process ID: 0x5fa8
Faulting application start time: 0x01da03939e0484ac
Faulting application path: F:\foobar2000\foobar2000-2.1-x86\foobar2000.exe
Faulting module path: C:\Windows\System32\jscript9.dll
Report ID: 569abd91-ea0c-436e-af4d-4668eac781f2
Faulting package full name:
Faulting package-relative application ID:

The exception code is STATUS_FAIL_FAST_EXCEPTION ('A fail fast exception occurred. Exception handlers will not be invoked and the process will be terminated immediately.')

I've attached an FPL file that may trigger it for other people (with the right set-up).

Thank you! I really don't know what else to do after making a complete vanilla FCL. Make a portable foobar? Why? My included FCL's are completely vanilla plus JS3_POI and do crash with a culprit/bad file.

I can confirm that your attached playlist triggers the crash.

All of a sudden I get an entry in windows eventviewer as well.

Faulting application name: foobar2000.exe, version: 2.1.0.0, time stamp: 0x65292aa0
Faulting module name: jscript9.dll, version: 11.0.22621.2070, time stamp: 0x30f96d8e
Exception code: 0xc0000602
Fault offset: 0x0020fef7
Faulting process id: 0x0x70B8
Faulting application start time: 0x0x1DA036E24AE46C9
Faulting application path: C:\Program Files (x86)\_MEDIA\foobar2000\foobar2000.exe
Faulting module path: C:\Windows\System32\jscript9.dll
Report Id: cf96887e-2f71-4be6-9c86-3ae2635e38fa
Faulting package full name:
Faulting package-relative application ID:

Same dll, but other version.

Re: JScript Panel

Reply #1301
I've attached an FPL file that may trigger it for other people (with the right set-up).
Thanks musicmusic, that works nicely for triggering the crash.

Thank you! I really don't know what else to do after making a complete vanilla FCL. Make a portable foobar? Why? My included FCL's are completely vanilla plus JS3_POI and do crash with a culprit/bad file.
To make finding the claimed bug as easy as possible. I don't know if marc2k3 tried triggering the crash but I have spent a lot of time trying various component configurations and following your instructions. Feels almost like that's all I have managed to do today, try to make foobar2000 crash.
It's quite easy to ignore a crash report if one can't trigger a problems. As a rule of thumb if you want to report a bug you should provide all the information you can and make it as easy as possible for the developer to confirm the problem.

Re: JScript Panel

Reply #1302
Thank you! I really don't know what else to do after making a complete vanilla FCL. Make a portable foobar? Why? My included FCL's are completely vanilla plus JS3_POI and do crash with a culprit/bad file.
To make finding the claimed bug as easy as possible. I don't know if marc2k3 tried triggering the crash but I have spent a lot of time trying various component configurations and following your instructions. Feels almost like that's all I have managed to do today, try to make foobar2000 crash.
It's quite easy to ignore a crash report if one can't trigger a problems. As a rule of thumb if you want to report a bug you should provide all the information you can and make it as easy as possible for the developer to confirm the problem.

That's why I spend almost two days on this bug (a full day before I sent my first post about it).
Still don't understand why a vanilla fcl which crashes is not enough and it has to be a portable one.

Thankfully Musicmusic had the right idea by just sending an fpl with a culprit.

Re: JScript Panel

Reply #1303
Still don't understand why a vanilla fcl which crashes is not enough and it has to be a portable one.
Because the crash has nothing to do with the FCL. And like I was trying to say, even after going through the trouble of obtaining all the components your layout file needed and trying to follow your instructions as well as possible, foobar was not crashable. The files you provided didn't cause the crash and I could not create a scenario that you described that would crash.
If you had provided a zip with needed components and crashing playlist, it would have been reproducible in 1 minute. Now we spent a day hunting it down.

Now with musicmusic's FPL file the crash is triggerable with instructions anyone can follow:
1. install clean portable foobar2000.
2. install foo_youtube
3. install foo_jscript_panel3
4. add JScript panel to UI
5. load Properties + Other Info sample script to the panel
6. configure panel selection mode to Follow selected track
7. drag bad-playlist.fpl to the UI
8. observe how things crash after a short moment

Re: JScript Panel

Reply #1304
So the bug was me being oblivious to this dump method default args in the JSON library I'm using documented here...

https://json.nlohmann.me/api/basic_json/dump/

I didn't realise the default behaviour was to throw exceptions with invalid UTF8 sequences. I've since updated this and hope it works now.

Thanks to musicmusic for the .fpl file.  8)

---

3.3.7

https://github.com/jscript-panel/release/releases


Re: JScript Panel

Reply #1305
Hi,

Please look at the screenshot:

https://imgbox.com/3GWaBkLo

How to make songs with disc number and track number appear first? I use Smooth Playlist.

Thanks for any help.

Re: JScript Panel

Reply #1306
It's not really a playlist's job to sort items. Proper playlists obviously provide clickable column headers for convenience but generally it's the responsibility of whatever library viewer you're using (or Preferences>shell integration > sort incoming files by if using the file menu to add files/folders or drag/dropping from Explorer).

The only way to sort files after being added is using the Edit menu>Sort. Use Sort By for custom title formatting or use one the built in presets.

Re: JScript Panel

Reply #1307
Thanks for the answer.

The problem is that regardless of the sorting scheme I would choose, files without a disk number are displayed first.

And I would like it to be the other way around, because I have a disc where the additional songs are not a separate disc, but are placed on the disc as a bonus files. On the mobile foobar everything is as it should be.

edit. Okay, in foobar for Windows installed without any additions it's the same, i.e. foobar simply treats songs without a discnumber as "disc zero" and places them before the first, second, etc. The only way is probably to add 2 of these songs or something else to the "discnumber" tags.

Re: JScript Panel

Reply #1308
If you want tracks without discnumber tags to be treated as disc 1 without tags then you can try this somewhere in your sort pattern....

Code: [Select]
$if2(%discnumber%,1)

Use some silly high value like 9999 if you want them shunted right to the end. Repeat for %tracknumber% if needed.

Re: JScript Panel

Reply #1309
So the bug was me being oblivious to this dump method default args in the JSON library I'm using documented here...

https://json.nlohmann.me/api/basic_json/dump/

I didn't realise the default behaviour was to throw exceptions with invalid UTF8 sequences. I've since updated this and hope it works now.

Thanks to musicmusic for the .fpl file.  8)

---

3.3.7

https://github.com/jscript-panel/release/releases


Thx for fixing this.

Plenty of questions about the search component of foo_youtube and/or the external yt-dlp.exe though which I will address in the correct forum topic.

Re: JScript Panel

Reply #1310
3.3.8

https://github.com/jscript-panel/release/releases

The allmusic sample has been nuked because of changes on the website that prevent new lookups. If you have a cache of previously saved reviews and want to continue displaying them, you'll need this script....

https://jscript-panel.github.io/files/allmusic.txt

I've also added an "Album Art + Text Display" sample. If peeps have been following the discussion thread, you might have seen it there already. It displays album art above the text in addition to the optional background. Just select it from the samples button.

Re: JScript Panel

Reply #1311
Apologies for the inconvenience but I already broke the "Album Art + Text Display" sample added in 3.3.8 2 days ago.

If you install 3.3.9+, you need to replace it with the original "Text Display". This now has 3 layout options available on the right click menu:

- Text only
- Album Art top, Text bottom ( text alignment is not available in this mode but are in the other 2)
- Album Art left, Text right

---

3.3.9

https://github.com/jscript-panel/release/releases

edit: it's quite likely this breaks mods posted in the discussion thread. They should be replaced with the original if possible.




Re: JScript Panel

Reply #1313
Hi, marc!
My script is not working somehow, specifically DrawThemeBackground function.

Code: [Select]
...
this.theme = window.CreateThemeManager("scrollbar");

this.upImage_normal = utils.CreateImage(this.w, this.w);
gb = this.upImage_normal.GetGraphics();
this.theme.SetPartAndStateID(1, 1);
this.theme.DrawThemeBackground(gb, 0, 0, this.w, this.w);
this.upImage_normal.ReleaseGraphics();
...

And, is it possible to revert the 'topbar filterbox' feature in smooth playlist?

Thanks!

Re: JScript Panel

Reply #1314
My script is not working somehow, specifically DrawThemeBackground function.

I can't test now but I'll look at it later. I know it works when used conventionally without creating your own graphics objects. See the basic\SimpleThemedButton + Tooltip sample or the Smooth samples/JS Playlist when not using dark mode and you use "system default" colour in DUI or have theming enabled in CUI.

Quote
And, is it possible to revert the 'topbar filterbox' feature in smooth playlist?

Absolutely not. That was so broken, it was never usable. The filtering never considered the original positions in the playlist so you could never select or play the results. It was functionally useless.


Re: JScript Panel

Reply #1316
3.3.12

Playback statistics are back. The title format pattern for binding database records to tracks is no longer hard coded. It can edited to anything you like.

Pay attention to the docs. :P

https://github.com/jscript-panel/release/releases

https://jscript-panel.github.io/docs/playback-statistics/


Re: JScript Panel

Reply #1318
3.3.14

- Update Playback Statistics with %jsp3_skipcount%.
- Add IMetadbHandleList Drop and IMetadbHandleList Take.
- Remove up/down indicators from Text Display sample.

https://github.com/jscript-panel/release/releases

https://jscript-panel.github.io/docs/changes/





Re: JScript Panel

Reply #1322
3.3.18

https://github.com/jscript-panel/release/releases

https://jscript-panel.github.io/docs/changes/

No component changes, just a new combined last.fm bio/images sample. Screenshot can be found in the DUI gallery thread.

https://hydrogenaud.io/index.php/topic,58574.msg1036118.html#msg1036118

Re: JScript Panel

Reply #1323
3.3.19

https://github.com/jscript-panel/release/releases

https://jscript-panel.github.io/docs/changes/

Add utils.GetCountryFlag and a $country_flag title format function. Details on how to use and the required font is here...

https://jscript-panel.github.io/docs/country-flags/

Some docs have been added on how to use $font and $rgb in your own scripts.

https://jscript-panel.github.io/docs/font-rgb/

 

Re: JScript Panel

Reply #1324
3.3.20

https://github.com/jscript-panel/release/releases

https://jscript-panel.github.io/docs/changes/

Existing users of Last.fm Bio + Image must re-import from the Samples button.
Fixes various bugs with Last.fm Bio + Image.
Add new Allmusic Review + Album Art sample
Both of the above have toggles for displaying the text to the right or to the bottom of the main image.
You can alter the ratio for image/text display by holding down Ctrl while you scroll.