[Qgis-developer] Share some of my Processing Scripts

kimaidou kimaidou at gmail.com
Mon Jun 2 22:27:37 PDT 2014


Hi Victor,

I am amazed by your reactivity ! Thanks for improving Processing ! My
answers :


2014-06-02 23:00 GMT+02:00 Victor Olaya <volayaf at gmail.com>:

> I have just uploaded a first version of a tool to manage Processing
> resources (basically models and scripts)
>
> You will find tools named "Get scripts/models from on-line repository" in
> the scripts and models branches of the toolbox. They open a dialog where
> you can select the elements to install/uninstall, similar to the plugin
> manager
>


I will need to recompile QGIS to test this new feature. Hopefully I will
have time at the end of the week.


>
> Scripts and models are stored in a repo named QGIS-Processing under the
> QGIS organization. I recommend all people with scripts/models that they
> want to share, to make pull requests against that repo.
>


This sounds good to me.



>
> I have added the scripts by Michael and Vincent there, to add some
> intitial content (I haven't added any model yet). Please, let me know if
> you do not want them to be shared there.
>


I fully agree to have my scripts shared in this repository. You should
probably add a licence file (and a message in the readme) announcing all
the scripts in this repository are GPL V2. Thank you for having already
added them there.



>
> There is a list.txt with some info about the resources available. It's
> created automatically by running the create_lists.py script, and it acts
> like an easy to retrieve index, so there is no need to browse all the
> content and extract metadata from the help files.
>


OK.



>
> In the help files, there is now a ALG_VERSION element to indicate a
> version, which is 1.0 if it is not provided. That allows the interface to
> know if a script/model is up to date or not.
>


ok



>
> Notice that the format for help files is now json. That solves the issue
> that some people reported, cause by trying to unpickle the help
> description. I have converted the help files for the scripts that I added
> to the repo, using the help_converter.py script. Feel free to use it for
> your own scripts if needed (I might remove it from this repo, since i a not
> sure it belongs here...maybe better put it as a gist)
>


Thank you for converting the help files. I think you could keep the
converter here for a while, since it does not harm ;)   Or add a link to
the future gist in the README so that people can easily find it when using
QGIS-Processing repository.


>
> Things to discuss from now: How do we classify the algorithms? How do we
> allow people to add new scripts? The pull request mechanism might be too
> complex for some people, and the GitHub API allows to add a new file and a
> comit to a repo, so we can probably simplify it.
>


I think someone must review the scripts put in this new repository, since
it is the "official" QGIS sharing script repo. Pull requests are good for
this. This way some checking could be done by the reviewer :
* the category could be checked among a pre-defined required list (to be
defined)
* the script must have a complete help file to be accepted
* the script should not duplicate an existing script (if so better improve
the existing script which does the same)
etc.



>
> Ideas are welcome. This is just a first try done in a couple of nights so
> there is plenty of room for improvement.
>


Another idea then ;)
It could be handy to be able to add other repositories, as we can for
plugins. This way anyone can have its own script repository , and share
some of the script when wanted. The script writers and the end users will
have the choice to add some repositories.


>
> Thanks in advance!
>

Thank you for you amazing work around Processing !


>
>
> 2014-06-02 10:52 GMT+02:00 kimaidou <kimaidou at gmail.com>:
>
> Hi all
>>
>> Victor, thanks for your review, I will modify the scripts as soon as
>> possible.
>>
>> Sharing scripts raises some questions :
>>
>> * How can we categorize the scripts to help the users find one particular
>> among the many potential scripts that will be shared ? The "group" can
>> help, but any script writer can at present use the group he wants to. For
>> example, I used "3liz - Database" or "3liz - Vector", etc which makes sense
>> for me, but surely not for other users.
>>
>> * How do we assure that the user has got the last version of each script
>> ? As proposed before, I think some "git magic" could help.
>>
>> * Because it is more easy to create or modifiy, I usually create
>> "scripts". We could on the contrary "force" people who share scripts to use
>> the capability of Processing to integrate external algo via "provider".
>> This supposes to create a plugin for a set of scripts, which is more
>> complicated. But this would answer some of the questions above, for example
>> "how do we update the scripts", because QGIS plugin architecture would do
>> the job. I would also allow the user to temporarilly disable a set of
>> script (by disabling the corresponding plugin).
>>
>> IMHO we should not add more plugins for sharing scripts, but instead use
>> the same architecture : we could have a new Processing sub-menu
>> "Manage/Install external scripts and models" which would show a similar
>> interface as the plugin manager, and similar features : tagging, vote,
>> categories, descriptions, etc.
>>
>> I confess sharing my scripts had a double objective :
>> * share them :)
>> * begin a discussion about the future workflow to share scripts and
>> algorithms.
>>
>> Cheers
>> Michael
>>
>>
>>
>>
>> 2014-06-02 1:27 GMT+02:00 Giovanni Manghi <giovanni.manghi at faunalia.pt>:
>>
>> > - Contour : make contours around points at levels (based on the contour
>>> plugin)
>>> > - Buffer contour : make and merge circular buffer around points at
>>> levels
>>> > - Points at crossing / touching lines : make a point layer where lines
>>> cross or touch each other (2 scripts)
>>> > - Fill holes : remove holes in polygons under a certain area
>>> > - Remove parts : delete parts in multi polygons under a certain area
>>> > - cut by field : cut one polygon layer by another when 2 polygons
>>> share a field value
>>>
>>>
>>> very nice both sets of scripts! why not adding them into processing?
>>>
>>> cheers!
>>>
>>>
>>> -- G --
>>> _______________________________________________
>>> Qgis-developer mailing list
>>> Qgis-developer at lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/qgis-developer
>>>
>>
>>
>> _______________________________________________
>> Qgis-developer mailing list
>> Qgis-developer at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/qgis-developer
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20140603/753e1161/attachment.html>


More information about the Qgis-developer mailing list