Re: [QGIS-Developer] Profiler times in Python

2023-05-05 Thread Michel Stuyts via QGIS-Developer
Until now I always used qgis.utils.plugin_times, but I noticed the different 
values between this variable and the “Debugging/Development Tools” Panel. 
That’s the reason I wanted the profiler values.  The qgis.utils.plugin_times 
variable has 0 loading time as value for some plugins, which is also very 
unlikely.

Does anyone know the difference these two sources of plugin loading times?


Michel

Van: Etienne Trimaille 
Verzonden: vrijdag 5 mei 2023 14:03
Aan: Michel Stuyts 
CC: qgis-developer 
Onderwerp: Re: [QGIS-Developer] Profiler times in Python

U ontvangt niet vaak e-mail van 
etienne.trimai...@gmail.com<mailto:etienne.trimai...@gmail.com>. Meer 
informatie over waarom dit belangrijk 
is<https://aka.ms/LearnAboutSenderIdentification>
One line I know, maybe this is enough :

>>> from qgis.utils import plugin_times
>>> plugin_times

It's not using the profiler. Values are different from the Profiler, after a 
quick look...

Le ven. 5 mai 2023 à 10:21, Michel Stuyts via QGIS-Developer 
mailto:qgis-developer@lists.osgeo.org>> a écrit 
:
I want to use the data on plugins from the Profiler.  In the 
“Debugging/Development Tools” Panel I can see both the total time for all 
plugins and the individual time per plugin.  With the following Python code, I 
want to get the same data in Python:

profiler = QgsApplication.profiler()
for child in profiler.childGroups():
childGroup = profiler.childGroups(child)
if child == 'Load plugins':
print(child, profiler.profileTime(child))
for subGroup in childGroup:
print(subGroup, profiler.profileTime(subGroup))

It shows the total time for all plugins just fine as “Load plugins” with the 
same number of seconds as in the Panel, but for the individual plugins I get 
0.0 as time for all plugins.  What do I do wrong or is it a bug?


Michel Stuyts
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org<mailto:QGIS-Developer@lists.osgeo.org>
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer


[QGIS-Developer] Profiler times in Python

2023-05-05 Thread Michel Stuyts via QGIS-Developer
I want to use the data on plugins from the Profiler.  In the 
"Debugging/Development Tools" Panel I can see both the total time for all 
plugins and the individual time per plugin.  With the following Python code, I 
want to get the same data in Python:

profiler = QgsApplication.profiler()
for child in profiler.childGroups():
childGroup = profiler.childGroups(child)
if child == 'Load plugins':
print(child, profiler.profileTime(child))
for subGroup in childGroup:
print(subGroup, profiler.profileTime(subGroup))

It shows the total time for all plugins just fine as "Load plugins" with the 
same number of seconds as in the Panel, but for the individual plugins I get 
0.0 as time for all plugins.  What do I do wrong or is it a bug?


Michel Stuyts
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer


[QGIS-Developer] qgis.utils.plugin_times vs. Debugging/Development Tools

2021-09-24 Thread Michel Stuyts
I am the creator of the "Plugin Load Times" plugin.  It's a simple plugin that 
shows the values of the QGIS Python variable qgis.utils.plugin_times in a gui 
window, to check which plugins take a long time to load at QGIS startup. I was 
comparing the values in the qgis.utils.plugin_times variable and the values in 
the "Debugging/Development Tools" panel - "Startup" - "Load plugins" and I 
noticed all values are different. So I was wondering why there is a difference? 
Is the qgis.utils.plugin_times variable still valid?  Is it possible to get the 
values from the "Debugging/Development Tools" panel in Python?

Michel Stuyts
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer


Re: [QGIS-Developer] Broken links to PDF manuals

2019-05-10 Thread Michel Stuyts
The link is http://docs.qgis.org/3.4/pdf/en/QGIS-3.4-UserGuide-en.pdf but that 
redirects to https://docs.qgis.org/3.4/en/en/QGIS-3.4-UserGuide-en.pdf

The same happens to different language versions: 
http://docs.qgis.org/3.4/pdf/nl/QGIS-3.4-UserGuide-nl.pdf redirects to 
https://docs.qgis.org/3.4/en/nl/QGIS-3.4-UserGuide-nl.pdf 


Michel


-Oorspronkelijk bericht-
Van: QGIS-Developer  Namens Nyall Dawson
Verzonden: vrijdag 10 mei 2019 8:30
Aan: qgis-developer 
Onderwerp: [QGIS-Developer] Broken links to PDF manuals

Hey list,

Can anyone confirm for me that the link to download PDF versions of the QGIS 
manual is currently broken? From https://www.qgis.org/en/docs/index.html the 
link leads to https://docs.qgis.org/3.4/en/en/QGIS-3.4-UserGuide-en.pdf, which 
returns a 404.

There's also links under https://docs.qgis.org/3.4/en/docs/ to the PDF, which 
point across to https://docs.qgis.org/testing/pdf/ -- but that link redirects 
back to https://docs.qgis.org/testing/en/docs/ and not the actual PDFs (it's 
also redirected from the 3.4 docs to the testing ones)

Nyall
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] Plugins website

2018-12-13 Thread Michel Stuyts
Yes, it works again.


Michel

-Oorspronkelijk bericht-
Van: QGIS-Developer [mailto:qgis-developer-boun...@lists.osgeo.org] Namens 
Richard Duivenvoorde
Verzonden: donderdag 13 december 2018 12:02
Aan: Alessandro Pasotti ; Richard Duivenvoorde 

CC: QGIS Developer Mailing List 
Onderwerp: Re: [QGIS-Developer] Plugins website

On 12/13/18 11:13 AM, Alessandro Pasotti wrote:
> On Thu, Dec 13, 2018 at 11:10 AM Richard Duivenvoorde 
> mailto:rdmaili...@duif.net>> wrote:
> 
> On 12/13/18 10:56 AM, Michel Stuyts wrote:
> > The plugins website https://plugins.qgis.org/ can’t find the Bootstrap
> > files (bootsrap.min.css, bootstrap-responsive.min.css,
> > bootstrap.min.js).  It makes some parts of the webpage show up on
> wrong
> > places. The same happens on all subpages.
> 
> Seems ok to me, as in I do not see missing resources in webdeveloper
> console?
> 
> It's not ok, this gives 404 for me too:
> https://plugins.qgis.org/static/bootstrap/js/bootstrap.min.js

Ok, should be fixed, please check.

Regards,

Richard
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

[QGIS-Developer] Plugins website

2018-12-13 Thread Michel Stuyts
The plugins website https://plugins.qgis.org/ can't find the Bootstrap files 
(bootsrap.min.css, bootstrap-responsive.min.css, bootstrap.min.js).  It makes 
some parts of the webpage show up on wrong places. The same happens on all 
subpages.


Michel


___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] Wrong line widths in legend when saving layout as pdf

2018-12-13 Thread Michel Stuyts
Maybe you changed the line weights option in AcroPlot Matrix. See 
https://www.cadzation.com/help/matrix_lineweightsnotshowing.htm


Michel

-Oorspronkelijk bericht-
Van: QGIS-Developer [mailto:qgis-developer-boun...@lists.osgeo.org] Namens 
magerlin
Verzonden: woensdag 12 december 2018 23:10
Aan: qgis-developer@lists.osgeo.org
Onderwerp: Re: [QGIS-Developer] Wrong line widths in legend when saving layout 
as pdf

I have realized it depends on what PDF-viewer I use for seeing the results.

In Adobe Reader the line widths are right, in Acroplot Matrix they are 
wrong.???

Have used Acroplt Matrix for a long time and never experienced this problem 
before.



-
Regards Morten

Currently using Qgis 2.18.23 (OSGeo4) and Qgis 3.4.2 in parallel Windows 7, 
64bit
--
Sent from: http://osgeo-org.1560.x6.nabble.com/QGIS-Developer-f4099106.html
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] QGIS 3.4 Plugin Python : error during import of PCRaster

2018-11-15 Thread Michel Stuyts
Have you tried installing it from the OSGeo shell instead of from the Windows 
default shell (cmd.exe)?


Michel



Van: QGIS-Developer [mailto:qgis-developer-boun...@lists.osgeo.org] Namens 
Christine
Verzonden: donderdag 15 november 2018 16:44
Aan: qgis-developer@lists.osgeo.org
Onderwerp: [QGIS-Developer] QGIS 3.4 Plugin Python : error during import of 
PCRaster


Hello all,


I am developping a plugin for QGIS 3.4. In my module irip_dockwidget.py when I 
try to import PCRaster 4.2. I get this error :

File 
"C:/Users/a/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\irip\irip_dockwidget.py",
 line 26, in import pcraster as pcr
File "C:/PROGRA~1/QGIS3~1.4/apps/qgis/./python\qgis\utils.py", line 672, in 
_import  mod = _builtin_import(name, globals, locals, fromlist, level)
File "C:\Program Files\pcraster-4.2.0\python\pcraster\__init__.py", line 62, in 
 raise ImportError(msg)
ImportError: The 'Microsoft Visual C++ 2015 Redistributable Update 3' is 
required to run PCRaster, available at:
 https://www.microsoft.com/en-us/download/details.aspx?id=53840
DLL load failed: Le module spécifié est introuvable.In case you cannot solve 
the issue please consult the PCRaster mailing list at: 
https://lists.geo.uu.nl/mailman/listinfo/pcraster-info

I’ve installed the MSCP as recommended in the message but the problem still 
remains. I’ve mailed to PCRaster team and wait for a reply but maybe have you  
already seen this problem and you have a solution.
Another point : I developed a command-line version of my application which 
works well.
My envir : Windows 8, QGIS 3.4 (QGIS-OSGeo4W-3.4.1-1-Setup-x86_64.exe), Python 
3.6, PCRaster 4.2
Thanks for your help,
Christine


___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] Unable to compile QGIS3 plugin

2018-03-23 Thread Michel Stuyts
Sophie,

This means  there is a probably something in your resources.py that causes the 
crash. Could you share that file and your resources.qrc that you used to 
generate resources.py?


Michel

Van: Sophie Crommelinck [mailto:sophie.crommeli...@gmail.com]
Verzonden: vrijdag 23 maart 2018 11:48
Aan: Michel Stuyts <michel.stu...@edegem.be>
CC: qgis-developer@lists.osgeo.org
Onderwerp: Re: [QGIS-Developer] Unable to compile QGIS3 plugin

@ Michel: Does my answer make sense to you?
Does anyone have an additional idea that I could try to compile the resource 
file successfully?
Best,
Sophie

2018-03-16 14:27 GMT+01:00 Sophie Crommelinck 
<sophie.crommeli...@gmail.com<mailto:sophie.crommeli...@gmail.com>>:
Hi,
then again a resources.py file is created that makes QGIS3 crash.
Best,
Sophie

2018-03-16 12:24 GMT+01:00 Michel Stuyts 
<michel.stu...@edegem.be<mailto:michel.stu...@edegem.be>>:
And if you first run:
call C:\OSGeo4W64\bin\py3_env.bat

and after that:
C:\OSGeo4W64\apps\Python36\Scripts\pyrcc5 –o resources.py resources.qrc


Michel




___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] Unable to compile QGIS3 plugin

2018-03-16 Thread Michel Stuyts
Sophie,

What happens if you add the full path before the pyrcc5 command when you’re in 
the plugin folder?

So  you go to the plugin folder and there you run:
C:\OSGeo4W64\apps\Python36\Scripts\pyrcc5 –o resources.py resources.qrc

Michel



Van: QGIS-Developer [mailto:qgis-developer-boun...@lists.osgeo.org] Namens 
Sophie Crommelinck
Verzonden: vrijdag 16 maart 2018 10:53
Aan: KOHLMANN Hannes ; j...@norbit.de
CC: qgis-developer@lists.osgeo.org
Onderwerp: Re: [QGIS-Developer] Unable to compile QGIS3 plugin

I think my images broke while sending,
here they are again:

Jürgen's suggestion:
[cid:image002.jpg@01D3BD17.8A7FB8C0]
Hannes' suggestion:
[cid:image004.jpg@01D3BD17.8A7FB8C0]
python-core.bat
[cid:image005.png@01D3BD17.8A7FB8C0]


2018-03-16 10:45 GMT+01:00 Sophie Crommelinck 
>:
Hello Jürgen and Hannes,
thanks for your support. I tried both suggestions, with little success.
Jürgen's suggestion:
[http://?ui=2=ad514a8e24=att=1622e15a2bbbae15=0.1=safe=ii_jetq74350_1622e15a2bbbae15]
This creates the resources.py file (attached). However, when I open QGIS3 it 
crashes every time I reload the plugin (crash report attached).
Hannes' suggestion:
[http://?ui=2=ad514a8e24=att=1622e24472fdda7d=0.2=safe=ii_jetqrnzt1_1622e24472fdda7d]
which results in the same as above. However, here I am not entirely sure if I 
followed the suggestion correctly as I go back to the plugin folder for 
compiling.
Also, I wonder, why the result of calling python-qgis-dev.bat lists win32, 
while I have a win64 machine.

I also tried changing the python path as suggested in the stack exchange 
question to Python36 in C:\OSGeo4W64\etc\ini\python-core without success
[http://?ui=2=ad514a8e24=att=1622e29d99d79ebd=0.0.3=safe=ii_jetqzhre4_1622e29d99d79ebd]
Best,
Sophie




2018-03-16 1:11 GMT+01:00 KOHLMANN Hannes 
>:
Hey Sophie!

There is one .bat file that does all the work of setting the Environment 
variables properly: /osgeo4w_root/bin/python-qgis-dev.bat
Call that file in the console and in the same console cd to the directory with 
the pyrcc.bat file (osgeo4w_root/apps/python36/scripts)

Here is the link to a gis.stackexchange question concerning that:
https://gis.stackexchange.com/questions/260743/how-to-compile-qtdesigner-user-interface-ui-and-resource-qrc-files-with-qg/264377#264377

Good luck and compiling ;)

Cheers,
Hannes
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer


___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] WMS GetFeatureInfo: Test Server with JSON support?

2017-12-08 Thread Michel Stuyts
This server supports JSON
https://ro.ruimtevlaanderen.be/drodsi-geoserver/wms


Michel

-Oorspronkelijk bericht-
Van: QGIS-Developer [mailto:qgis-developer-boun...@lists.osgeo.org] Namens 
Matthias Kuhn
Verzonden: donderdag 7 december 2017 9:30
Aan: qgis-developer@lists.osgeo.org
Onderwerp: [QGIS-Developer] WMS GetFeatureInfo: Test Server with JSON support?

Hi all,

QGIS suppors querying features from a WMS. Among the supported response formats 
is JSON.

The current code is based on QScript, which is deprecated.

I've written some code that removes this dependency, so we can stick to 
maintained Qt code and can remove a dependency from QGIS.

Now the state is as follows, the code is written, but I couldn't test it 
because I don't know a WMS server with this behavior.

If someone could point me towards a server that responds with JSON formatted 
feature information, I can make sure, the new code behaves the way it should.

If not, I'll just keep the old code around on any system that has QScript 
available (which should be almost any system out there) and only resort to the 
untested code when QScript is not available in the build environment.

Thanks a lot in advance

Matthias

___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] Convert from mapunits to pixels

2017-11-10 Thread Michel Stuyts
That's because it's a QGIS 3 plugin. It had a wrong qgisMinimumVersion in the 
metadata in the previous versions.


Michel

-Oorspronkelijk bericht-
Van: QGIS-Developer [mailto:qgis-developer-boun...@lists.osgeo.org] Namens Tom 
Chadwin
Verzonden: vrijdag 10 november 2017 12:23
Aan: qgis-developer@lists.osgeo.org
Onderwerp: Re: [QGIS-Developer] Convert from mapunits to pixels

By the way, I couldn't load go2mapillary in 2.18.14 via the plugin manager - I 
get "cannot import name QgsDataSourceUri".

Thanks

Tom



-
Buy Pie Spy: Adventures in British pastry 2010-11 on Amazon
--
Sent from: http://osgeo-org.1560.x6.nabble.com/QGIS-Developer-f4099106.html
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] New plugin version approval

2017-10-02 Thread Michel Stuyts
I wrote a local repo implementation in PHP a while ago, if you have a server 
with PHP you can use this simple script. You can find it on Github: 
https://github.com/mstuyts/phpQGISrepository

Michel


Van: QGIS-Developer [qgis-developer-boun...@lists.osgeo.org] namens Alex 
Zvoleff [azvol...@conservation.org]
Verzonden: maandag 2 oktober 2017 11:25
Aan: Tom Chadwin; qgis-developer@lists.osgeo.org
Onderwerp: Re: [QGIS-Developer] New plugin version approval

Thanks Tim, Tom and others. I hadn't considered the option of our own repo. I 
will keep this in mind. Thanks!

Best,
Alex

> -Original Message-
> From: QGIS-Developer [mailto:qgis-developer-boun...@lists.osgeo.org] On
> Behalf Of Tom Chadwin
> Sent: Sunday, October 01, 2017 9:56 PM
> To: qgis-developer@lists.osgeo.org
> Subject: Re: [QGIS-Developer] New plugin version approval
>
> Hi Alex
>
> Have you considered setting up your own plugin repo? I think you need some
> hosting and an XML file - hopefully fairly easy to set up.
>
> Tom
>
>
>
> -
> Buy Pie Spy: Adventures in British pastry 2010-11 on Amazon
> --
> Sent from: http://osgeo-org.1560.x6.nabble.com/QGIS-Developer-
> f4099106.html
> ___
> QGIS-Developer mailing list
> QGIS-Developer@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer