Bug 460510 - Eclipse hang on very long-lined Java files.
Summary: Eclipse hang on very long-lined Java files.
Status: CLOSED WONTFIX
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 4.5   Edit
Hardware: PC Windows NT
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: JDT-Core-Inbox CLA
QA Contact: Manoj N Palat CLA
URL:
Whiteboard: stalebug
Keywords: needinfo
Depends on:
Blocks:
 
Reported: 2015-02-21 09:48 EST by Ed Willink CLA
Modified: 2020-02-01 10:30 EST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ed Willink CLA 2015-02-21 09:48:47 EST
M5a

I wrote a to-Unix line endings program for Java files, but accidentally wrote integer text rather than characters to the output file. As a result some *.java files contained very long sequences of digit characters.

Silly me. But Eclipse hangs. After killing and restarting I see an error log entry:

org.eclipse.core.runtime.AssertionFailedException: assertion failed: Marker property value is too long: Syntax error on token "11297991079710310132111114103461019910810511211510146113118116100461201161011201164611311811699111114101461171054699111110116101110116971151151051151164697110116108114461051101161011141109710859321010105109112111114116321069711897461051114673110112117116831161141019710959101051091121111141163211111410346101991081051121151014612011610112011646425910105109112111114116321111141034610199108105112115101461201161011201164611297114115101114464259101051091121111141163211111410346101991081051121151014612011610112011646112971141151011144610510911210846425910105109112111114116321111141034610199108105112115101461011091024610199111114101461171161051084669991111141018511610510859101051091121111141163211111410346101991081051121151014610110910246101991111141014669799810610199116591010510911211111411632111114103461019910810511211510146120116101120116461129711411510111446971101161081144688116101120116841111071011108311611410197109591010510911211111411632111114103461019910810511211510146120116101120116461129711411510111446971101161081144688116101120116841111071011108311611410197109467210510010010111084111107101110115591010510911211111411632111114103461019910810511211510146120116101120116461051001014610110010511611111446991111101161011101169711511510511511646971101161081144610511011610111411097108466598115116114979911673110116101114110971086711111011610111011665115115105115116809711411510111459101051091121111141163211111410346101991081051121151014612011610112011646105100101461011001051161111144699111110116101110116971151151051151164697110116108114461051101161011141109710846687065591010510911211111411632111114103461019910810511211510146113118116100461201161011201164611311811699111114101461151011141181059910111546818684991111141017111497109109971146599991011151155910101010105109112111114116321111141034697110116108114461141171101161051091014642591010510911211111411632106971189746117116105108468311697991075910105109112111114116321069711897461171161051084676105115116591010510911211111411632106971189746117116105108466511411497121761051151165910105109112111114116321069711897461171161051084677971125910105109112111114116321069711897461171161051084672971151047797112591064831171121121141011151158797114110105110103115403497108108344110112117981081059932991089711511532731101161011141109710881868499111114101809711411510111432101120116101110100115326598115116114979911673110116101114110971086711111011610111011665115115105115116809711411510111432123103232323211211798108105993211511697116105993210210511097108328311611410511010391933211611110710111078971091011153261321101011193283116114105110103919332123103232323232323232346010511011897108105100623444323460697982623444323460687987786234443234608580623444323482857669957378843444323482857669958373787176699581857984696895838482737871344432348285766995837377807669957368344432348285766995698367658069689573683444323482857669956983676580696895677265826567846982344432348285766995766984846982956772658265678469823444323482857669956879856676699581857984696895838482737871344432348285766995777695837378717669958185798469689583848273787134443234828576699577769567797777697884344432348285766995837695677977776978843444323482857669958783344432348285766995657889957984726982344432343959393444323439991041019910739344432343910111010211111499101393444323439105109112111114116393444323439105109112111114116115393444323439108105981149711412139344432343910997112393444323439113117101114121393444323439114101971081051221013934443234391141011021051101011153934443234391161149711011510211111410997116105111110393444323439117115101115393444323439453934443234391101111163934443234394239344432343947393444323439433934443234396239344432343960393444323439626139344432343960613934443234396139344432343960623934443234399711010039344432343911111439344432343912011111439344432343910510911210810510111539344432343946393444323439456239344432343963463934443234396345623934443234398411711210810139344432343966111111108101971103934443234397311011610110310111439344432343982101971083934443234398311611410511010339344432343985110108105109105116101100789711611711497108393444323439799910865110121393444323439799910873110118971081051003934443234397999108861111051003934443234398310111639344432343966971033934443234398310111311710111099101393444323439671111081081019911610511111039344432343979114100101114101100831011163934443234396339344432343912339344432343912539344432343910511039344432343944393444323439119104101114101393444323439124393444323439586139344432343940393444323439413934443234395839344432343958583934443234394646393444323439434339344432343976971099810097393444323439105110118971081051003934443234391101171081083934443234391121141013934443234399139344432343993393444323439105102393444323439116104101110393444323439101108115101393444323439101110100105102393444323439101108115101105102393444323439108101116393444323439115101108102393444323439101120116101110100115393444323439383839344432343911511711210111439344432343910010110297117108116393444323439116114117101393444323439102971081151013934443234396439341032323232125591032323232112117981081059932115116971161059932102105110971083210511011632849595505761505759103232323211211798108105993211511697116105993210210511097108321051101163284959550566150565910323232321121179810810599321151169711610599321021051109710832105110116328495955055615055591032323232112117981081059932115116971161059932102105110971083210511011632849595505461505459103232323211211798108105993211511697116105993210210511097108321051101163284959550536150535910323232321121179810810599321151169711610599321021051109710832105110116328285766995698367658069689567726582656784698261565910323232321121179810810599321151169711610599321021051109710832105110116328495955052615052591032323232112117981081059932115116971161059932102105110971083210511011632849595505161505159103232323211211798108105993211511697116105993210210511097108321051101163284959550506150505910323232321121179810810599321151169711610599321021051109710832105110116328285766995657889957984726982614953591032323232112117981081059932115116971161059932102105110971083210511011632849595504961504959103232323211211798108105993211511697116105993210210511097108321051101163284959550486150485910323232321121179810810599321151169711610599321021051109710832105110116328285766995698367658069689573686155591032323232112117981081059932115116971161059932102105110971083210511011632828576699568798566766995818579846968958384827378716149485910323232321121179810810599321151169711610599321021051109710832105110116326979706145495910323232321121179810810599321151169711610599321021051109710832105110116328495955751615751591032323232112117981081059932115116971161059932102105110971083210511011632849595495761495759103232323211211798108105993211511697116105993210210511097108321051101163284959557526157525910323232321121179810810599321151169711610599321021051109710832105110116328495955749615749591032323232112117981081059932115116971161059932102105110971083210511011632849595575061575059103232323211211798108105993211511697116105993210210511097108321051101163284959549546149545910323232321121179810810599321151169711610599321021051109710832105110116328495955748615748591032323232112117981081059932115116971161059932102105110971083210511011632849595495661495659103232323211211798108105993211511697116105993210210511097108321051101163284959549556149555910323232321121179810810599321151169711610599321021051109710832105110116328285766995837377807669957368615459103232323211211798108105993211511697116105993210210511097108321051101163284959556486156485910323232321121179810810599321151169711610599321021051109710832105110116328495955649615649591032323232112117981081059932115116971161059932102105110971083210511011632849595565061565059103232323211211798108105993211511697116105993210210511097108321051101163284959556516156515910323232321121179810810599321151169711610599321021051109710832105110116328285766995837378717669958185798469689583848273787161535910323232321121179810810599321151169711610599321021051109710832105110116328495955653615653591032323232112117981081059932115116971161059932102105110971083210511011632849595565261565259103232323211211798108105993211511697116105993210210511097108321051101163284959556556156555910323232321121179810810599321151169711610599321021051109710832105110116328495955654615654591032323232112117981081059932115116971161059932102105110971083210511011632849595565761565759103232323211211798108105993211511697116105993210210511097108321051101163284959556566156565910323232321121179810810599321151169711610599321021051109710832105110116328285766995766984846982956772658265678469826157591032323232112117981081059932115116971161059932102105110971083210511011632828576699577769567797777697884614950591032323232112117981081059932115116971161059932102105110971083210511011632849595554961554959103232323211211798108105993211511697116105993210210511097108321051101163284959555506155505910323232321121179810810599321151169711610599321021051109710832105110116328495955548615548591032323232112117981081059932115116971161059932102105110971083210511011632849595555461555459103232323211211798108105993211511697116105993210210511097108321051101163284959555536155535910323232321121179810810599321151169711610599321021051109710832105110116328495955552615552591032323232112117981081059932115116971161059932102105110971083210511011632849595555161555159103232323211211798108105993211511697116105993210210511097108321051101163284959555576155575910323232321121179810810599321151169711610599321021051109710832105110116328495955556615556591032323232112117981081059932115116971161059932102105110971083210511011632849595555561555559103232323211211798108105993211511697116105993210210511097108321051101163284959554566154565910323232321121179810810599321151169711610599321021051109710832105110116328495955457615457591032323232112117981081059932115116971161059932102105110971083210511011632849595545461545459103232323211211798108105993211511697116105993210210511097108321051101163
	at org.eclipse.core.runtime.Assert.isTrue(Assert.java:110)
	at org.eclipse.core.internal.resources.MarkerInfo.checkValidAttribute(MarkerInfo.java:64)
	at org.eclipse.core.internal.resources.MarkerInfo.setAttribute(MarkerInfo.java:149)
	at org.eclipse.core.internal.resources.MarkerInfo.setAttributes(MarkerInfo.java:183)
	at org.eclipse.core.internal.resources.Marker.setAttributes(Marker.java:282)
	at org.eclipse.jdt.internal.core.builder.AbstractImageBuilder.storeProblemsFor(AbstractImageBuilder.java:780)
	at org.eclipse.jdt.internal.core.builder.BatchImageBuilder.storeProblemsFor(BatchImageBuilder.java:309)
	at org.eclipse.jdt.internal.core.builder.AbstractImageBuilder.updateProblemsFor(AbstractImageBuilder.java:838)
	at org.eclipse.jdt.internal.core.builder.AbstractImageBuilder.acceptResult(AbstractImageBuilder.java:131)
	at org.eclipse.jdt.internal.compiler.Compiler.processCompiledUnits(Compiler.java:531)
	at org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:453)
	at org.eclipse.jdt.internal.core.builder.AbstractImageBuilder.compile(AbstractImageBuilder.java:367)
	at org.eclipse.jdt.internal.core.builder.BatchImageBuilder.compile(BatchImageBuilder.java:179)
	at org.eclipse.jdt.internal.core.builder.AbstractImageBuilder.compile(AbstractImageBuilder.java:304)
	at org.eclipse.jdt.internal.core.builder.BatchImageBuilder.build(BatchImageBuilder.java:61)
	at org.eclipse.jdt.internal.core.builder.JavaBuilder.buildAll(JavaBuilder.java:256)
	at org.eclipse.jdt.internal.core.builder.JavaBuilder.build(JavaBuilder.java:180)
	at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:730)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
	at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:205)
	at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:245)
	at org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:298)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
	at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:301)
	at org.eclipse.core.internal.events.BuildManager.basicBuildLoop(BuildManager.java:357)
	at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:380)
	at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBuildJob.java:144)
	at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJob.java:239)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
Comment 1 Manoj N Palat CLA 2015-03-09 01:33:40 EDT
Unable to reproduce the hang with the given input line. Could you please attach one (or part) of those .java files which causes the hang?
Comment 2 Ed Willink CLA 2015-03-09 03:07:24 EDT
Maybe it's not just one bad marker but many; my stupid program was converting many files. The problem is in a builder and builders can be pretty stupid if they fail to build.

Just looking at the Javadoc:

	/**
	 * Returns whether the given object is a valid attribute value. Returns
	 * either the attribute or an equal canonical substitute.
	 */
	protected static Object checkValidAttribute(Object value) {

the subsequent Assert.isTrue(false, msg); is a violation.

Surely the marker should be trimmed, perhaps a log message entered, but the trimmed marker should be returned?


		if (value == null)
			return null;

is also a violation of the Javadoc contract. Surely there should be a NULL canonical substitute that is returned?
Comment 3 Eclipse Genie CLA 2020-02-01 10:30:59 EST
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.