New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 789242 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Nov 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Chrome , Mac
Pri: 1
Type: Bug

Blocking:
issue 780164



Sign in to add a comment

[MD Extensions] Manifest errors not displayed.

Project Member Reported by dpa...@chromium.org, Nov 28 2017

Issue description

I am observing differences between old vs new UI, as well as enable-error-console vs disable-error-console, which look like a bug to me.

See screenshots:
Case 1: Old UI, disabled error console. Manifest errors are shown.
Case 2: Old UI, enabled error console. Manifest errors are not shown.
Case 3,4: New UI. Manifest errors not show either way.

Aren't manifest errors supposed to be surfaced somehow in all cases?
 
old_ui_disabled_error_console.png
53.5 KB View Download
old_ui_enabled_error_console.png
19.8 KB View Download
new_ui_disabled_error_console.png
13.8 KB View Download
new_ui_enabled_error_console.png
13.7 KB View Download
It's strange to me that the old UI doesn't show the manifest errors if error console's enabled. If I had to guess, the intention might be to show the "ERROR" button instead of embedding the errors directly in the card, but for some logical bug the "ERROR" button is not shown either.
Hmm... On both the old and new UI, the manifest errors are shown for me in the error console (which is enabled).

Agreed that the new UI *without* error console will not display these.
Selection_410.png
67.6 KB View Download
Selection_411.png
47.9 KB View Download

Comment 3 by dpa...@chromium.org, Nov 29 2017

@Devlin: It seems that the observed behavior is different across the two following extensions?

1) The one I used https://cs.chromium.org/chromium/src/chrome/test/data/extensions/error_console/runtime_and_manifest_errors/
2) The one you used, which I am guessing is a local modification of https://cs.chromium.org/chromium/src/chrome/test/data/extensions/error_console/manifest_warnings/manifest.json ?
They both seem to work for me?

I'm on Linux, tip-ish of tree (sync'd Tuesday).
Selection_412.png
42.6 KB View Download
Selection_413.png
86.3 KB View Download

Comment 5 by dpa...@chromium.org, Nov 29 2017

@Devlin: Are you passing --disable-error-console in the command line?
No - from #2:
> Hmm... On both the old and new UI, the manifest errors are shown for me in the error console (which is enabled).

> Agreed that the new UI *without* error console will not display these.

If error console is disabled, then errors not showing in the error console is WAI :)  (though, again, it does mean we'll need to surface them somehow differently... or shard error console's behavior /shudder/)

Comment 7 by dpa...@chromium.org, Nov 29 2017

The current plan is to launch without the error console, which means users on stable and beta will be seeing the result as if --disable-error-console is passed. So to summarize, if

1) using --disable-error-console
2) using MD version
3) attempt to install https://cs.chromium.org/chromium/src/chrome/test/data/extensions/error_console/runtime_and_manifest_errors/

I don't see any manifest errors anywhere on the page. @devlin, can you reproduce this? 

Comment 8 by dpa...@chromium.org, Nov 29 2017

> errors not showing in the error console is WAI

I see. This was not my expectation. I thought error console was only about runtime errors, not about manifest errors.
Cc: bettes@chromium.org
Yeah, the error console is designed to show all errors (manifest and runtime) when it's enabled.  In the old UI, this means replacing the existing manifest errors display (the pink blocks) and adding runtime errors.  In the new UI, it's all we had, so we'll need to figure something out for manifest errors.

How far from ready is the error console?  If most of the features we're worried about are related only to runtime errors, and the manifest error coverage is decent, then perhaps we can enable it just for manifest errors?  It will be a bit of a nasty hack (gating whether to log a certain type of error based on MD extensions flag), but may or may not be worse than trying to think up a new UI...

+bettes@
> How far from ready is the error console?

My assessment is that is still a bit far, at least when it comes to displaying arbitrary runtime errors. From a quick search of the codebase see related bugs:

https://bugs.chromium.org/p/chromium/issues/detail?id=781335
https://bugs.chromium.org/p/chromium/issues/detail?id=781316
https://bugs.chromium.org/p/chromium/issues/detail?id=783961
https://bugs.chromium.org/p/chromium/issues/detail?id=781410

Having said that, if we are only showing manifest errors, some of these (if not all) might not be a problem. Given our current main page UI (meaning the card layout which has limited space), I think showing manifest errors in the errors view, even when --disable-error-console is in effect, is reasonable.
Would it be reasonable for the Errors button to open the manifest error dialog instead of using the errors page?
Owner: dpa...@chromium.org
Status: Assigned (was: Untriaged)
>  It will be a bit of a nasty hack (gating whether to log a certain type of error based on MD extensions flag)

@Devlin: I don't think this hack is necessary. The code reports errors differently based on the enabled/disabled status of the error console.

When --disable-error-console: The errors are reported as |installWarnings|.
When --enable-error-console: |installWarnings| are empty and |manifestErrors| are populated.

Which means that I can (maybe?) leverage the existing |installWarnings| and show them in the error view of MD Extensions (hopefully that will not be too hard). WDYT?
@dschuyler: FYI, I am trying the suggestion at comment #11.
Blocking: 780164
Still working on some polish, but basically the approach that seems the most viable is to show the installation warnings on a new dialog, see screenshot.

I am still working on the CL, and hopefully it can be landed before the M64 cutoff.
show_manifest_errors.mp4
510 KB View Download
@14 I like it. +1
Status: Started (was: Assigned)
CL in review at https://chromium-review.googlesource.com/c/chromium/src/+/798799.
Project Member

Comment 17 by bugdroid1@chromium.org, Nov 30 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8926416ef093507a2b996b172f632dc1d019f297

commit 8926416ef093507a2b996b172f632dc1d019f297
Author: dpapad <dpapad@chromium.org>
Date: Thu Nov 30 19:52:13 2017

MD Extensions: Display installation warnings when error console is disabled.

Bug:  789242 
Cq-Include-Trybots: master.tryserver.chromium.linux:closure_compilation
Change-Id: I6c379b49dc444a786a5afa597c306d69f5a43841
Reviewed-on: https://chromium-review.googlesource.com/798799
Commit-Queue: Demetrios Papadopoulos <dpapad@chromium.org>
Reviewed-by: Devlin <rdevlin.cronin@chromium.org>
Reviewed-by: Dave Schuyler <dschuyler@chromium.org>
Cr-Commit-Position: refs/heads/master@{#520649}
[modify] https://crrev.com/8926416ef093507a2b996b172f632dc1d019f297/chrome/browser/resources/md_extensions/compiled_resources2.gyp
[modify] https://crrev.com/8926416ef093507a2b996b172f632dc1d019f297/chrome/browser/resources/md_extensions/extensions_resources.grd
[add] https://crrev.com/8926416ef093507a2b996b172f632dc1d019f297/chrome/browser/resources/md_extensions/install_warnings_dialog.html
[add] https://crrev.com/8926416ef093507a2b996b172f632dc1d019f297/chrome/browser/resources/md_extensions/install_warnings_dialog.js
[modify] https://crrev.com/8926416ef093507a2b996b172f632dc1d019f297/chrome/browser/resources/md_extensions/item.js
[modify] https://crrev.com/8926416ef093507a2b996b172f632dc1d019f297/chrome/browser/resources/md_extensions/manager.html
[modify] https://crrev.com/8926416ef093507a2b996b172f632dc1d019f297/chrome/browser/resources/md_extensions/manager.js
[modify] https://crrev.com/8926416ef093507a2b996b172f632dc1d019f297/chrome/browser/ui/webui/extensions/extensions_ui.cc

Status: Fixed (was: Started)
This made it into the m64 branch.

Sign in to add a comment