- attached .idea.zip
Unable to view a number of files and get this error when trying to deploy a field that is not in project view.
I’m having a issue where I’m unable to see a number of files in the project view, in this case any file under the objects directory:
159358] INFO - odule.ModuleSubscriptionEditor - Writing updated package.xml contents to 'C:/Users/justinj/GRE Salesforce Phase One2/manifest/package.xml'.
2021-06-10 11:48:09,401 [78159545] INFO - pl.ProjectRootManagerComponent - some project roots were removed (stacktrace has been already reported with trace_hash = 174475415)
2021-06-10 11:48:19,633 [78169777] WARN - .IlluminatedCloudExceptionUtil - Cannot invoke "String.toUpperCase()" because "<local8>" is null
java.lang.NullPointerException: Cannot invoke "String.toUpperCase()" because "<local8>" is null
at com.illuminatedcloud.intellij.builder.ModuleContentsFilter.accept(SourceFile:104)
at com.illuminatedcloud.intellij.builder.AbstractForceComMetadataDeployer.deploy(SourceFile:247)
at com.illuminatedcloud.intellij.builder.ForceComBuilder.deployWithMetadataApi(SourceFile:1708)
at com.illuminatedcloud.intellij.builder.ForceComBuilder.build(SourceFile:1573)
at com.illuminatedcloud.intellij.builder.ForceComBuilder.buildForSave(SourceFile:1883)
at com.illuminatedcloud.intellij.builder.ForceComBuilder.buildForSave(SourceFile:1744)
at com.illuminatedcloud.intellij.builder.ForceComBuilder.buildForSave(SourceFile:1733)
at com.illuminatedcloud.intellij.builder.IlluminatedCloudSaveAllAction.lambda$actionPerformed$0(SourceFile:200)
at com.intellij.openapi.application.TransactionGuardImpl.runWithWritingAllowed(TransactionGuardImpl.java:218)
at com.intellij.openapi.application.TransactionGuardImpl.access$200(TransactionGuardImpl.java:21)
at com.intellij.openapi.application.TransactionGuardImpl$2.run(TransactionGuardImpl.java:200)
at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:781)
at com.intellij.openapi.application.impl.ApplicationImpl.lambda$invokeLater$4(ApplicationImpl.java:319)
at com.intellij.openapi.application.impl.FlushQueue.doRun(FlushQueue.java:84)
at com.intellij.openapi.application.impl.FlushQueue.runNextEvent(FlushQueue.java:133)
at com.intellij.openapi.application.impl.FlushQueue.flushNow(FlushQueue.java:46)
at com.intellij.openapi.application.impl.FlushQueue$FlushNow.run(FlushQueue.java:189)
at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:316)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:391)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:969)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:839)
at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$8(IdeEventQueue.java:449)
at com.intellij.openapi.progress.impl.CoreProgressManager.computePrioritized(CoreProgressManager.java:808)
at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$9(IdeEventQueue.java:448)
at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:781)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:496)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
2021-06-10 11:48:22,035 [78172179] INFO - mponents.impl.stores.StoreUtil - saveProjectsAndApp took 2442 ms
2021-06-10 11:48:23,378 [78173522] INFO - er.ForceComMetadataApiDeployer - Deployment status = SUCCEEDED
And then I get the above error when trying to deploy a field under one of those directories. I have the same project in another folder working ok.
Any ideas where this issue is coming from?
Comments (7)
-
reporter -
reporter Ok, I think I know now what happened.
The sfdx-project.json got mangled in a PR merge and then I merged develop into my branch (I tried running SFDX manually which gave me a validation error). I fixed up the sfdx-project.json and then reloaded the project and it now seems to have resolved the issue.
So, to help resolve this issue in the future - could you validate the sfdx-project.json and present an error to the user?
thanks
Justin
-
reporter Here was the mangled sfdx-project.json:
{ "packageDirectories": [ { "path": "force-app", "default": true, "dependencies": [ { "package": "Apex Mocks" }, { "package": "Utils" }, { "package": "Trigger Framework" } ], "package": "QICGRE", "versionNumber": "1.0.0" "default": true } ], "name": "Redacted", "namespace": "", "sfdcLoginUrl": "https://redacted.my.salesforce.com", "sourceApiVersion": "51.0", "signupTargetLoginUrl": "", "packageAliases": { "QIC Apex Mocks": "04t5m0000000d8AARR", "QIC Utils": "04t8t0000000RWVDDD", "QIC Trigger Framework": "04t5m0000000c6rCCC" },
-
repo owner Justin, the first stack trace is a legitimate NPE that I've fixed locally and will include in the next build. As for validating the
sfdx-project.json
file, let me reproduce the behavior you're seeing and hopefully there's already an error that's just being swallowed or sent only to logs that should instead be surfaced to the end user. -
repo owner Yup, there was an exception that gets logged but not presented to the user in this situation. Also, the null parsed project was cached without dependencies which is why you had to restart the IDE (or minimally close/reopen the project). I've fixed both of those behaviors for the next build and now the error is presented to the user:
and as soon as you fix the issue, IC picks up the now-valid information.
-
reporter Excellent! thanks!
-
repo owner - changed status to resolved
Delivered in 2.1.8.1.
- Log in to comment
Attached project definition files.