Skip to content

Missing dependency? #142

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
pearofducks opened this issue May 12, 2018 · 5 comments
Closed

Missing dependency? #142

pearofducks opened this issue May 12, 2018 · 5 comments

Comments

@pearofducks
Copy link

pearofducks commented May 12, 2018

Looks like the newest changes are using the YAMLMacros package?

On MacOS 10.13.4 and Sublime 3175 (and 3.3.0 of this package).

When installing or restarting:

reloading plugin Vue Syntax Highlight.macros
Traceback (most recent call last):
  File "/Applications/Sublime Text.app/Contents/MacOS/sublime_plugin.py", line 116, in reload_plugin
    m = importlib.import_module(modulename)
  File "./python3.3/importlib/__init__.py", line 90, in import_module
  File "<frozen importlib._bootstrap>", line 1584, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1565, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1532, in _find_and_load_unlocked
  File "/Applications/Sublime Text.app/Contents/MacOS/sublime_plugin.py", line 1183, in load_module
    exec(compile(source, source_path, 'exec'), mod.__dict__)
  File "/Users/pear/Library/Application Support/Sublime Text 3/Installed Packages/Vue Syntax Highlight.sublime-package/macros.py", line 1, in <module>
ImportError: No module named 'YAMLMacros'
@skyronic
Copy link
Collaborator

Hey @pearofducks thanks for reporting. Does the extension still work ok though.

@Thom1729 what's the best way to fix this?

@pearofducks
Copy link
Author

@skyronic - nope, the extension fails to load! :)

@Thom1729
Copy link
Contributor

My bad! The new PR should fix this.

The problem was that the macros.py file was in the package root where Sublime would try to execute it. This is completely unnecessary, because the macros are only used when someone builds the syntax. I've moved the macros file into a subdirectory where Sublime won't look for it. This should completely resolve the problem.

@pearofducks
Copy link
Author

@Thom1729 @skyronic

Confirmed working now against #143

@skyronic
Copy link
Collaborator

I made a new release v3.3.1, will test once sublime package updates in a few minutes. Thanks for the quick response @Thom1729

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants