viperet / vscode-magento-wizard

Helps develop Magento 2 extensions using VSCode
36 stars 16 forks source link

File not in the workspace (not saved yet?) #30

Open jcellon opened 2 years ago

jcellon commented 2 years ago

When I do F1 and try to inject dependency from the MagentoWizard nothing comes up. But looking into the Runtime Status I get: File not in the workspace (not saved yet?) And when looking into the output tab I get:

Found files registration files: FileSystemWatcher: Deleted ~\app\code\JCWizard\Boiler\etc\di.xml

Originally posted by @jcellon in https://github.com/viperet/vscode-magento-wizard/issues/29#issuecomment-924112301

viperet commented 2 years ago

@jcellon please post full log. Does it correctly detects Magento root location? Does it finds some modules/themes/blocks?

"File not in the workspace (not saved yet?)" means just what it says - you probable just created an empty file, right? To inject dependency it should be correctly formatted PHP file with class in it. Saved in one of the module folders, for example /app/code/foo/bar/Blocks/Example.php

jcellon commented 2 years ago

Here's the log:

PHP 7.3.21 (cli) (built: Aug 4 2020 11:21:19) ( ZTS MSVC15 (Visual C++ 2017) x64 ) Found Magento root at c:\wamp64\www\magento2