SFDX Module set to "All/Package" subscription fails to deploy new file in context mode
I deploy single files etc and in this project, it now doesn’t like deploying new files in context mode.
(not possible to tick the Apex class)
Changing to “Selected” does allow the deploy as it ticks the checkbox ion the deploy modal.
Additionally, I’ve noticed that deploying in Context mode doesn’t update the local-only status, needing to explicitly refresh the metadata.
Comments (9)
-
repo owner -
reporter I don’t recall specifically setting it to All, so I’ll remember to swap off that when I notice projects with it. thanks
-
reporter Oh, I see how it got that setting - it seems to be the default when creating a new sfdx project
-
repo owner Hmmmm....let me take a look. I may know what's going on. More to come shortly.
-
repo owner Hmmmm...can you explain the nature of this project a bit more. For an SFDX project I wouldn't ever expect the module config screen to look like that. Here's what it looks like (or at least should look like) for a scratch org module/project where it's assumed that the CLI will manage the "subscription" via source tracking:
and here's what it looks like (same qualifier applies) for a manifest-based source format module/project where
manifest/package.xml
is used to manage the subscription:It sounds like perhaps your project is in some other state and IC2 isn't quite setting things up properly? It'd be good to know that state. In particular I'd like to know the following:
- What kind of connection is being used here? Could I see the connection properties (with anything sensitive redacted, of course)?
- How was the project created and what is its overall structure?
- Does it have a
manifest/package.xml
file? f not, does it have apackage.xml
file somewhere else? - Where are the source roots and are they properly configured?
Let's start there. I suspect that this project is outside of IC2's expectations--which is not to say that they're incorrect, of course--and that's why you're seeing this kind of odd behavior.
-
reporter - OAuth to Sandbox (or Dev ed)
- File->New Project->SFDX->Select OAuth connection
- No & no
- Just the defaults
Screenshots from new project which lead to my last comment about defaults (since changed off All)
-
repo owner Fix committed for the next release.
-
repo owner - changed status to resolved
Delivered in 2.1.7.5.
-
repo owner - changed component to Metadata Deployment/Retrieval/Removal
- Log in to comment
I'll take a look at the issue deploying new files via context mode. That's certainly odd. For what it's worth, I discourage the use of All/Package for anything except for managed package development as there are numerous issues associated with it because it can pick up metadata that either doesn't retrieve properly or fails to even deploy back to the same org from which it was retrieved (both can result in GACKs). I've been strongly considering removing it as an option in an upcoming release.
As for not updating the local-only status, right now no deployments or retrievals do that. They should...but right now they don't.