Written by

Question Daoyuan Sun · Feb 23, 2021

Can't compile in VSCode

When I use vscode, Some classes cannot be compiled, while others can .it will report the following error:

What should I do?

Product version: Ensemble 2018.1
$ZV: 2018.1.0HS.1010.0

Comments

Jeff Liu · Feb 23, 2021

Hi Daoyuan,

Can this class be compiled in Studio? 

Best regards,

Jeff

0
Daoyuan Sun  Feb 23, 2021 to Jeff Liu

Hi Jeff,

thank you for your reply,

the class can be compiled normally in Studio.

0
Jeff Liu  Feb 24, 2021 to Daoyuan Sun

It is weird to have permission issue if you use same user in VSCode as you do in Studio. It would be more convenient if we can have check your actual environment. You may contact me @jeff.liu@intersystems.com if you want me to have a look.

0
Daoyuan Sun  Feb 25, 2021 to Jeff Liu

finally I solved the problem  by setting resource %DB_%DEFAULT RW permissions.

0
Jeff Liu  Feb 26, 2021 to Daoyuan Sun

Hi Daoyuan,

Good to see that you solved it. Do you still need me to investigate any other issue? 

I replied your email, but havn't heard back yet.

Best regards,

Jeff

0
Daoyuan Sun  Feb 26, 2021 to Jeff Liu

Sorry Jeff, I thought I had sent the email, but I just realized that I pressed the wrong button.

Thank you for offering in my two posts,I think I can do the rest by myself.

Best wishs,

Daoyuan

0
Daoyuan Sun  Feb 26, 2021 to John Murray

It's very valuable,I'll read intensively

0
Dmitry Maslennikov · Feb 24, 2021

Should not be any problem if you use the same user both in Studio and VSCode. PROTECT error means you have security issue and your user not granted for write permission, or that database is just in read only mode

0
Daoyuan Sun  Feb 26, 2021 to Dmitry Maslennikov

Yeah! I was inspired by your comments,finally I gave the %DB_%DEFAULT RW permissions.

0
John Murray · Feb 24, 2021

Are some classes in a package that is mapped to a different database that you don't have WRITE permission on?

0
Daoyuan Sun  Feb 25, 2021 to John Murray

I can't even compile a class that doesn't extends any classes but only writes HelloWorld

0