0 Replies Latest reply: Aug 26, 2013 7:21 AM by archont RSS

    Repeated NullPointerException in FB 4.7

    archont Community Member

      Hi,

       

      I've been having multiple problems with FB 4.7 - in one project, over the span of two weeks, I've had to deal with

       

      1) Bitmaps that do not have an alpba channell being silently skipped from the library.swc (fixed by forcing custom quality)

       

      2) Flash builder not presenting a password prompt during AIR publishing and then complaining about the non-password being incorrect (fixed by packaging using command line, later by resizing the window unttil it refreshes and shows the dialog)

       

      3) Flash builder constantly failing to compile, seemingly at random, throwing java NullPointerExceptions

       

      DescriptionResourcePathLocationType

      com.google.common.collect.ComputationException: java.lang.NullPointerException


      at com.google.common.collect.ComputingConcurrentHashMap$ComputingSegment.compute(ComputingCo ncurrentHashMap.java:167)

      at com.google.common.collect.ComputingConcurrentHashMap$ComputingSegment.compute(ComputingCo ncurrentHashMap.java:116)

      at com.google.common.collect.ComputingConcurrentHashMap.apply(ComputingConcurrentHashMap.jav a:67)

      at com.google.common.collect.MapMaker$ComputingMapAdapter.get(MapMaker.java:623)

      at com.adobe.flash.compiler.internal.projects.CompilerProject.getCacheForScope(CompilerProje ct.java:711)

      at com.adobe.flash.compiler.internal.scopes.ASScope.findPropertyQualified(ASScope.java:1476)

      at com.adobe.flash.compiler.internal.definitions.references.ResolvedQualifiersReference.reso lve(ResolvedQualifiersReference.java:80)

      at com.adobe.flash.compiler.internal.definitions.DefinitionBase.resolveType(DefinitionBase.j ava:1049)

      at com.adobe.flash.compiler.internal.definitions.DefinitionBase.resolveType(DefinitionBase.j ava:1089)

      at com.adobe.flash.compiler.internal.definitions.ClassDefinition.resolveBaseClass(ClassDefin ition.java:373)

      at com.adobe.flash.compiler.internal.definitions.TypeDefinitionBase$TypeIterator.pushChildre n(TypeDefinitionBase.java:284)

      at com.adobe.flash.compiler.internal.definitions.TypeDefinitionBase$TypeIterator.next(TypeDe finitionBase.java:218)

      at com.adobe.flash.compiler.internal.definitions.TypeDefinitionBase$TypeIterator.next(TypeDe finitionBase.java:176)

      at com.adobe.flash.compiler.internal.scopes.TypeScope.getPropertyForScopeChain(TypeScope.jav a:261)

      at com.adobe.flash.compiler.internal.scopes.ScopeView.getPropertyForScopeChain(ScopeView.jav a:71)

      at com.adobe.flash.compiler.internal.scopes.ASScope.findProperty(ASScope.java:1038)

      at com.adobe.flash.compiler.internal.scopes.ASScope.findProperty(ASScope.java:981)

      at com.adobe.flash.compiler.internal.scopes.ASScope.findProperty(ASScope.java:1161)

      at com.adobe.flash.compiler.internal.scopes.ASScope.findProperty(ASScope.java:919)

      at com.adobe.flash.compiler.internal.scopes.ASScopeCache.findPropertyQualified(ASScopeCache. java:267)

      at com.adobe.flash.compiler.internal.scopes.ASScope.findPropertyQualified(ASScope.java:1478)

      at com.adobe.flash.compiler.internal.definitions.references.ResolvedQualifiersReference.reso lve(ResolvedQualifiersReference.java:80)

      at com.adobe.flash.compiler.internal.definitions.DefinitionBase.resolveType(DefinitionBase.j ava:1049)

      at com.adobe.flash.compiler.internal.definitions.DefinitionBase.resolveType(DefinitionBase.j ava:1089)

      at com.adobe.flash.compiler.internal.definitions.DefinitionBase.resolveType(DefinitionBase.j ava:871)

      at com.adobe.flash.compiler.internal.definitions.DefinitionBase.resolveType(DefinitionBase.j ava:90)

      at com.adobe.flash.compiler.internal.tree.as.IdentifierNode.resolveType(IdentifierNode.java: 406)

      at com.adobe.flash.compiler.internal.tree.as.MemberAccessExpressionNode.resolveType(MemberAc cessExpressionNode.java:137)

      at com.adobe.flash.compiler.internal.semantics.MethodBodySemanticChecker.checkImplicitConver sion(MethodBodySemanticChecker.java:372)

      at com.adobe.flash.compiler.internal.semantics.MethodBodySemanticChecker.checkBinaryOperator (MethodBodySemanticChecker.java:324)

      at com.adobe.flash.compiler.internal.semantics.MethodBodySemanticChecker.checkBinaryOperator (MethodBodySemanticChecker.java:300)

      at com.adobe.flash.compiler.internal.as.codegen.ABCGeneratingReducer.checkBinaryOp(ABCGenera tingReducer.java:838)

      at com.adobe.flash.compiler.internal.as.codegen.ABCGeneratingReducer.binaryOp(ABCGeneratingR educer.java:799)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.action_448(CmcEmitter.java:6377)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.dispatchAction(CmcEmitter.java:92 11)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java: 39704)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduce(CmcEmitter.java:39681)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceSubgoals(CmcEmitter.java:39 723)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java: 39703)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduce(CmcEmitter.java:39681)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceSubgoals(CmcEmitter.java:39 723)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java: 39703)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.dispatchAction(CmcEmitter.java:95 19)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java: 39704)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduce(CmcEmitter.java:39681)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceSubgoals(CmcEmitter.java:39 732)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java: 39703)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduce(CmcEmitter.java:39681)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceSubgoals(CmcEmitter.java:39 723)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java: 39703)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduce(CmcEmitter.java:39681)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceSubgoals(CmcEmitter.java:39 732)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java: 39703)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduce(CmcEmitter.java:39681)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceSubgoals(CmcEmitter.java:39 723)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java: 39703)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduce(CmcEmitter.java:39681)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceSubgoals(CmcEmitter.java:39 732)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java: 39703)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduce(CmcEmitter.java:39681)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceSubgoals(CmcEmitter.java:39 723)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduceAntecedent(CmcEmitter.java: 39703)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.reduce(CmcEmitter.java:39681)

      at com.adobe.flash.compiler.internal.as.codegen.CmcEmitter.burm(CmcEmitter.java:39983)

      at com.adobe.flash.compiler.internal.as.codegen.ABCGenerator.generateInstructions(ABCGenerat or.java:232)

      at com.adobe.flash.compiler.internal.as.codegen.ABCGenerator.generateMethodBodyForFunction(A BCGenerator.java:397)

      at com.adobe.flash.compiler.internal.as.codegen.ABCGenerator.generateMethodBodyForFunction(A BCGenerator.java:351)

      at com.adobe.flash.compiler.internal.as.codegen.ABCGenerator.generateFunction(ABCGenerator.j ava:266)

      at com.adobe.flash.compiler.internal.as.codegen.ClassDirectiveProcessor.declareFunction(Clas sDirectiveProcessor.java:646)

      at com.adobe.flash.compiler.internal.as.codegen.DirectiveProcessor.processNode(DirectiveProc essor.java:215)

      at com.adobe.flash.compiler.internal.as.codegen.DirectiveProcessor.traverse(DirectiveProcess or.java:189)

      at com.adobe.flash.compiler.internal.as.codegen.GlobalDirectiveProcessor.declareClass(Global DirectiveProcessor.java:423)

      at com.adobe.flash.compiler.internal.as.codegen.DirectiveProcessor.processNode(DirectiveProc essor.java:207)

      at com.adobe.flash.compiler.internal.as.codegen.DirectiveProcessor.traverse(DirectiveProcess or.java:189)

      at com.adobe.flash.compiler.internal.as.codegen.GlobalDirectiveProcessor.declarePackage(Glob alDirectiveProcessor.java:449)

      at com.adobe.flash.compiler.internal.as.codegen.DirectiveProcessor.processNode(DirectiveProc essor.java:224)

      at com.adobe.flash.compiler.internal.as.codegen.DirectiveProcessor.traverse(DirectiveProcess or.java:189)

      at com.adobe.flash.compiler.internal.as.codegen.ABCGenerator.generate(ABCGenerator.java:126)

      at com.adobe.flash.compiler.internal.units.ASCompilationUnit.handleABCBytesRequest(ASCompila tionUnit.java:374)

      at com.adobe.flash.compiler.internal.units.CompilationUnitBase.processABCBytesRequest(Compil ationUnitBase.java:870)

      at com.adobe.flash.compiler.internal.units.CompilationUnitBase.access$300(CompilationUnitBas e.java:107)

      at com.adobe.flash.compiler.internal.units.CompilationUnitBase$4$1.call(CompilationUnitBase. java:309)

      at com.adobe.flash.compiler.internal.units.CompilationUnitBase$4$1.call(CompilationUnitBase. java:305)

      at com.adobe.flash.compiler.internal.units.requests.RequestMaker$1.call(RequestMaker.java:22 8)

      at com.adobe.flash.compiler.internal.units.requests.RequestMaker$1.call(RequestMaker.java:22 2)

      at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)

      at java.util.concurrent.FutureTask.run(Unknown Source)

      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)

      at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)

      at java.lang.Thread.run(Unknown Source)

      Caused by: java.lang.NullPointerException


      at com.google.common.base.Preconditions.checkNotNull(Preconditions.java:187)

      at com.google.common.collect.CustomConcurrentHashMap.hash(CustomConcurrentHashMap.java:1432)

      at com.google.common.collect.ComputingConcurrentHashMap.apply(ComputingConcurrentHashMap.jav a:66)

      at com.google.common.collect.MapMaker$ComputingMapAdapter.get(MapMaker.java:623)

      at com.adobe.flash.compiler.internal.scopes.ASProjectScope.addScopeToCompilationUnitScopeLis t(ASProjectScope.java:1306)

      at com.adobe.flash.compiler.internal.projects.CompilerProject$ScopeMakerFunction.apply(Compi lerProject.java:106)

      at com.adobe.flash.compiler.internal.projects.CompilerProject$ScopeMakerFunction.apply(Compi lerProject.java:95)

      at com.google.common.collect.ComputingConcurrentHashMap$ComputingSegment.compute(ComputingCo ncurrentHashMap.java:155)

      ... 89 moreRadialNavMenuMediator.as/ESEUM/src/ie/madrobot/eseum/view/mediatorline 22Flex Problem

       

       

      Curiously enough, the error seems to be mostly random - whenever it happens, I switch to FDT, do some work there - maybe add a couple classes, do some refactoring, and chances are the error will disappear, just like it appeared - out of nowhere, with no rhyme or reason. It may be renaming a class, it may be a day's work - eventually it does go away.

       

      Other things that may make the error disappear is commenting out the offending functions.

       

      Apparently FB 4.7 simply hates Vectors, as they are usually causing the exception. In particular a vector's length property.

       

      Project uses 1 lib and 1 src folder - no externally linked projects, although a different Flash Builder Pure Actionscript project is used with Flash CC to build a component library.

       

      Using AIR SDK 3.8. I am able to get a working air 3.8 package (occasionally) so the SDK is probably setup OK.

       

      I've run accross all sorts of odd bugs and quirks of Flash so I'm pretty forgiving - but 4.7 is a trainwreck.