Mailing List Archive

Cannot find SmpPermissionPolicy
Hi,

I need some help!

The SimpleMultiProjectPlugin
<https://trac-hacks.org/wiki/SimpleMultiProjectPlugin> doesn't work in my
new trac installation:

1. Installation:
pip2 install TracSimpleMultiProject

2. Change the trac.ini:
add:

[components]
simplemultiproject.* = enabled

[ticket-custom]
project = select
project.label = Project
project.value =


3. upgrade environment:
trac-admin /instance_trac/ upgrade
(smp_project, smp_milestone_project, smp_version_project,
smp_component_project tables are created)

4. restart webserver:
systemctl restart httpd

5. log in as admin

6. I can:
* see the plugin:
* TracSimpleMultiProject 0.7.1 and all component are enabled:
* simplemultiproject.admin.* -> SmpAdminPanel
* simplemultiproject.admin_command.* -> SmpAdminCommands
* simplemultiproject.environmentSetup.* ->
smpEnvironmentSetupParticipant
* simplemultiproject.model.* -> SmpModel
* simplemultiproject.permission.* -> SmpPermission
* create project:
* ADMIN => Projects - admin/projects/simplemultiproject
* one record created in the smp_project table
* modify project:
* click on the project name, change the description on the new form and
click on Modify button.
* the description field had modified in the smp_project table

7. I cannot:
* add project on:
* "Admin" -> "Ticket System" -> "Milestones" / "Versions"
* "Admin" -> "Ticket System" -> "Components"
* "New Ticket"
* see the projects chosen in the filter box on:
* "Timeline"
* "Roadmap"
* "View Tickets"

8. Change the trac.ini:
[trac]
deleted: permission_policies =
DefaultWikiPolicy,DefaultTicketPolicy,DefaultPermissionPolicy,LegacyAttachmentPolicy
added: permission_policies =
SmpPermissionPolicy,DefaultWikiPolicy,DefaultTicketPolicy,DefaultPermissionPolicy,LegacyAttachmentPolicy

9. restart webserver:
systemctl restart httpd

10. The trac application not available anymore! The error message:

Configuration Error

Cannot find implementation(s) of the IPermissionPolicy interface named
SmpPermissionPolicy. Please check that the Component is enabled or update
the option [trac] permission_policies in trac.ini.


System Information

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:85.0) Gecko/20100101
Firefox/85.0
Package Version
Trac 1.4.2
Genshi (not installed, some old plugins may not work as expected)
Jinja2 2.11.3
mod_wsg 4.7.1 (WSGIProcessGroup WSGIApplicationGroup %{GLOBAL})
MySQL server: "5.5.5-10.5.8-MariaDB", client: "0.8.0", thread-safe: True
pymysql 0.8.0
Python 2.7.17 (default, Aug 31 2020, 21:02:14) [GCC 8.3.1 20191121
(Red Hat 8.3.1-5)]
setuptools 39.0.1
jQuery 1.12.4
jQuery UI 1.12.1
jQuery Timepicker 1.6.3

Installed Plugins
Name Version Location
TracSimpleMultiProject 0.7.1 /usr/lib/python2.7/site-packages

Not installed the TracFineGrainedPermissions plugin.

What should I change in the configuration?

Thanks!
SzL

--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/trac-users/fb1cc4e8-1e6d-49f7-ab73-71013e3843c7n%40googlegroups.com.
Re: Cannot find SmpPermissionPolicy [ In reply to ]
On Tuesday, February 9, 2021 at 9:26:43 AM UTC-8 László Szécsi wrote:

>
> Hi,
>
> I need some help!
>
> The SimpleMultiProjectPlugin
> <https://trac-hacks.org/wiki/SimpleMultiProjectPlugin> doesn't work in my
> new trac installation:
>
> 1. Installation:
> pip2 install TracSimpleMultiProject
>
> 2. Change the trac.ini:
> add:
>
> [components]
> simplemultiproject.* = enabled
>
> [ticket-custom]
> project = select
> project.label = Project
> project.value =
>
>
> 3. upgrade environment:
> trac-admin /instance_trac/ upgrade
> (smp_project, smp_milestone_project, smp_version_project,
> smp_component_project tables are created)
>
> 4. restart webserver:
> systemctl restart httpd
>
> 5. log in as admin
>
> 6. I can:
> * see the plugin:
> * TracSimpleMultiProject 0.7.1 and all component are enabled:
> * simplemultiproject.admin.* -> SmpAdminPanel
> * simplemultiproject.admin_command.* -> SmpAdminCommands
> * simplemultiproject.environmentSetup.* ->
> smpEnvironmentSetupParticipant
> * simplemultiproject.model.* -> SmpModel
> * simplemultiproject.permission.* -> SmpPermission
> * create project:
> * ADMIN => Projects - admin/projects/simplemultiproject
> * one record created in the smp_project table
> * modify project:
> * click on the project name, change the description on the new form and
> click on Modify button.
> * the description field had modified in the smp_project table
>


Does that mean you see "simplemultiproject.permission" displayed on the
Admin page?

[image: Screen Shot 2021-02-09 at 10.10.17.jpg]

--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/trac-users/fdd12ddb-b3dc-43e5-8bc5-400fcf18e031n%40googlegroups.com.
Re: Cannot find SmpPermissionPolicy [ In reply to ]
I see the name of the "Implements the permission system for
SimpleMultipleProject" is SmpPermission instead of SmpPermissionPolicy.

I have replaced it in the trac.ini file:
permission_policies =
SmpPermission,DefaultWikiPolicy,DefaultTicketPolicy,DefaultPermissionPolicy,LegacyAttachmentPolicy

After the httpd restarted, the Trac application keep working, but the
project fields not showing yet in the appropriate screens.
[image: TracSimpleMultiProject 0.7.1_admin_Screenshot.png]
RjOllos a következ?t írta (2021. február 10., szerda, 18:51:00 UTC+1):

> On Tuesday, February 9, 2021 at 9:26:43 AM UTC-8 László Szécsi wrote:
>
>>
>> Hi,
>>
>> I need some help!
>>
>> The SimpleMultiProjectPlugin
>> <https://trac-hacks.org/wiki/SimpleMultiProjectPlugin> doesn't work in
>> my new trac installation:
>>
>> 1. Installation:
>> pip2 install TracSimpleMultiProject
>>
>> 2. Change the trac.ini:
>> add:
>>
>> [components]
>> simplemultiproject.* = enabled
>>
>> [ticket-custom]
>> project = select
>> project.label = Project
>> project.value =
>>
>>
>> 3. upgrade environment:
>> trac-admin /instance_trac/ upgrade
>> (smp_project, smp_milestone_project, smp_version_project,
>> smp_component_project tables are created)
>>
>> 4. restart webserver:
>> systemctl restart httpd
>>
>> 5. log in as admin
>>
>> 6. I can:
>> * see the plugin:
>> * TracSimpleMultiProject 0.7.1 and all component are enabled:
>> * simplemultiproject.admin.* -> SmpAdminPanel
>> * simplemultiproject.admin_command.* -> SmpAdminCommands
>> * simplemultiproject.environmentSetup.* ->
>> smpEnvironmentSetupParticipant
>> * simplemultiproject.model.* -> SmpModel
>> * simplemultiproject.permission.* -> SmpPermission
>> * create project:
>> * ADMIN => Projects - admin/projects/simplemultiproject
>> * one record created in the smp_project table
>> * modify project:
>> * click on the project name, change the description on the new form
>> and click on Modify button.
>> * the description field had modified in the smp_project table
>>
>
>
> Does that mean you see "simplemultiproject.permission" displayed on the
> Admin page?
>
> [image: Screen Shot 2021-02-09 at 10.10.17.jpg]
>

--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/trac-users/8214f58c-bfc7-4c6b-be31-9e67ac6645f8n%40googlegroups.com.
Re: Cannot find SmpPermissionPolicy [ In reply to ]
On Thursday, February 11, 2021 at 11:06:06 AM UTC-8 László Szécsi wrote:

> I see the name of the "Implements the permission system for
> SimpleMultipleProject" is SmpPermission instead of SmpPermissionPolicy.
>

The component was renamed SmpPermission -> SmpPermissionPolicy in r17810:
https://trac-hacks.org/changeset/17810

The recent changes haven't been published to PyPI.
https://trac-hacks.org/log/simplemultiprojectplugin?action=stop_on_copy&mode=stop_on_copy&rev=17988&stop_rev=17810&limit=100&sfp_email=&sfph_mail=

We need to release a 0.7.2. I will do that later today.

Ryan

--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/trac-users/8d63aca2-4946-4c9d-becc-9fb35d740468n%40googlegroups.com.
Re: Cannot find SmpPermissionPolicy [ In reply to ]
On Thursday, February 11, 2021 at 12:40:50 PM UTC-8 RjOllos wrote:

> On Thursday, February 11, 2021 at 11:06:06 AM UTC-8 László Szécsi wrote:
>
>> I see the name of the "Implements the permission system for
>> SimpleMultipleProject" is SmpPermission instead of SmpPermissionPolicy.
>>
>
> The component was renamed SmpPermission -> SmpPermissionPolicy in r17810:
> https://trac-hacks.org/changeset/17810
>
> The recent changes haven't been published to PyPI.
>
> https://trac-hacks.org/log/simplemultiprojectplugin?action=stop_on_copy&mode=stop_on_copy&rev=17988&stop_rev=17810&limit=100&sfp_email=&sfph_mail=
>
> We need to release a 0.7.2. I will do that later today.
>
> Ryan
>

Done, please try: https://pypi.org/project/TracSimpleMultiProject/0.7.2/

--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/trac-users/4714dca3-9ba6-47fe-acd5-e29fe728c3dfn%40googlegroups.com.
Re: Cannot find SmpPermissionPolicy [ In reply to ]
I have done these steps:

1. pip2 list --outdated --format=freeze | grep -v '^\-e' | cut -d = -f 1
| xargs -n1 pip2 install -U
2. permission_policies =
SmpPermissionPolicy,DefaultWikiPolicy,DefaultTicketPolicy,DefaultPermissionPolicy,LegacyAttachmentPolicy
3. systemctl restart httpd
4. trac-admin /instance_trac/ upgrade
5. trac-admin /instance_trac/ wiki upgrade
6. systemctl restart httpd

And now the project field appears everywhere I expected it.
Thanks for the help!

RjOllos a következ?t írta (2021. február 11., csütörtök, 21:44:55 UTC+1):

> On Thursday, February 11, 2021 at 12:40:50 PM UTC-8 RjOllos wrote:
>
>> On Thursday, February 11, 2021 at 11:06:06 AM UTC-8 László Szécsi wrote:
>>
>>> I see the name of the "Implements the permission system for
>>> SimpleMultipleProject" is SmpPermission instead of SmpPermissionPolicy.
>>>
>>
>> The component was renamed SmpPermission -> SmpPermissionPolicy in r17810:
>> https://trac-hacks.org/changeset/17810
>>
>> The recent changes haven't been published to PyPI.
>>
>> https://trac-hacks.org/log/simplemultiprojectplugin?action=stop_on_copy&mode=stop_on_copy&rev=17988&stop_rev=17810&limit=100&sfp_email=&sfph_mail=
>>
>> We need to release a 0.7.2. I will do that later today.
>>
>> Ryan
>>
>
> Done, please try: https://pypi.org/project/TracSimpleMultiProject/0.7.2/
>

--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/trac-users/63a6db94-4c87-4481-8a07-5e5066c44975n%40googlegroups.com.