Error: Encountered Plasmic component "abc" in plasmic/.../PlasmicPage.tsx that are being used but have not been synced

I am trying to publish my project to Github, which had been working just fine a few days ago, and now I am getting this error: “The latest publish failed” when syncing the Plasmic project. I do not see any errors on the Github side. Please help.

Maybe it has something to do with this error in the API viewer? FWIIW other than not being able to commit code to Github (and thus Vercel) I am not noticing any other problems in the editor.

Hello Plasmic team. I am still unable to push my commits to Github. I am still in dev mode but will need to push to staging and production next week. Please help.

Hi @higinio_maycotte, can you share the logs of the “Syncing Plasmic project…” step? It should be in your GitHub repository.

These appear to be the lines in question, thank you:


Fixing import statements...
Error encountered while fixing imports for Homepage: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicHomepage.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Error encountered while fixing imports for OurFirmAbout: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicOurFirmAbout.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Error encountered while fixing imports for LandingBasic: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLandingBasic.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Error encountered while fixing imports for LegalTermsOfUse: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLegalTermsOfUse.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Error encountered while fixing imports for LegalPrivacyPolicy: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLegalPrivacyPolicy.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Error encountered while fixing imports for LegalCookieNotice: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLegalCookieNotice.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Error encountered while fixing imports for LegalSecurityFraud: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLegalSecurityFraud.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Plasmic error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLegalSecurityFraud.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLegalSecurityFraud.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
    at throwMissingReference (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:500992:9)
    at /home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:500820:9
    at Array.forEach (<anonymous>)
    at replaceImports (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:500801:21)
    at fixFileImportStatements (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:501148:22)
    at fixComponentImportStatements (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:501130:9)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async fixAllImportStatements (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:501069:11)
    at async doSync (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:504698:5)
    at async withBufferedFs (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:501565:5)
Error: Command failed: npx plasmic sync --projects '5QZxznJqfpxLyLiYK8mG4S:1k4WRKphXek0Z4zfkeodPLln50A5W7ApGC3uNPIiLaCFBd47lQboBzyudMVlMeGVlSIfC4HyLsKRxBrvzokeg' --yes
Error encountered while fixing imports for Homepage: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicHomepage.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Error encountered while fixing imports for OurFirmAbout: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicOurFirmAbout.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Error encountered while fixing imports for LandingBasic: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLandingBasic.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Error encountered while fixing imports for LegalTermsOfUse: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLegalTermsOfUse.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Error encountered while fixing imports for LegalPrivacyPolicy: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLegalPrivacyPolicy.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Error encountered while fixing imports for LegalCookieNotice: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLegalCookieNotice.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
Error encountered while fixing imports for LegalSecurityFraud: Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLegalSecurityFraud.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.

Plasmic error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLegalSecurityFraud.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.Error: Encountered Plasmic component "hRDVXHhzL2jJ" in plasmic/higherorder_capital/PlasmicLegalSecurityFraud.tsx that are being used but have not been synced. Please run "plasmic sync" with --force flag to force-sync the dependencies.
    at throwMissingReference (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:500992:9)
    at /home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:500820:9
    at Array.forEach (<anonymous>)
    at replaceImports (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:500801:21)
    at fixFileImportStatements (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:501148:22)
    at fixComponentImportStatements (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:501130:9)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async fixAllImportStatements (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:501069:11)
    at async doSync (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:504698:5)
    at async withBufferedFs (/home/runner/work/higherorder.capital/higherorder.capital/node_modules/@plasmicapp/cli/dist/index.js:501565:5)

Try checking out the repo and running npx plasmic sync --force! It seems like some dependent projects were not synced properly for some reason.

Hey @jason, I literally spent all day on this deployment issue today and did not resolve it. I could not force the sync to work from my local environment…I got the exact same errors plasmic was getting with --force!.

I even deleted the component whose id showed up on the logs but then it would just fail at the next component.

I went so far as to wipe my dev repo, didn’t work. I then let plasmic create a new repo, it did not work.

This is my project: Plasmic

Please help!! I have put about 2 weeks of effort into this, LOVE PLASMIC, but need to get this deployed.

Thanks!

I also just tried using Plasmic hosting as an alternative until we can get it to commit to Github again. …but the site seemingly successfully publishes to Plasmic hosting but the subdomain/link returns a 404.


Hi @higinio_maycotte, I was able to reproduce your issue on a fresh project. It looks like some of your components are named with a prefixed underscore _. This causes them not to be output, hence why the CLI errored saying a component is missing.

To resolve this issue immediately, remove the underscore from all components.

We’ll think about changing this behavior since it only makes sense for pages, not components.

1 Like

AAAAAmazing. that worked! TYSM, I :heart: Plasmic!