Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

⬆️ Electron 3 (Take Two) #18916

Merged
merged 14 commits into from May 20, 2019

Conversation

Projects
None yet
9 participants
@jasonrudolph
Copy link
Member

commented Feb 26, 2019

Description of the Change

#18603 and #18815 upgraded Atom from Electron 2 to Electron 3, but we unfortunately experienced frequent crashes following those changes. As a short-term solution, #18908 reverted those changes.

This pull request restores the changes from #18603 and #18815. (It does so by reverting the changes from #18908.) Before we merge this pull request, we'll need to resolve the crashes that led to us having to revert the previous Electron 3 upgrade.

Issues to resolve

I think these issues are all caused by the upgrade to Electron 3. If we discover that they're not directly related to the Electron 3 upgrade, we can remove them from this list and address them separately.

Fixes #6666.
Fixes #18535.
Fixes atom/tabs#544

@Arcanemagus

This comment was marked as resolved.

Copy link
Member

commented Feb 26, 2019

#18840 also showed up with the Electron upgrade builds.

@jasonrudolph

This comment was marked as resolved.

Copy link
Member Author

commented Feb 27, 2019

#18840 also showed up with the Electron upgrade builds.

Thanks, @Arcanemagus. I've added it to the list in the PR body.

@carlos157oliveira

This comment was marked as spam.

Copy link

commented Mar 12, 2019

Hi, this is the first issue I've been assigned to triage by CodeTriage. This is still a issue? I see there is no recent activity. Would the maintainer consider closing this topic?

David Wilson and others added some commits Sep 7, 2018

@rafeca rafeca force-pushed the electron-3.1 branch from 211eb26 to 99af15e May 13, 2019

Show resolved Hide resolved package.json Outdated

jasonrudolph added some commits May 14, 2019

@jasonrudolph

This comment was marked as resolved.

Copy link
Member Author

commented May 14, 2019

Since Electron 3 uses Node 10, should this pull request update the build scripts to use Node 10?

For example, should we upgrade this build step to use Node 10?

steps:
- task: NodeTool@0
inputs:
versionSpec: 8.9.3
displayName: Install Node.js 8.9.3

@mfonville

This comment has been minimized.

Copy link
Contributor

commented May 16, 2019

Very happy to see that Atom based on Electron 3.x is finally near. I hope the upgrade to later versions will go faster, because Electron only supports the last 3 releases and the release of Electron 6.x (and thus EOL of 3.x) is expected on July 30th: https://electronjs.org/blog/12-week-cadence

@50Wliu

This comment has been minimized.

Copy link
Member

commented May 16, 2019

Here's some weird shifting of content that I'm seeing after opening and closing the dev tools.
slight-content-shifting

@as-cii

This comment has been minimized.

Copy link
Member

commented May 16, 2019

I also think we should consider looking into how text is being rendered in this new version before shipping it. Below you can find a zoomed-in screenshot of rendering the word Lorem in a variety of environments. Please, click on all of the images and quickly browse through the tabs to appreciate how stark the difference is for this pull request.

Atom on Electron 3 (this pull request)

Atom on Electron 3 0

VS Code on Electron 3 (latest published version)

VS Code

Atom on Electron 2 (Atom 1.38.0-beta0)

Atom on Electron 2 0

You can reproduce the above tests by using Fira Code Retina, 15px. I suspect some of the styling we do in TextEditorComponent is interacting oddly with the new Chromium version.

@jasonrudolph

This comment has been minimized.

Copy link
Member Author

commented May 16, 2019

I also think we should consider looking into how text is being rendered in this new version before shipping it.

Thanks, @as-cii. I've added this to the task list in the PR body.

@jasonrudolph

This comment was marked as resolved.

Copy link
Member Author

commented May 16, 2019

@50Wliu: It looks like you added this item to the task list in this PR body:

The "restarting search from the top" overlay icon in find-and-replace doesn't seem to show up

I want to make sure we address that item, but I don't understand what it means exactly. (Sorry.) Can you add a link that provides more detail or a gif that demonstrates the issue?

@50Wliu

This comment was marked as resolved.

Copy link
Member

commented May 17, 2019

@jasonrudolph Never mind, I just tested it again and it's working 😅. I forgot I needed to use it on a file that has a scrollbar.

@50Wliu

This comment was marked as outdated.

Copy link
Member

commented May 17, 2019

Okay, here's an actual regression. "Open link" (provided by the link package) no longer works.

Electron 3.1:
electron-3 1-broken-link

Electron 2.0 (Atom 1.37.0):
electron-2 0-working-link

@rafeca

This comment was marked as resolved.

Copy link
Contributor

commented May 17, 2019

Okay, here's an actual regression. "Open link" (provided by the link package) no longer works.

Thanks for reporting! I've created an issue for it: #19353

@rafeca

This comment was marked as resolved.

Copy link
Contributor

commented May 17, 2019

Okay, here's an actual regression. "Open link" (provided by the link package) no longer works.

I've done some investigation and this issue is not related to electron v3, since it's also present in current nightly versions of Atom which use electron v2 (more info in #19353), so I've removed it from the list of blocking issues for the upgrade.

@rafeca

This comment was marked as resolved.

Copy link
Contributor

commented May 17, 2019

Since this issue is appearing also on v1.38-beta0, I've added it to the list of release blockers

@as-cii as-cii marked this pull request as ready for review May 17, 2019

@as-cii

This comment has been minimized.

Copy link
Member

commented May 17, 2019

@rafeca and I think this pull request is ready to be merged. The sooner we do this, the more time we will have to catch bugs before it goes to Beta. Please, note that we are purposely ignoring #18915 for now because we haven't been able to reproduce it, and it's unclear how it would be related to the Electron upgrade.

Feedback on this is super welcome! Especially after this pull request gets merged, it would be useful to get as many 👀 on Nightly as possible to catch potential regressions that we didn't notice.

/cc: @atom/maintainers

@jasonrudolph

This comment has been minimized.

Copy link
Member Author

commented May 17, 2019

@rafeca and I think this pull request is ready to be merged.

Have you had a chance to run through the regression test plan? Once we've tested out all the items on that checklist, I'm 👍 on merging this pull request.

It's a pretty long checklist, so I'd be perfectly happy to divide and conquer with y'all.

@Arcanemagus

This comment has been minimized.

Copy link
Member

commented May 17, 2019

Note: The libgconf-2-4 dependency to be added in #19358 will need to be removed when this is merged, as Electron 3 doesn't require it.

@as-cii

This comment has been minimized.

Copy link
Member

commented May 20, 2019

Check for regressions experienced in previous upgrades

  • Verify that you can collaborate with Teletype
    • Host using Atom's current stable release can collaborate with guest using Atom with the new version of Electron
    • Guest using Atom's current stable release can collaborate with host using Atom with the new version of Electron
    • Host and guest can collaborate when both are using Atom with the new version of Electron
    Steps 1. Open a file 1. Share a portal 1. Have a guest join the portal 1. When guest edits the text in the file, verify that the host sees those changes

Text Input/Keybindings

See how to setup keyboard layouts.

  • IME not working (#14911)

    • macOS
    • Windows 10
    • Ubuntu
    Repro steps
    1. Install an IME layout, for example Pinyin simplified
    2. Open Atom and use the layout you installed as the keyboard layout
    3. Example, if you picked Pinyin simplified type in zhongwenshuru

    Expected: in Pinyin simplified 中文输入 is expected

    gif

    Issues we've seen: Only shows latin first character and not every character typed.

    gif

  • macOS: Key binding with composition characters are ignored (#15189)

    Repro steps
    1. Open your keymap.cson file and add the following:
      'atom-text-editor':
        # use hjkl; vim-like when pressing alt (word by word, paragraph by paragraph)
        # or alt (letter by letter)
        'alt-h': 'core:move-left'
        'alt-j': 'core:move-down'
        'alt-k': 'core:move-up'
        'alt-l': 'core:move-right'
    2. Save keymap.cson and reload atom.
    3. Try the new keymappings under ABC - Extended keyboard layout

    Expected: the keybindings work

    Issues we've seen: it types out the modified keys and ignores the key mapping

  • macOS: Composition characters mess up insertion point (#15344)

    Repro steps
    1. Open keymap.cson and add the following:
      'atom-text-editor':
        'alt-n': 'core:move-down'
        'alt-o': 'core:move-down'
    2. Have the following in your buffer:
      Foo
      Bar
      
    3. Have the cursor at the beginning of file(before F character) Type alt-n, then arrow right, then insert a character. Observe that the character is inserted at the beginning of the line (where the alt-n left you).
    4. Repeat steps using alt-o instead of alt-n.

    Expected: Both alt-o and alt-n behave the same

    Issues we've seen:
    bug

  • Ubuntu: Keystrokes involving ctrl resolve to the default layout instead of the active layout (#13170)

    Repro steps

    This should be tested on Linux with gnome

    1. Install a Linux ditro with gnome, for example Ubuntu
    2. Install French AZERTY and English US QWERTY layouts
    3. Change the default layout to be French AZERTY
    4. Open Atom and switch to English US QWERTY layout
    5. Press ctrl-w

    Expected: core:close to dispatch (Or the keybinding-resolver to resolve to ctrl-w). Should be resolving to the keyboard layout that is chosen and not the OS default layout.

    Issues we've seen: core:undo dispatched because it was resolved as ctrl-z because AZERTY has Z where W is on QWERTY.

  • Other keyboard layouts on new Electron version

UI

  • tree-view drag image (atom/tree-view#1054)

    • macOS
    • Windows 10
    • Ubuntu
    Repro steps
    1. Open a project in Atom with multiple files and a few folders
    2. Drag a file into a folder

    Expected:
    image

    Issues we've seen:

    image

  • drag-and-drop indicator (atom/tree-view#1055, atom/tabs#426, atom/tabs#437)

    • macOS
    • Windows 10
    • Ubuntu
    Repro steps
    1. Open Atom with a few folder projects on tree-view (you can do this on terminal in a directory that has existing folder and having a space between each folder. Example: atom folderA folderB folderC)
    2. Drag and drop all of the folders to reorder them on Atom

    Expected:
    The placeholder indicates where the folder/project is being dropped to.

    screen shot 2017-03-29 at 16 31 16

    Issues we've seen:
    No placeholder shows up after drag and dropping

    screen shot 2017-03-29 at 16 30 51

  • Large file rendering (#16591)

    • macOS
    • Windows 10
    • Ubuntu
    Repro steps
    1. Open a file that has over one million lines
    2. Scroll down to the bottom

    Expected: To not regress the number of lines that can be rendered. Rendering to be correct for lines past a certain point. Atom 1.25 can render around 800k to 1 million lines correctly.

    Issues we've seen: Increased number of lines rendered but bad rendering past a certain point

    bad renderer

  • Loss of subpixel AA when the cursor is at the end of long lines (#16889, #16595)

    • macOS
    • Windows 10
    • Ubuntu
    Repro steps
    1. Open text-editor.js in Atom
    2. Copy the first 21 lines to a new untitled window
    3. Turn on soft wrapping and change language mode to javascript
    4. Resize the Window so it's soft wrapped
    5. On line 15 type a until the you reach the end of the window

    Expected: To not lose subpixel AA

    Issues we've seen: Loss of subpixel AA. Both when soft wrapping was enabled and disabled.

    subpixel aa loss softwrap

  • Scrolling horizontally shift + scroll wheel (#12696 (comment))

    • macOS
    • Windows 10
    • Ubuntu
    Repro steps
    1. Open a file that has long lines
    2. Turn off soft wrapping and resize the window so you have a horizontal scrollbar
    3. Press shift and scroll in both directions using the mouse wheel

    Expected: File to scroll horizontally in both directions

    Issues we've seen: File does not scroll horizontally at all in any direction

  • Scrollbars misbehaving on the first file that is opened (#12696 (comment))

    Repro steps
    1. Open Atom
    2. Open some file that has content enough to have a vertical scrollbar
    3. Close Atom
    4. Open Atom and look at the vertical scrollbar

    Expected: Scrollbar to be visible

    Issues we've seen: Scrollbar is not visible and is flickering when you are editing

  • Middle clicking on unsaved tab (#15197)

    • macOS
    • Ubuntu
    Repro steps
    1. Open Atom and open a new unsaved file.
    2. Make edits to the unsaved file and middle click on the tab.

    Expected:
    Clicking save/cancel or the options on the dialog works.

    Issues we've seen:
    The UI and the dialog is unable to receive mouse clicks. You can still choose options via Keyboard, but not mouse.

  • Linux: Atom scrolls even when not focused (#15482)

    Repro steps
    1. Open Atom with a large enough file that has a scrollbar
    2. Open a different application and place it over the Atom window
    3. Scroll with the mouse inside the other window
    4. Focus the Atom window

    Expected: Atom window should keep the original scroll position

    Issues we've seen: The Atom window scrolls after it is focused

Other

  • Deprecation warnings (#12696 (comment))

    • macOS
    • Windows 10
    • Ubuntu
    Repro steps

    This should be tested on macOS, Linux and Windows with community packages installed

    1. Open Atom
    2. Open the Developer tools console on the master branch and check for deprecation warnings
    3. Open the Developer tools console on the electron upgrade branch and check for deprecation warnings
    4. Compare the two outputs

    Expected: No new deprecation warnings

    Issues we've seen: New deprecation warnings both from core and community packages

  • Supported Versions of OS (#15297)

    • macOS
    • Windows 10
    • Ubuntu
    Repro steps
    1. Check the list of supported platforms Electron Master
    2. Check what version is listed as minimum for each platform on https://atom.io and https://atom.io/faq

    Expected: https://atom.io and https://atom.io/faq to display the same versions as the Electron documentation

    Issues we've seen: macOS version support changed and https://atom.io and https://atom.io/faq was not updated

  • macOS : Native tabs (#14711)

    Repro steps
    1. Open two atom windows on mac
    2. Go to View in menus and check Show Tab Bar
      screen shot 2017-06-03 at 5 10 32 pm
    3. Do this for both Atom windows.
    4. Drag one atom window to the other via tab bar

    Expected:
    Native Tab bar shows up and able to drag different windows to each other. Also make sure UI isn't messed up.

    Issues we've seen:
    Native Tab Bar doesn't work and messes up UI when enabled

  • Ubuntu with KDE: Menu uses 100% CPU (electron/electron#8455, #13885) Omitted

    Repro steps
    1. Install Atom on Ubuntu KDE. [instructions]
    2. Enable KDE plasma global menu: Right-click on the desktop -> Add Panel => Application Menu Bar. [demo]
    3. Start Atom.
    4. Try to use the desktop menu.

    Expected:
    Desktop menu items work

    Issues we've seen:
    Desktop menu items do nothing when you click on things.

  • macOS: Slovak QWERTZ (atom/atom-keymap#223)

    Repro steps
    1. Install Slovak keyboard layout on mac
    2. Open keyboard viewer to see the keys are are suppose to show up and open keyboard resolver on atom.
    3. hit cmd+'.

    Expected: Resolves to cmd+' like it shows on keyboard viewer on mac.

    Issues we've seen: It resolves to ctrl+§

  • macOS: IME jump (#15696)

    Repro steps
    1. Install an IME layout, for example Chinese pinyin
    2. Type one character

    Expected:
    Expected the IME to be positioned at under the character you entered
    Issues we've seen: The IME window is in the top left corner. When you enter the second character it jumps to be positioned under the text

@rafeca

This comment has been minimized.

Copy link
Contributor

commented May 20, 2019

I've done the sanity checks on Linux and haven't found any regression related to this upgrade. I have some notes though about some items:

Large file rendering (#16591)

I've tried with a several million lines file and the editor becomes almost unresponsive (good thing is that Atom shows a warning saying that the file is too big and may cause issues with the editor). When I tried to scroll to ~800k line Atom ended up crashing.

This same behaviour happened on current Atom beta, so it's not an electron issue.

Scrolling horizontally shift + scroll wheel (#12696 (comment))

I'm not able to test this one because I don't have a wheel mouse.

Middle clicking on unsaved tab (#15197)

I'm not able to test this one because I don't have a wheel mouse.

@as-cii as-cii merged commit dc39210 into master May 20, 2019

4 checks passed

Atom Production Branches #1.39.0-dev+40690 succeeded
Details
Atom Pull Requests #20190516.1 succeeded
Details
continuous-integration/appveyor/branch AppVeyor build succeeded
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details

@as-cii as-cii deleted the electron-3.1 branch May 20, 2019

@nathansobo

This comment has been minimized.

Copy link
Contributor

commented May 20, 2019

Probable regression: #19372

nathansobo added a commit that referenced this pull request May 20, 2019

Revert "Merge pull request #18916 from atom/electron-3.1"
This reverts commit dc39210, reversing
changes made to e18559f.
@nathansobo

This comment has been minimized.

Copy link
Contributor

commented May 20, 2019

Hate to have to say this, but I reverted this in 3da827b due to crashes related to #19372. The saga continues.

@nathansobo nathansobo restored the electron-3.1 branch May 20, 2019

@as-cii as-cii deleted the electron-3.1 branch May 21, 2019

as-cii added a commit that referenced this pull request May 21, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.