-
Notifications
You must be signed in to change notification settings - Fork 7
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
Issue with importing uuid class? #22
Comments
Hello @psychohamster, |
…tatements would work correctly inside ~/.rbql_init_source.py
Glad I wasn't going crazy and missing something obvious! Thank you very much for tracking that down so fast. |
I've published a new version with import fix: 1.7.1. Please let me know if you find any other issues with the plugin! |
Hello,
I've had a monthly batch process that I've been using for about a year based on this sublime plugin which has been working great. It uses some UDFs defined in the .rbql_init_source.py file that require the uuid functions. So i've had 'import uuid' at the top of the init file working great for ages. A few weeks ago I started trying to run the process (skipped Feb this year, so I think my last successful run was with 1.5.0) and now it acts like the import uuid statement no longer works, as I get 'undefined global uuid' error when running my function within the query.
At first, I assumed it was something wonky with the sublime embedded python and started rolling back versions of ST3 to no avail. Even confirmed / recompiled the 3.3.6 pyo for the uuid class, etc.
After no luck there, I tried running the same process using VSCode and its corresponding rbql plugin, with the same result. So, I'm guessing some sort of weird conflict has come up with uuid, since I can import sys and use functions there with no problem.
I confirmed I can exec the functions from the python cli on the system level.
Steps for simple repro:
Install any recent version of ST3 and install Rainbow_CSV from package control
.rbql_init_source.py:
Open up a csv file in ST3 and run the following:
update set a1 = joe()
query execution, Error at line 1, details: global name 'uuid' is not defined
Now try this:
update set a1 = bob()
File executes and replaces with the expected embedded python version string
I'm going to downgrade to 1.5.0 and see if comes back, but figured I'd post here too in case anyone has run into this and has a quick solution I'm missing.
[updated] - downgraded the st3 package to 1.5.0 by replacing the folder under packages and now it works again.
Thanks!
The text was updated successfully, but these errors were encountered: