[Qgis-user] Running QGis on a machine with Python 3.11 and PyCharm ?

Zoltan Szecsei zoltans at geograph.co.za
Mon Jun 12 00:22:44 PDT 2023


Hi Toussaint,
I am not a hard-core developer, but I script/code whenever I can 
automate a procedure, so:

  * It is my understanding that QGIS is developed/maintained in the QT
    environment - so go that way rather than PyCharm if you plan to
    dabble in QGIS development.
    Perhaps one of the devs that lurk on this user list will add to this
    comment of mine.
  * Get on to QGIS-dev as well - you might find some better guidance
    there, for PyCharm and other python scripting issues.

I will try to find time to set up QGIS and PyCharm on my laptop in the 
next day or so - *_but in the meantime, google_* "pycharm with qgis" - 
there are about a billion articles and videos that come up.

Oh!, Yes!, I am exaggerating..... :-)

Regards,
Zoltan

On 2023/06/12 10:06, Toussaint OTTAVI via QGIS-User wrote:
> Hi Zoltan,
>
> Thank you in advance for your help.
>
> For now, I didn't manage to find a suitable configuration by setting 
> paths and environment variables in a startup ".bat" file. QGis still 
> tries to load things from my system-wide Python folder (c:\python), 
> even if no path or env variable points to it. Then, it fails.
>
> The only workaround I found is a bit rough : rename my c:\python 
> folder to c:\python.bak, run QGis, then rename back to the original 
> name ! Of course, this prevents from using QGis at the same time with 
> PyCharm or other Python stuff, and is not an acceptable solution on 
> the long term.
>
> Even if I don't have the skills to dive into QGis source code for now, 
> I may try to play around with some simple plugins. Then, wouldn't it 
> be a better idea to install QGis in "developer" mode, by cloning / 
> forking the GitHub repo ?
>
> Any suggestions are welcome.
>
> Kind regards.
>
>
>
> Le 09/06/2023 à 22:25, Zoltan a écrit :
>> Hi,
>> I seem to remember that pycharm website provides help on using 
>> pycharm with qgis, so don't mess with your existing installations of 
>> python.
>> The gist of it is that you add the pycharm startup to the end of the 
>> bat file that qgis provides for setting up all the env variables.
>> Starting pycharm from the Taskbar will not set these environment for 
>> you so use the edited bat file I describe above.
>> There might also be a way in your pycharm venv to pre set these env vars.
>> I have a new laptop which I have not yet set up for this but if you 
>> are still stuck tomorrow,  I'll set mine up and let you know what works.
>> Regards
>> Zoltan
>>
>
>
> _______________________________________________
> QGIS-User mailing list
> QGIS-User at lists.osgeo.org
> List info:https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe:https://lists.osgeo.org/mailman/listinfo/qgis-user

-- 

=============================================
Zoltan Szecsei GPrGISc 0031
Director, Geograph (Pty) Ltd.
GIS and Photogrammetric Services

Cape Town, South Africa.

Mobile: +974-5058-8729 (Signal, not WhatsApp)
         +27-83-6004028 (Signal, not WhatsApp)

www.geograph.co.za
=============================================
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20230612/fa208a00/attachment.htm>


More information about the QGIS-User mailing list