Adobe-CEP / CEP-Resources

Tools and documentation for building Creative Cloud app extensions with CEP
https://www.adobe.io/apis/creativecloud/cep.html
1.63k stars 831 forks source link

CEP 11 Not writing Extension console.log messages to log file #520

Open BrianWCSI opened 1 month ago

BrianWCSI commented 1 month ago

Overview

I am unable to see any console.log messages from an HTML Extension in the expected log files with Adobe Illustrator 2021-2024 (all CEP11-based versions). I CAN see log messages for AI 2020 using CEP 9. The CSXS.11 LogLevel registry setting IS set to '6' (all messages).

To Repro

This was discovered using our own Extension, but I am able to reproduce the issue using the HTML Test extension (https://github.com/Adobe-CEP/CEP-Resources/tree/master/CEP_11.x/Samples/CEP_HTML_Test_Extension-10.0)

1) I updated the html/index.html file to add a few console log messages at the end of the window.onload function:

/**
 * Add eventListener to listen PP's theme change event.
 **/
window.onload = function()
{
    CSLibrary.addEventListener("com.adobe.csxs.events.ThemeColorChanged", themeChangedEventListener);

    /* store the original background image's path */
    imageURL = document.getElementById("index_body").style.backgroundImage;

    checkNodeJS();

    changeThemeColor(); 

    console.log("*** TEST LOG MSG ***");
    console.warn("*** TEST LOG MSG WARN ***");
    console.error("*** TEST LOG MSG ERROR ***");
};

2) I then copied all of the Extension files into my "user home" CEP Extension folder: C:\Users\bwaldsmith\AppData\Roaming\Adobe\CEP\extensions\com.adobe.CEPHTMLTEST

3) I triple-checked that the Registry settings for Log Level were set as expected: Computer\HKEY_CURRENT_USER\SOFTWARE\Adobe\CSXS.9\LogLevel is 6 (PlayerDebugMode is also set to 1) Computer\HKEY_CURRENT_USER\SOFTWARE\Adobe\CSXS.11\LogLevel is 6 (PlayerDebugMode is also set to 1) (I don't think it matters, but the keys for CSXS.7, CSXS.8, CSXS.10, and CSXS.12 are set up the same way too)

4) I started Illustrator and opened the extension (Windows -> Extensions -> CEP HTML Test Panel 1). I did this with both Illustrator 2020 (v24.3, CEP 9) and Illustrator 2024 (v28.7.1, CEP 11).

5) I examined the log files in [USERHOME]/AppData/Local/Temp :

Results For CEP 9, the CEPHtmlEngine9-ILST-24.3.0-com.adobe.CEPHTMLTEST.Panel1.log log file shows the test console.log messages from the extension. The CEP9-ILST.log file is also showing DEBUG/TRACE level messages

For CEP 11, the CEPHtmlEngine11-ILST-28.7.1-com.adobe.CEPHTMLTEST.Panel1.log file does NOT show the test console.log messages. However, the CEP11-ILST.log IS showing DEBUG/TRACE level messages.

Expected Behavior The CEP 11 extension log should show Extension console.log messages just like is done for CEP 9.

Is there some other setting, like a CEF Command Line parameter or other Registry change that is needed to make this work for CEP 11? Or is it a defect?

ErinFinnegan commented 1 month ago

Hi @BrianWCSI,

This is a very well-written bug report! Thanks, I appreciate it. (Really!)

That said, I think this bug will get much more traction if you post it in the Illustrator prerelease forum: https://www.adobeprerelease.com/beta/85A6F544-2705-49BD-8314-DD549C6A1713/feedback/home - I know it's not quite an Illustrator-specific problem but they will route it to the correct team. The handy thing about reporting there is that you will be able to follow the JIRA ticket and continue to comment on it.

You can copy and paste pretty much everything above. (I know I could do the same, but you wouldn't get notifications until I relay them to you.)

It's also handy if you mention in the Feedback form how many users you have, or how the broad effect on CEP developers.

BrianWCSI commented 1 month ago

Hi @ErinFinnegan .

Thanks for the comment and suggestion. I will log the ticket there as well and include a note about customer base impact and developer impact.

I also noticed that this issue is also reproducible using the HTML Test Extension with Photoshop (I tried v22.2, 24.7.5, and the latest 25.12). I didn't have an old enough version to try one with CEP 9, but the versions with CEP 10, CEP 11, and CEP 12 showed the same logging behavior as described with Illustrator.

I assume though it's still OK to use the Illustrator Prerelease route for logging the ticket, to at least get it in the system? Even though the issue doesn't seem limited to Illustrator?

Thanks!

ErinFinnegan commented 1 month ago

Woops, I didn't answer your question (then I was at MAX):

I assume though it's still OK to use the Illustrator Prerelease route for logging the ticket, to at least get it in the system? Even though the issue doesn't seem limited to Illustrator?

Yes, I believe I said that:

I know it's not quite an Illustrator-specific problem but they will route it to the correct team.

BrianWCSI commented 1 month ago

Hi @ErinFinnegan . No problem, and thanks for the reply. I did log the ticket in the Prerelease system a couple weeks ago, although so far I have not seen any response to it. Thanks!