Skip to main content
Topic: Spider Monkey Panel (foo_spider_monkey_panel) (Read 53454 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #325
Regretfully, fb2k does not provide `on_startup_done` callback and I can't implement it myself.

I have no need to recalculate the width of the text at every on_paint
As I've said, you can *cache* the value. Or just use a simple boolean guard
Code: [Select]
var isInitialized = false;
function on_paint()
{
  if (!isInitialized )
  {
    CalculateSmth();
    isInitialized =true;
  }
}

I see. Thanks, I actually needed to be reassured that a workaround is needed here. I guess I'll just save the playing playlist name to a file, Talking of workarounds, I found out that you can trigger a few playlist events before the initial on_paint by adding and removing items to a playlist on start up. It's probably the closest you can get to an on_start_up_done.
I'm late

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #326
@davideleo , I've got some info from Peter (https://hydrogenaud.io/index.php?topic=117208.msg977811#msg977811), which clarified some things:
- It *might* be possible to create on_start_up_done callback. No promises or ETA though.
- on_paint and on_size callbacks *might* (and often will) be called before the fb2k is fully initialized.
[Edit]:
- It *is* possible to suppress shortcuts. But no promises or ETA on that either.

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #327
 8)  You are my favorite foobar2000 component developer ♥
I'm late


Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #329
- on_paint and on_size callbacks *might* (and often will) be called before the fb2k is fully initialized.

What I refer to as "start up" is probably autoplaylist initialization really. The console log shows the start up time right after all autoplaylists are set, therefore I gathered that was the last stand of the start up process. This is my usual start up log:


Quote from:  console.log
components loaded
configuration read
on_size
Spider Monkey panel initialized
on_size (3 times)
UI initialized
foo_custom_database initialized
autoplaylist initialized
foo_enhanced_playcount loaded
start up done (at least start up time is written here in the console log) <-----------------
possible playlist events
on_paint


I'm late

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #330
Hello @TheQwertiest, hoping to find you well, I am getting to you just to have an idea of when you would release the new SMP with the v1 and v2 methods merged together.
I am waiting for it in order to use Library Tree (I have then to remove because of the too frequent out-of-memory crashes).
Kind regards, Andrea

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #331
@AndreaT, it's still quite far from release, but you can use Nightly version in the meantime (Nightly/beta doesn't mean "not stable" ), it has v2 sorting method integrated.

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #332
@AndreaT, it's still quite far from release, but you can use Nightly version in the meantime (Nightly/beta doesn't mean "not stable" ), it has v2 sorting method integrated.

Hello @TheQwertiest, ... thanks ... but your last Nightly build I downloaded few hours ago cannot be installed.
I am getting an installation error. I tried 3 times.
If you need the error code, let me know and I will try to reinstall again.
Thanks and regards, Andrea

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #333
I am getting an installation error. I tried 3 times.
If you need the error code, let me know and I will try to reinstall again.
That's really weird. Is there a error message or smth like that?

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #334
Hello @TheQwertiest, this is the error I get during the installation process:
"Could not load component "foo_spider_monkey_panel.fb2k-component": bad allocation"

I downloaded right now the Nightly buid from your GitHub project page: https://github.com/TheQwertiest/foo_spider_monkey_panel
using the link you provided for the nightly build:
link https://ci.appveyor.com/api/projects/theqwertiest/foo-spider-monkey-panel/artifacts/_result%2FWin32_Release%2Ffoo_spider_monkey_panel.fb2k-component?branch=master&job=Configuration%3A%20Release

Regards, Andrea


Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #336
I need some clarification about memory usage. I'm monitoring the panel and the total memory usage of a one SMP only configuration and I was expecting the two values to coincide. Instead, panel memory usage reaches 52 MB before GC kicks in, while total memory usage is more or less stuck on 2 MB. How is that? Why is total memory usage lower than panel memory usage?
I'm late

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #337
Hello @TheQwertiest , I am getting the same error: Could not load component "foo_spider_monkey_panel.fb2k-component": bad allocation.

By the way, is it correct that this package is 57MB in size and that I had to rename the file removing the ending "_debug"?

Regards, Andrea

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #338
I need some clarification about memory usage. I'm monitoring the panel and the total memory usage of a one SMP only configuration and I was expecting the two values to coincide. Instead, panel memory usage reaches 52 MB before GC kicks in, while total memory usage is more or less stuck on 2 MB. How is that? Why is total memory usage lower than panel memory usage?
What smp version are you using?

Hello @TheQwertiest , I am getting the same error: Could not load component "foo_spider_monkey_panel.fb2k-component": bad allocation.
Hm... That's really weird. Can you check if installation of the latest release version (v1.2.2) works? I'm not even sure if it's a SMP error anymore...
Oh and what's your fb2k version?

By the way, is it correct that this package is 57MB in size and that I had to rename the file removing the ending "_debug"?
Yes, that's correct. Another user has informed me that I forgot to include some files though, so it wouldn't have worked even if your installation succeeded.


Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #340
v1.2.2-preview+0db3c6a4
Calculating total memory usage is actually not a `free` operation in terms of performance (compared to panel memory usage), so to minimize performance impact it uses cached value, which is updated every GC cycle. In some cases (e.g. yours) this might result in incorrect values. I'll see if smth can be done to make reported values more accurate.

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #341
Thanks for the answer. Since it's a one-panel configuration, can I presume the total memory consumption to be that of the only panel, or does the component use more memory besides the panel shares?
I'm late

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #342
Thanks for the answer. Since it's a one-panel configuration, can I presume the total memory consumption to be that of the only panel, or does the component use more memory besides the panel shares?
SMP needs additional memory for JS engine and for internal usage, but it's safe to assume that panel is the one that contributes the most to memory usage (unless it contains nothing :P).
The memory impact of SMP will be close to zero (citation needed), if there are no SMP panels active.

Re: Spider Monkey Panel (foo_spider_monkey_panel)

Reply #343
Hello @TheQwertiest, I am sorry, I have bad news: no way for me to install ever the v1.2.2-preview.
I am getting the same error.
I would like to try to remove the current version I have running:

Spider Monkey Panel v1.2.3-beta+61085bf2 by TheQwertiest
Based on JScript Panel by marc2003
Based on WSH Panel Mod by T.P. Wang

Build: 10:49:05, Nov 11 2019
Columns UI SDK Version: 6.5


But what about if then I cannot reinstall any?

Regards, Andrea

 
SimplePortal 1.0.0 RC1 © 2008-2019