Frequently Asked Questions (FAQ)
đ Installation and Configuration
How do I install Odoo Shortcuts?
From Marketplace:
- Open VS Code
- Go to Extensions (
Ctrl+Shift+X)
- Search for âOdoo Shortcutsâ
- Click Install
From VSIX:
code --install-extension odoo-shortcuts-0.40.4.vsix
Configure Odoo Server paths for the LSP:
{
"odooShortcuts.odooServerPaths": [
"/home/user/odoo",
"/home/user/enterprise"
]
}
Why doesnât the Odoo Explorer appear?
- Verify you have a workspace open
- Check that there are addons with
__manifest__.py
- Update the view: click on đ
đď¸ Scaffold and Code Generation
How do I create a new addon?
Use the command: Odoo Shortcuts: New Addon
Or use the shortcut: Ctrl+K Ctrl+A
Can I customize the generated templates?
Yes, configure custom headers in settings:
{
"odooShortcuts.fileHeaders.enabled": true,
"odooShortcuts.fileHeaders.author": "Your Name",
"odooShortcuts.fileHeaders.company": "Your Company"
}
Why does it generate <tree> instead of <list>?
The system automatically detects Odoo version:
- Odoo < 18: generates
<tree>
- Odoo 18+: generates
<list>
Make sure to select the correct version when prompted.
How do I generate inherited views?
Use: Odoo Shortcuts: Create Inherit Views
Or use CodeLens on an existing model: [Create Inherit View]
đł Odoo Explorer
How do I add my addons to the explorer?
The explorer automatically detects addons in your workspace. Make sure:
- They have
__manifest__.py
- They are in the open workspace
Can I view Odoo Core addons?
Yes, configure:
{
"odooShortcuts.odooServerPaths": ["/path/to/odoo"],
"odooShortcuts.coreAddonPatterns": ["/odoo/addons/"]
}
Why do some addons appear in gray?
Read-only addons (Core/Enterprise) appear with different icons and donât allow editing.
đ§ LSP and Autocomplete
Why doesnât autocomplete work?
- Wait for initial indexing to finish (progress bar)
- Restart the LSP:
Odoo Shortcuts: Restart OWL/JS Language Server
- Verify files have
/** @odoo-module **/
How do I reindex JavaScript files?
Use: Odoo Shortcuts: Reindex JavaScript Files (LSP)
What if the LSP doesnât start?
- Check Developer Console (
Ctrl+Shift+I) for errors
- Restart VS Code
- Reinstall the extension if necessary
đť CodeLens
Why donât I see CodeLens links?
- Verify itâs enabled:
odooFile.codelens.enabled: true
- Wait a few seconds (loads asynchronously)
- File must be Python or JavaScript
How do I disable CodeLens?
{
"odooFile.codelens.enabled": false
}
đ Common Errors
âAddon not foundâ
Verify that:
- Directory has
__manifest__.py
- Youâre in the correct workspace
- Structure is valid for Odoo
âCould not generate fileâ
Possible causes:
- Write permissions in directory
- File already exists
- Invalid addon structure
âENOENTâ error
Directory or file doesnât exist. Verify path and create necessary folders.
If you work with many addons:
- Disable auto-refresh:
"odooShortcuts.autoRefresh": false
- Hide unused repositories
- Exclude large directories in settings
Why does the LSP use so much memory?
Initial indexing requires memory. You can:
- Reduce paths in
odooServerPaths
- Restart VS Code periodically
- Close unused files
đ Other Questions
Does it support Odoo 17/18/19?
Yes, the extension supports Odoo 14-19 and automatically adapts templates according to version.
Does it work with Odoo.sh?
Yes, the extension works with any Odoo addon structure, including Odoo.sh.
Can I use it with multiple workspaces?
Yes, the Odoo Explorer shows addons from all folders in the workspace.
How do I report bugs or request features?
Open an issue on GitHub: https://github.com/mjavint/odoo-shortcuts/issues
đĄ Tips
Productivity
- Use CodeLens to generate code quickly
- Learn keyboard shortcuts
- Configure automatic headers for your files
- Explore the context menu in Odoo Explorer
Debugging
- Check developer console for errors
- Restart LSP if there are autocomplete issues
- Verify paths are configured correctly
Donât see your question? Open an issue on GitHub or check the complete documentation.