Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: invalid empty bundle types filtered from result #412

Merged
merged 6 commits into from
Aug 4, 2021

Conversation

WillieRuemmele
Copy link
Member

What does this PR do?

if a there was an empty top level directory for a bundle type, I'll use LWC as an example, it would cause deploy errors. I filter those out during the bundle adapter's populate method

so a force:source:deploy -m LightningComponentBundle
on a dir that looks like

   * ├── validLWC/
   * |   ├── myFoo.js
   * |   ├── myFooStyle.css
   * |   ├── myFoo.html
   * |   ├── myFoo.js-meta.xml
   * ├── invalidLWC/

will only result in validLWC being deployed, and no errors

What issues does this PR fix or reference?

#forcedotcom/cli#1099, @W-9692466@

Functionality Before

error on the server An object 'withoutContent' of type LightningComponentBundle was named in package.xml, but was not found in zipped directory
<insert gif and/or summary>

Functionality After

deploys correctly
<insert gif and/or summary>

Copy link
Member Author

@WillieRuemmele WillieRuemmele left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks @shetzel

Copy link
Contributor

@shetzel shetzel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verified unit test fails without the code fix and passes with it.
Verified the fix works using the ebikes_lwc project, with and without an empty LWC directory.
Code looks good with nice jsdoc comments branched from develop.

@shetzel shetzel merged commit cb9b67b into develop Aug 4, 2021
@shetzel shetzel deleted the wr/bundleSourceAdapter branch August 4, 2021 17:52
rcoringrato-sfdc pushed a commit that referenced this pull request Aug 5, 2021
* chore: invalid empty bundle types filtered from result

* chore: more comments

* chore: simplify logic

* chore: inverse logic to simplify

* fix: fixes the unit test

Co-authored-by: Steve Hetzel <[email protected]>
rcoringrato-sfdc pushed a commit that referenced this pull request Aug 5, 2021
* chore: invalid empty bundle types filtered from result

* chore: more comments

* chore: simplify logic

* chore: inverse logic to simplify

* fix: fixes the unit test

Co-authored-by: Steve Hetzel <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants