Opened on 02/28/2019 at 06:16:44 PM

Closed on 03/05/2019 at 03:47:20 PM

#7317 closed change (fixed)

[python-abp] Make abp a namespace package

Reported by: kvas Assignee: kvas
Priority: P3 Milestone:
Module: Sitescripts Keywords:
Cc: tudor Blocked By:
Blocking: Platform: Unknown / Cross platform
Ready: yes Confidential: no
Tester: Unknown Verified working: no
Review URL(s):

https://codereview.adblockplus.org/30020555/

Description (last modified by kvas)

Background

We are starting to have other packages in the abp namespace, for example abp-request-classifier. If abp is a normal package (not namespace), only one of them can be imported. This is rather suboptimal.

What to change

Make abp in python-abp a namespace package by placing the following line in its __init__.py:

__path__ = __import__('pkgutil').extend_path(__path__, __name__)

This is the second option from namespace packaging guide. Unfortunately we can't go with the first as long as python-abp supports Python 2.

The new version should be released to PyPI. This can be a patch version bump so the new version will be 0.1.1.

Attachments (0)

Change History (5)

comment:1 Changed on 02/28/2019 at 06:18:01 PM by kvas

  • Description modified (diff)
  • Owner set to kvas

comment:2 Changed on 02/28/2019 at 06:35:38 PM by kvas

  • Review URL(s) modified (diff)
  • Status changed from new to reviewing

comment:3 Changed on 03/05/2019 at 03:32:16 PM by abpbot

A commit referencing this issue has landed:
Issue 7317 - Make abp a namespace package

comment:4 Changed on 03/05/2019 at 03:47:11 PM by kvas

comment:5 Changed on 03/05/2019 at 03:47:20 PM by kvas

  • Resolution set to fixed
  • Status changed from reviewing to closed

Add Comment

Modify Ticket

Change Properties
Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from kvas.
 
Note: See TracTickets for help on using tickets.