Closed ayiyann closed 3 years ago
Hi @ayiyann - We need more information to attempt to troubleshoot this:
hi How can i find log file of Vscode and send them to you ?
here i smy config:
OS: windows 10
sfdx --version :sfdx-cli/7.89.2-d1d2614d02 win32-x64 node-v14.15.4
sfdx plugins --core @oclif/plugin-autocomplete 0.3.0 (core) @oclif/plugin-commands 1.3.0 (core) @oclif/plugin-not-found 1.2.4 (core) @oclif/plugin-plugins 1.9.5 (core) @oclif/plugin-warn-if-update-available 1.7.0 (core) @oclif/plugin-which 1.0.3 (core) @salesforce/lwc-dev-server 2.10.0 ├─ @oclif/plugin-help 2.2.3 └─ @oclif/plugin-update 1.3.10 @salesforce/sfdx-diff 0.0.6 @salesforce/sfdx-trust 3.6.0 (core) alias 1.1.5 (core) auth 1.4.8 (core) config 1.2.4 (core) generator 1.1.5 (core) salesforcedx 51.1.1 (core) ├─ schema 1.0.4 (core) ├─ user 1.1.2 (core) ├─ limits 1.0.4 (core) ├─ custom-metadata 1.0.11 (core) ├─ apex 0.1.4 (core) ├─ @salesforce/sfdx-plugin-lwc-test 0.1.7 (core) ├─ templates 51.3.0 (core) └─ salesforce-alm 51.1.1 (core) sfdx-cli 7.89.2 (core)
i also use local development server in order to preview LWC locally
when i deploy to my salesforce org nothing happens even if the command ended with 0 ( i need to restard my computer in order to make everything works fine until it happens again => very boring ).
in Help > Toggle Developer Tools > console i don't see anything
i can share my screen and show you the issue if it is possible for you
Hi @ayiyann , let's take a step back. Can you explain what you mean by "doesn't do nothing" ? Is it that your changes do not get deployed to the org ? What changes happen to your experience with the command that is solved by restarting your machine ?
Hi, yes that mean my changes are not deployed. i am currently facing the same issue again. i don't know why it is random. I just right click on my component and deploy to my sandbox and i get this ( but nothing what been deployed to my sandbox): Notice that the command doesn't show at the end of the log the deployed components ( maybe i can try to send you a video or screenshots )
Starting SFDX: Deploy Source to Org 18:26:06.573 sfdx force:source:deploy --sourcepath c:\Users\yann\Desktop\YANN\AUTRES\OUTILS\VSCode_Salesforce\Salesforce_ORG\AGEFOS\AGEFOS_develop\AGEFOS_develop\force-app\main\default\lwc\lwc018_demandeDeRappelV2\lwc018_demandeDeRappelV2.html --json --loglevel fatal 18:26:12.396 sfdx force:source:deploy --sourcepath c:\Users\yann\Desktop\YANN\AUTRES\OUTILS\VSCode_Salesforce\Salesforce_ORG\AGEFOS\AGEFOS_develop\AGEFOS_develop\force-app\main\default\lwc\lwc018_demandeDeRappelV2\lwc018_demandeDeRappelV2.html --json --loglevel fatal ended with exit code 0
In order to make it run the solution i currently use is to restart my computer. yesterday i stop local developpement server + restart vscode and the deployment works fine. Today i am facing the same issue ( local development server is not running) . i don't know where is the issue. I will restart again vscode and if it is not working i will restart my computer .
hi je restart Vscode and the "SFDX: Deploy Source" command works fine . Here is the logs when it runs fine. You can see that at the end of the log the deployed component are listed. When i face the issue the logs doesn't show the deployed components. (cf the logs of my previous post)
Starting SFDX: Deploy Source to Org
18:38:05.147 sfdx force:source:deploy --sourcepath c:\Users\yann\Desktop\YANN\AUTRES\OUTILS\VSCode_Salesforce\Salesforce_ORG\AGEFOS\AGEFOS_develop\AGEFOS_develop\force-app\main\default\lwc\lwc018_demandeDeRappelV2\lwc018_demandeDeRappelV2.html --json --loglevel fatal 18:38:13.457 sfdx force:source:deploy --sourcepath c:\Users\yann\Desktop\YANN\AUTRES\OUTILS\VSCode_Salesforce\Salesforce_ORG\AGEFOS\AGEFOS_develop\AGEFOS_develop\force-app\main\default\lwc\lwc018_demandeDeRappelV2\lwc018_demandeDeRappelV2.html --json --loglevel fatal ended with exit code 0
=== Deployed Source
STATE FULL NAME TYPE PROJECT PATH
───── ────────────────────────────────────────────────────── ──────────────────────── ────────────────────────────────────────────────────────────────────────────────────────
Add lwc018_demandeDeRappelV2\lwc018_demandeDeRappelV2.html LightningComponentBundle force-app\main\default\lwc\lwc018_demandeDeRappelV2\lwc018_demandeDeRappelV2.html
Add lwc018_demandeDeRappelV2\lwc018_demandeDeRappelV2.js LightningComponentBundle force-app\main\default\lwc\lwc018_demandeDeRappelV2\lwc018_demandeDeRappelV2.js
Add lwc018_demandeDeRappelV2\lwc018_demandeDeRappelV2.js LightningComponentBundle force-app\main\default\lwc\lwc018_demandeDeRappelV2\lwc018_demandeDeRappelV2.js-meta.xml
I do have the same issue on running the same command. I am on latest version of SFDX. Here is what happens
It just finishes, no error, no warning, no success. A week back, it used to work i.e. show number of components, deploy status etc. Same thing happens if I run it from a terminal, adding --verbose flag does not provide any useful info. I will be happy to provide more information.
OS: Windows 10 I am using default config of SFDX, no experimental flags. It started happening after I updated SFDX a week back
Version:
I too am having this issue. When I make a change to my Apex class and I save the change, the deploy to salesforce executes but does not actually deploy the changes. I get message stating it ended with an exit code of 0 but it did not actually deploy the code. I then have to make another change to the file, and save it. It then deploys to Salesforce, sometimes this works, sometimes it does not. I have to continue to make changes until the file is actually sent to Salesforce. Here are the logs from doing this today.
Starting SFDX: Deploy Source to Org
07:52:52.352 sfdx force:source:deploy --sourcepath c:\Salesforce\VSCode\McConxJB\force-app\main\default\classes\MSLUpdateEventServiceTest.cls --json --loglevel fatal 07:53:04.993 sfdx force:source:deploy --sourcepath c:\Salesforce\VSCode\McConxJB\force-app\main\default\classes\MSLUpdateEventServiceTest.cls --json --loglevel fatal ended with exit code 0
It says the deploy of the source code worked but my changes are not on the org.
Starting SFDX: Deploy Source to Org
07:53:22.536 sfdx force:source:deploy --sourcepath c:\Salesforce\VSCode\McConxJB\force-app\main\default\classes\MSLUpdateEventServiceTest.cls --json --loglevel fatal 07:53:39.654 sfdx force:source:deploy --sourcepath c:\Salesforce\VSCode\McConxJB\force-app\main\default\classes\MSLUpdateEventServiceTest.cls --json --loglevel fatal ended with exit code 0
=== Deployed Source
STATE FULL NAME TYPE PROJECT PATH
───── ───────────────────────── ───────── ─────────────────────────────────────────────────────────────────────
Add MSLUpdateEventServiceTest ApexClass force-app\main\default\classes\MSLUpdateEventServiceTest.cls
Add MSLUpdateEventServiceTest ApexClass force-app\main\default\classes\MSLUpdateEventServiceTest.cls-meta.xml
Now the changes are actually on the org.
Hi a fix will be available soon ? It is very difficult to work like this. I confirm it is the same issue in https://github.com/forcedotcom/salesforcedx-vscode/issues/3042 Best Regards
@smaddox-sf : Stephanie, there is something that I failed to mention in https://github.com/forcedotcom/salesforcedx-vscode/issues/3042 that I will add here. It may or may not help, but when dealing with issues I feel that too much information is better than not enough:
When running the deploy command by typing it into the terminal, every time that it has indicated success, the file has actually been deployed into the org.
I am too facing this issue since updating to 7.89 versions of the cli. In the meantime this issues is fixed has anyone found a workaround or a way to roll back cli to stable versions?
I believe you are running into a slightly different version of the expired session problem as in #899
If you switch to use SOAP (sfdx config:set restDeploy=false
) or ensure your auth tokens are valid (you can run sfdx force:org:display
and it should refresh it for you) I think you will no longer see this problem. Can you please confirm and if that is the case, close this issue?
I believe you are running into a slightly different version of the expired session problem as in #899 If you switch to use SOAP (
sfdx config:set restDeploy=false
) or ensure your auth tokens are valid (you can runsfdx force:org:display
and it should refresh it for you) I think you will no longer see this problem. Can you please confirm and if that is the case, close this issue?
Thank you for providing assistance.
I did that, here is the command log. I still see the same issue. The retrieve also gives an error. The class I am trying to retrieve is present since 2 years and is present in same org as seen in screenshot.
I will reinstall the CLI entirely.
I finally fixed by
npm remove sfdx-cli -g
C:\\users\yourname
. npm install sfdx-cli -g
As mentioned by @manjitsingh8, the issue doesn't seem to be with the token as all my orgs when I ran the command sfdx force:org:display
it did show as connected and I'm also able to retrieve the components from the org. But with the deploy command, the components don't get deployed to the org. I'm still facing this issue in the 7.91 version of the cli.
I also don't have the flexibility to uninstall and install applications in a corporate environment. So I'm waiting for the fix in an upcoming update.
@vikyaiyer I don't think you have to wait for a fix to the REST deploy path. If you're on v7.91 of the CLI and the core version of salesforcedx plugin bundled with that CLI then you should be able to switch to SOAP for the deploy and it should work. Appending --dev-debug
generally gives additional helpful output as well.
@shetzel thanks for the update, switching to SOAP for deploy worked.
I'm closing this--it's all related to the soap/rest switch.
hi however it is related to soap/rest switch i hope the rest behaviour will be fixed
@mshanemc What "soap/rest switch"? (EDIT: As in, I understand the discussion of the workaround of switching from using REST to using SOAP. What I don't understand is your reference to "the soap/rest switch" [emphasis added by me].)
This was closed without resolution but with no reference/link to any other issue.
hi @RCMoonpie the workaround is to switch to soap deployment by using the command: sfdx config:set restDeploy=false in the terminal
Thank you for the replay @ayiyann . But you said it yourself - that is a "workaround". Which means the underlying issue still exists.
Which is why I do not understand the closing of this issue without directly linking it to another issue that is still being worked.
I was updating a managed package very late last month & saw the toast say success during my right-click in a file > deploy action...yet the org didnt get the update. I think its happened as few as ~ 3 times for me, (that i noticed and out of tens of thousands of uses).
to anyone troubleshooting: I have not intentionally made any edits to the "soap/rest switch".
I think reopening vscode helped me around it, but im really not sure what causes or what fixes it.
Im on sfdx-cli/7.91.0-6a6ed69ebe win32-x64 node-v14.15.4.
Thank you for the replay @ayiyann . But you said it yourself - that is a "workaround". Which means the underlying issue still exists.
Which is why I do not understand the closing of this issue without directly linking it to another issue that is still being worked.
hi @RCMoonpie I agree with you . I don't understand why they have closed this case because switching to soap is just a workaround.
Has anyone got solution (no workaround please)
@NarangAshish
The issue would be resolved once you update the cli and switch to SOAP deploy
sfdx update
sfdxconfig:set restDeploy=false
Should this issue should not be closed if it is a bug (REST is default) and there is no error given. The config:set restDeploy=false workaround is not working and spent a while just to get here :) Goal is simply to use org browser, edit a file on sandbox, deploy to org.
Whoever is reading this - note that all these user issues are happening on Windows - Can we confirm that this is not related to parsing of windows path names?
@shawnholt - REST is no longer the default. It was switched back to SOAP months ago. In order to reopen this issue there would need to be more information in how to reproduce it, or open a new issue with the details from the template filled out such as CLI and plugin versions, the exact command and parameters used, and any debug output that may help track down the problem (append --dev-debug to the command for that
.
You can also try installing/using the source plugin beta which is what we're moving towards in the very near future to see if that fixes the problem. Details for that are in the announcement at the top of the issues page.
Another thing you can check is that you no longer have the salesforcedx
plugin installed if you're on the latest CLI version (7.108.0). If you do you should uninstall it.
I've been having this bug too, inconsistently. I will deploy source to org and SFDX will tell me 'Deploy source to org ran successfully,' but the remote code won't change. I am using the SOAP not the REST.
It's obvious that the developers just aren't going to reopen this problem and figure out what is actually going on here, so I will tell you the workaround that worked for me:
Edit the code remotely using the web interface, and make some trivial change like adding a comment. Then when you deploy it will work.
It is really annoying I have to do this because I have to waste time every time I deploy to make sure the deployment actually worked. It would be really nice if this problem was actually fixed instead of being swept under the rug.
I deploy to my salesforce org by selecting my LWC and click SFDX: deploy source to org" . The command ended with code 0 but oesn't do nothing .
Sometime i need to restart my computer in order to make the command ok.
16:32:16.931 sfdx force:source:deploy --sourcepath c:\Users\yann\Desktop\YANN\AUTRES\OUTILS\VSCode_Salesforce\Salesforce_ORG\PERSO\LWC_Playground\LWC\force-app\main\default\lwc\boatSearchForm\boatSearchForm.js --json --loglevel fatal ended with exit code 0