"getInputStream() must not be called against a directory" when deploying a new Lightning component
I just saw this error when updating my org locally via IC from the latest in Git. It appears to be a recent behavioral change in the base IDE, though it's likely unveiling an IC bug that was previously masked.
Comments (19)
-
reporter -
reporter - changed status to resolved
Hotfix delivered in 2.0.5.4. So sorry for introducing this temporary regression! Please let me know if this doesn't resolve the issue for you.
-
Account Deactivated Works for me now. Thanks Scott!
-
reporter Thanks for confirming, Doug! Sorry again for the momentary blip.
-
How do I obtain this hotfix? Using v1.8.5.1 and getting this error. Appears to be due to space in the path?
Thanks.
-
reporter Jason, what you're seeing may be a different instance of the issue because the change that caused it in Illuminated Cloud 2 was not ever made in Illuminated Cloud 1. Can you please reproduce the error and attach the
idea.log
(Help>Show Log in Explorer/Finder/Files) so that I can see the details of the error? -
@Scott Wells
Here is the scrubbed idea.log (from today actually).
https://hydrostudios.box.com/s/boqccwjtlbbkz8zgk4vaz16vtobb9ryo
Let me know if you don’t have enough information. In reviewing the error and path, it doesn’t appear to be an issue with a space now. The path is a legitimate directory path.
-
reporter Thanks much, Jason. I think that gives me what I need. It appears that it's mishandling deployment of an email template folder and trying to treat it as a file instead of as a directory:
2019-07-01 18:12:05,125 [102396706] WARN - .IlluminatedCloudExceptionUtil - getInputStream() must not be called against a directory: file://d:/path/to/project/DevelopPro/src/email/name java.io.IOException: getInputStream() must not be called against a directory: file://d:/path/to/project/DevelopPro/src/email/name at com.intellij.openapi.vfs.newvfs.impl.VirtualDirectoryImpl.getInputStream(VirtualDirectoryImpl.java:679) at com.illuminatedcloud.intellij.builder.ForceComBuilderUtil.getFileContentsAsByteArray(SourceFile:1004) at com.illuminatedcloud.intellij.builder.ForceComMetadataApiDeployer.createDeploymentArchive(SourceFile:641) at com.illuminatedcloud.intellij.builder.ForceComMetadataApiDeployer.deployWithMetadataApi(SourceFile:257) at com.illuminatedcloud.intellij.builder.ForceComMetadataApiDeployer$1.run(SourceFile:184)
That's definitely been addressed in IC2, but IC2 is now so far from IC1 that I probably didn't ever back-port a version of the fix because it wasn't obvious that it needed to be merged.
I'm currently traveling but will take a look at it tomorrow and see if I can issue a quick-fix for you. In the interim the workaround would be to perform a selectively deployment that excludes that (and likely other) email template folder(s).
Thanks for providing the log!
-
reporter Jason, I was able to reproduce the issue. I'll create a build with the fix and post it here for you to verify. If things look good I'll issue a new official version the morning after the verification.
-
reporter - attached IlluminatedCloud-14.zip
Okay, I've attached a build with the prospective fix. Download the archive (don't extract it) and use Settings>Plugins>Install plugin from disk (under the gear drop-down) to install it.
If this does resolve the issue, just let me know; if it doesn't, please detail the exact steps that lead to failure so I can be sure to reproduce/fix it. Thanks!
-
Sounds great.
-
reporter Jason, did you ever verify the fix using the attached build? If not, do you mind doing so when you get a chance? Thanks!
-
reporter Fix for another instance of this delivered in 2.0.6.7. Waiting for feedback from Jason before updating IC1 with the same fix.
-
Sorry for the delay. Just installed update and appears to have resolved the error. Thanks for jumping on my issue so quickly.
-
reporter Thanks for verifying! I'll get a new build of IC1 out tomorrow with this and a few other small fixes. Just stay on that build until prompted to update, and the update will include the same fix. Thanks again!
-
reporter The new fix was delivered for IC1 via 1.8.5.2. Jason, feel free to take the latest official build as it includes this fix.
-
Wanted to give you heads up that I just received this error when syncing metadata. Looks related.
getInputStream() must not be called against a directory: file://path/to/DevelopPro/src/dashboards/CompanyDashboards
-
reporter Jason, can you share the portion from the bottom of your
.iml
file that looks like:<component name="NewModuleRootManager" inherit-compiler-output="true"> <exclude-output /> <content url="file://$MODULE_DIR$"> <sourceFolder url="file://$MODULE_DIR$/app/src" isTestSource="false" /> <sourceFolder url="file://$MODULE_DIR$/test/src" isTestSource="true" /> <sourceFolder url="file://$MODULE_DIR$/resource-bundles" isTestSource="false" /> </content> <orderEntry type="jdk" jdkName="IlluminatedCloud (df17/demo)" jdkType="IlluminatedCloud" /> <orderEntry type="sourceFolder" forTests="false" /> </component>
I helped another user with just such a problem the other day and it was due to a slightly misconfigured project. Let's see if you're experiencing the same.
-
reporter - changed component to Metadata Deployment/Retrieval/Removal
- Log in to comment
Issue
#1233was marked as a duplicate of this issue.