Hi,

I'd have to see the source of the extension to really be able to tell you
more, but it sounds like perhaps the extension or its registration (in
setup.py) isn't using absolute module paths to refer to some module.

Would you be able to show me how you're registering it in setup.py, and the
class attributes for your extension?

Thanks,

Christian

-- 
Christian Hammond - christ...@beanbaginc.com
Review Board - https://www.reviewboard.org
Beanbag, Inc. - https://www.beanbaginc.com

On Tue, Nov 3, 2015 at 12:23 PM, Graeme Perrow <graeme.per...@gmail.com>
wrote:

> I am trying to create an authentication extension for reviewboard (running
> 2.0.18). I've followed the authentication backend instructions here
> <https://www.reviewboard.org/docs/manual/2.0/extending/auth-backends/#authentication-classes>
>  and
> the installation instructions here
> <https://www.reviewboard.org/docs/manual/2.0/extending/extensions/distribution/#python-egg>.
> But I'm obviously missing something. My extension shows up in the list of
> available extensions, but attempting to enable it results in a "Loading..."
> message that never goes away.
>
> If I look in the log file (specified in the Logging admin page), I see
> this exception:
>
> relative imports require the 'package' argument
> Traceback (most recent call last):
>   File "/usr/lib/python2.7/site-packages/django/core/handlers/base.py",
> line 112, in get_response
>     response = wrapped_callback(request, *callback_args, **callback_kwargs)
>   File
> "/usr/lib/python2.7/site-packages/django/views/decorators/cache.py", line
> 52, in _wrapped_view_func
>     response = view_func(request, *args, **kwargs)
>   File "/usr/lib/python2.7/site-packages/django/views/decorators/vary.py",
> line 19, in inner_func
>     response = func(*args, **kwargs)
>   File "/usr/lib/python2.7/site-packages/djblets/webapi/resources.py",
> line 497, in __call__
>     request, method, view, api_format=api_format, *args, **kwargs)
>   File "/usr/lib/python2.7/site-packages/djblets/webapi/resources.py",
> line 568, in call_method_view
>     return view(request, *args, **kwargs)
>   File "/usr/lib/python2.7/site-packages/djblets/webapi/resources.py",
> line 765, in put
>     return self.update(request, *args, **kwargs)
>   File "/usr/lib/python2.7/site-packages/djblets/webapi/decorators.py",
> line 117, in _call
>     return view_func(*args, **kwargs)
>   File "/usr/lib/python2.7/site-packages/djblets/webapi/decorators.py",
> line 138, in _checklogin
>     return view_func(*args, **kwargs)
>   File "/usr/lib/python2.7/site-packages/djblets/webapi/decorators.py",
> line 117, in _call
>     return view_func(*args, **kwargs)
>   File "/usr/lib/python2.7/site-packages/djblets/webapi/decorators.py",
> line 164, in _checkpermissions
>     response = view_func(*args, **kwargs)
>   File "/usr/lib/python2.7/site-packages/djblets/webapi/decorators.py",
> line 117, in _call
>     return view_func(*args, **kwargs)
>   File "/usr/lib/python2.7/site-packages/djblets/webapi/decorators.py",
> line 117, in _call
>     return view_func(*args, **kwargs)
>   File "/usr/lib/python2.7/site-packages/djblets/webapi/decorators.py",
> line 287, in _validate
>     return view_func(*args, **new_kwargs)
>   File "/usr/lib/python2.7/site-packages/djblets/extensions/resources.py",
> line 211, in update
>     self._extension_manager.enable_extension(extension_id)
>   File "/usr/lib/python2.7/site-packages/djblets/extensions/manager.py",
> line 310, in enable_extension
>     extension = self._init_extension(ext_class)
>   File "/usr/lib/python2.7/site-packages/djblets/extensions/manager.py",
> line 608, in _init_extension
>     self._reset_templatetags_cache()
>   File "/usr/lib/python2.7/site-packages/djblets/extensions/manager.py",
> line 667, in _reset_templatetags_cache
>     get_templatetags_modules()
>   File "/usr/lib/python2.7/site-packages/django/template/base.py", line
> 1292, in get_templatetags_modules
>     import_module(templatetag_module)
>   File "/usr/lib/python2.7/site-packages/django/utils/importlib.py", line
> 33, in import_module
>     raise TypeError("relative imports require the 'package' argument")
> TypeError: relative imports require the 'package' argument
>
> My actual extension is not listed in the call stack. What am I missing?
>
>
> --
> Supercharge your Review Board with Power Pack:
> https://www.reviewboard.org/powerpack/
> Want us to host Review Board for you? Check out RBCommons:
> https://rbcommons.com/
> Happy user? Let us know! https://www.reviewboard.org/users/
> ---
> You received this message because you are subscribed to the Google Groups
> "reviewboard" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to reviewboard+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Supercharge your Review Board with Power Pack: 
https://www.reviewboard.org/powerpack/
Want us to host Review Board for you? Check out RBCommons: 
https://rbcommons.com/
Happy user? Let us know! https://www.reviewboard.org/users/
--- 
You received this message because you are subscribed to the Google Groups 
"reviewboard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to reviewboard+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to