Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Command list generated with commands run after exception is displayed #190

Open
1 task
rsese opened this issue Apr 4, 2018 · 0 comments
Open
1 task
Labels

Comments

@rsese
Copy link

rsese commented Apr 4, 2018

Prerequisites

Not run in safe mode so we could use the command added to the init script to generate an error

Description

h/t @Ben3eeE for finding this comment - as mentioned by Lee in atom/atom#11690 (comment):

thank you for pointing out that the command list is generated when the Issue is submitted, not when the dialog is displayed

So when an error notification is displayed, the Commands section generated includes things you do after the dialog is displayed which can be misleading as Lee mentions further in that comment:

That's a bug we should fix ... it could be sending us down some blind alleys 😀

If you perform enough actions, the actual actions related to generating the error aren't shown since it seems like 16 commands are shown and the rest is truncated?

Steps to Reproduce

Add this to your init.coffee so you can generate an error h/t @lee-dohm:

atom.commands.add 'atom-workspace',
  'custom:throw-error': ->
    throw new Error
  1. Start Atom (not in safe mode so we can use the command above)
  2. From the command palette, run Custom: Throw Error (error notification shows at this point)
  3. Run some other commands e.g. use the command palette to Tree View: Toggle 6 times
  4. Copy the error report to clipboard (click the clipboard icon in the exception dialog)
  5. Paste the error report to examine the Commands section.

Expected behavior: [What you expect to happen]

To see commands up to when the error dialog is displayed.

Actual behavior: [What actually happens]

Commands run after the dialog is displayed are shown in the Commands section:

     -0:06.6.0 tree-view:toggle (input.hidden-input)
     -0:06.0 command-palette:toggle (input.hidden-input)
     -0:05.2.0 core:confirm (input.hidden-input)
     -0:05.2.0 tree-view:toggle (input.hidden-input)
     -0:04.8.0 command-palette:toggle (div.tool-panel.tree-view)
     -0:04.4.0 core:confirm (input.hidden-input)
     -0:04.4.0 tree-view:toggle (div.tool-panel.tree-view)
     -0:04.0 command-palette:toggle (input.hidden-input)
     -0:03.6.0 core:confirm (input.hidden-input)
     -0:03.6.0 tree-view:toggle (input.hidden-input)
     -0:03.0 command-palette:toggle (div.tool-panel.tree-view)
     -0:02.6.0 core:confirm (input.hidden-input)
     -0:02.6.0 tree-view:toggle (div.tool-panel.tree-view)
     -0:02.3.0 command-palette:toggle (input.hidden-input)
     -0:01.9.0 core:confirm (input.hidden-input)
     -0:01.9.0 tree-view:toggle (input.hidden-input)

For comparison, if I copy the error report right after step 2, then the generated Commands section looks like this:

     -0:03.1.0 command-palette:toggle (input.hidden-input)
     -0:01.8.0 core:confirm (input.hidden-input)
     -0:01.8.0 custom:throw-error (input.hidden-input)

Reproduces how often:

100%

Versions

$ atom -v
Atom    : 1.27.0-dev-8ef1a05f2
Electron: 1.7.11
Chrome  : 58.0.3029.110
Node    : 7.9.0

$ apm -v
apm  1.19.0
npm  3.10.10
node 6.9.5 x64
atom 1.27.0-dev-8ef1a05f2
python 2.7.10

macOS 10.12.6

/cc @Ben3eeE ✌️

@rsese rsese added the triaged label Apr 4, 2018
@rsese rsese changed the title Command list generated when issue submitted, not when exception displayed Command list not generated up to when exception is displayed Apr 4, 2018
@rsese rsese changed the title Command list not generated up to when exception is displayed Command list generated with commands run after exception is displayed Apr 4, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant