Mailspring icon indicating copy to clipboard operation
Mailspring copied to clipboard

Error: Failed to execute 'setStart' on 'Range': The offset 4294967295 is larger than the node's length (1).

Open Lyptik opened this issue 8 years ago • 22 comments

Hello team !

spec : win10 mailspring : 1.5.1-da141eaf with dark theme

I always had this behavior from Mailspring :

  • write a mail (by answering on the quic reply form)
  • just write and go in the mail, and then sometimes randomly I have this (screenshot attached)
  • impossible to recover, so I have to restard mailspring (I don't loose what I wrote though)

It happens now more than before, but also the error message change : Error: Failed to execute 'setStart' on 'Range': The offset 4294967295 is larger than the node's length (1).

Please fix this, it's incredibly annoying :)

All the best,

image

Lyptik avatar Oct 29 '18 10:10 Lyptik

ugh.. this just hit me too..

Error: Failed to execute 'setStart' on 'Range': The offset 4294967294 is larger than the node's length (1).
    at findDOMRange (/usr/share/mailspring/resources/app.asar/node_modules/slate-react/lib/utils/find-dom-range.js:37:5)
    at Content._this.updateSelection (/usr/share/mailspring/resources/app.asar/node_modules/slate-react/lib/components/content.js:154:46)
    at Content._this.componentDidUpdate (/usr/share/mailspring/resources/app.asar/node_modules/slate-react/lib/components/content.js:121:13)
    at Hi (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:227:383)
    at Fi (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:218:212)
    at Gi (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:217:174)
    at Ki (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:232:135)
    at de (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:85:207)

image

Arch Linux MailSpring 1.5.2-31660462 (would be helpful if i could copy-paste the version instead of typing it :D )

I took the log out of the console also: https://pastebin.com/tEqZw8fW

KristerV avatar Nov 12 '18 15:11 KristerV

happens in average once every one or two days for me (yes I write a lots of mails !)

Lyptik avatar Nov 12 '18 15:11 Lyptik

Ditto: Error: Failed to execute 'setStart' on 'Range': The offset 4294967294 is larger than the node's length (109). at findDOMRange (/usr/share/mailspring/resources/app.asar/node_modules/slate-react/lib/utils/find-dom-range.js:37:5) at Content._this.updateSelection (/usr/share/mailspring/resources/app.asar/node_modules/slate-react/lib/components/content.js:154:46) at Content._this.componentDidUpdate (/usr/share/mailspring/resources/app.asar/node_modules/slate-react/lib/components/content.js:121:13) at Hi (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:227:383) at Fi (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:218:212) at Gi (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:217:174) at Ki (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:232:135) at de (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:85:207)

Lose steps to repeat:

  1. Begin editing the email inline (not as a pop-out).
  2. Navigate using the keyboard arrow-keys (often the up key causes this for me).

I'm using a custom theme, so I'm not sure it has anything to do with the dark-theme.

Most similar to https://github.com/Foundry376/Mailspring/issues/1080

Also using Manjaro Gnome. Mailspring version 1.5.3-420ce003

klawson4311 avatar Nov 26 '18 18:11 klawson4311

+1, same steps and dark theme as well

Le lun. 26 nov. 2018 à 19:55, klawson4311 [email protected] a écrit :

Ditto: Error: Failed to execute 'setStart' on 'Range': The offset 4294967294 is larger than the node's length (109). at findDOMRange (/usr/share/mailspring/resources/app.asar/node_modules/slate-react/lib/utils/find-dom-range.js:37:5) at Content._this.updateSelection (/usr/share/mailspring/resources/app.asar/node_modules/slate-react/lib/components/content.js:154:46) at Content._this.componentDidUpdate (/usr/share/mailspring/resources/app.asar/node_modules/slate-react/lib/components/content.js:121:13) at Hi (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:227:383) at Fi (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:218:212) at Gi (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:217:174) at Ki (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:232:135) at de (/usr/share/mailspring/resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:85:207)

Lose steps to repeat:

  1. Begin editing the email inline (not as a pop-out).
  2. Navigate using the keyboard arrow-keys (often the up key causes this for me).

I'm using a custom theme, so I'm not sure it has anything to do with the dark-theme.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Foundry376/Mailspring/issues/1190#issuecomment-441754794, or mute the thread https://github.com/notifications/unsubscribe-auth/AE7tceiyuxpTRXFRDq6BJoqNPdqLmSHUks5uzDkugaJpZM4X-4d8 .

Lyptik avatar Nov 26 '18 19:11 Lyptik

Happens to me as well, but not in the dark theme. Both on Linux (Ubuntu 18.04.1 LTS) and Windows (10, don't remember the build right now). All my systems seem to be affected by this issue.

Mailspring Version: 1.5.3-420ce003

rgsilva avatar Dec 04 '18 17:12 rgsilva

This error has haunted me for a little while now.

This occurred while navigating around using the keyboard while finishing writing a reply which has been a draft for a few days.

Mailspring version 1.5.3 Theme Light OS macOS Mojave (10.14.1)

Error: Failed to execute 'setStart' on 'Range': The offset 4294967295 is larger than the node's length (1).
    at findDOMRange (/Applications/Mailspring.app/Contents/Resources/app.asar/node_modules/slate-react/lib/utils/find-dom-range.js:37:5)
    at Content._this.updateSelection (/Applications/Mailspring.app/Contents/Resources/app.asar/node_modules/slate-react/lib/components/content.js:154:46)
    at Content._this.componentDidUpdate (/Applications/Mailspring.app/Contents/Resources/app.asar/node_modules/slate-react/lib/components/content.js:121:13)
    at Hi (/Applications/Mailspring.app/Contents/Resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:227:383)
    at Fi (/Applications/Mailspring.app/Contents/Resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:218:212)
    at Gi (/Applications/Mailspring.app/Contents/Resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:217:174)
    at Ki (/Applications/Mailspring.app/Contents/Resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:232:135)
    at de (/Applications/Mailspring.app/Contents/Resources/app.asar/node_modules/react-dom/cjs/react-dom.production.min.js:85:207)

danieldraper avatar Dec 13 '18 00:12 danieldraper

Same here on Ubuntu 18.04

tonypartridge avatar Dec 14 '18 11:12 tonypartridge

I just got this error on Debian. Mailspring v1.5.3.

bennlich avatar Dec 19 '18 03:12 bennlich

Also happening on Ubuntu Budgie 18.04, don't think it's OS dependent

jacobbarrow avatar Jan 02 '19 15:01 jacobbarrow

This seems to be a bug in slate. May be https://github.com/ianstormtaylor/slate/issues/1874 or https://github.com/ianstormtaylor/slate/issues/1696.

bennlich avatar Jan 21 '19 07:01 bennlich

This happened ob both linux and windows to me

Dudo1985 avatar Jan 27 '19 18:01 Dudo1985

same...

Sent from Mailspring (https://getmailspring.com/), the best free email app for work On Jan 27 2019, at 6:26 pm, Dario Curvino [email protected] wrote:

This happened ob both linux and windows to me

— You are receiving this because you commented. Reply to this email directly, view it on GitHub (https://github.com/Foundry376/Mailspring/issues/1190#issuecomment-457941733), or mute the thread (https://github.com/notifications/unsubscribe-auth/ABVglsU0sbaXEvlUf74uocwWq0zYDxcmks5vHe9vgaJpZM4X-4d8).

tonypartridge avatar Jan 28 '19 09:01 tonypartridge

Just happened to me on linux :(

fquinner avatar Feb 13 '19 12:02 fquinner

Same here. Another way to reproduce this problem is in: https://github.com/Foundry376/Mailspring/issues/727#issuecomment-462114521

ayala-io avatar Feb 14 '19 14:02 ayala-io

As a work around I discovered if you toggle the reading pane off then on again the error will be cleared.

  1. View -> Reading Pane Off
  2. View -> Reading Pane On

Hopefully that helps until the bug can be fixed.

Mail Spring version: 1.5.6-4cb1851b

jcrawford888 avatar Feb 25 '19 17:02 jcrawford888

Hi there. This just happened to me. I'm running Ubuntu 18.04 and yesterday I updated to 1.5.7 via .deb While writing a reply, I hit the up arrow key and the view/reply panel now shows nothing but this message (until I restart Mailspring), any mail I choose, the view panel shows that message.

tincho avatar Feb 26 '19 13:02 tincho

As a work around I discovered if you toggle the reading pane off then on again the error will be cleared.

  1. View -> Reading Pane Off
  2. View -> Reading Pane On

@jcrawford888 Unfortunately, the above didn't work for me in clearing the error in MailSpring 1.5.7-2057ca30 on Windows 10. Have to restart it.

ayala-io avatar Feb 27 '19 04:02 ayala-io

Unfortunately, this happens to me with a specific email containing some nested quotes (from a previous mail in the thread). Toggling the reading pane does clear the error when I'm focused on other mails, but even after a restart, this particular email keeps triggering the error. It doesn't contain any heavy images or whatever, it's just a text conversation in html format with quotes.

I'm using the Snap version of MailSpring 1.5.7-2057ca30 on Ubuntu 18.04.2 LTS running Gnome 3.28.2

aapit avatar Mar 06 '19 17:03 aapit

This is happening to me as well every now and then. Haven't noticed any pattern yet, it has happened when I am drafting an email or just reading.

Toggle reading pane on off clears the error.

I am on Ubuntu 18.04.1 LTS and using snap version of MailSpring 1.5.7-2057ca30

ASeatonSpatial avatar Mar 07 '19 10:03 ASeatonSpatial

Hey folks I'm going to merge this in to #921. I've been tracking this for a while and I'm hoping it can be fixed soon. The slate-react project that powers the text editor has come a long way, but there were a few performance regressions that were blocking us from upgrading. Will see if they've been resolved!

bengotow avatar Mar 17 '19 17:03 bengotow