Edgewall Software

Ticket #7407 (closed defect: invalid)

Opened 5 months ago

Last modified 5 months ago

Unable to load plugin authz_policy.py

Reported by: fermulator@… Owned by: athomas
Priority: normal Milestone:
Component: general Version: 0.11b1
Severity: critical Keywords:
Cc: athomas, cboos

Description

Following: TracFineGrainedPermissions

I cannot get the authz_policy.py plugin to work.

  1. Receive error in trac log:
    2008-07-03 23:55:06,569 Trac[loader] DEBUG: Loading file plugin authz_policy from /..(snip)../trac/my_project/plugins/authz_policy.py
    2008-07-03 23:55:06,570 Trac[loader] ERROR: Failed to load plugin from /..(snip)../trac/my_project/plugins/authz_policy.py
      File "/..(snip)../trac/my_project/plugins/authz_policy.py", line 1
    
  2. Of course because of this, fine grained permissions do not work.

Where is this .py file supposed to go? And, why isn't it an egg?

Attachments

Change History

in reply to: ↑ description   Changed 5 months ago by athomas

Replying to fermulator@sympatico.ca:

Following: TracFineGrainedPermissions I cannot get the authz_policy.py plugin to work. 1. Receive error in trac log:

2008-07-03 23:55:06,569 Trac[loader] DEBUG: Loading file plugin authz_policy from /..(snip)../trac/my_project/plugins/authz_policy.py
2008-07-03 23:55:06,570 Trac[loader] ERROR: Failed to load plugin from /..(snip)../trac/my_project/plugins/authz_policy.py
  File "/..(snip)../trac/my_project/plugins/authz_policy.py", line 1

You've snipped the actual error off...

1. Of course because of this, fine grained permissions do not work. Where is this .py file supposed to go? And, why isn't it an egg?

It's not an egg because it's a single-file plugin. It goes directly into your environments plugins directory.

  Changed 5 months ago by cboos

Well, "line 1", hm, have you verified it's not an empty file?

  Changed 5 months ago by fermulator@…

  • status changed from new to closed
  • resolution set to invalid

omg ... thank you. (funny how you can sit for some time trying to debug something and skip right over an important assumption) ... it's nice to wake up the next morning and have a fresh brain.

When I wget'd the file, I wget'd:

wget http://trac.edgewall.org/browser/trunk/sample-plugins/permissions/authz_policy.py

instead of:

wget http://trac.edgewall.org/browser/trunk/sample-plugins/permissions/authz_policy.py?format=txt/authz_policy.py

i.e. I ended up downloading an HTML file instead of the RAW authz_policy.py.

Sorry for wasting your time dudes.

Add/Change #7407 (Unable to load plugin authz_policy.py)

Author



Change Properties
<Author field>
Action
as closed
Next status will be 'reopened'
to The owner will change from athomas. Next status will be 'closed'
 
Note: See TracTickets for help on using tickets.