Bug 508991 - remove rhpl usage
Summary: remove rhpl usage
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: system-config-firewall
Version: rawhide
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Thomas Woerner
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: rhplectomy
TreeView+ depends on / blocked
 
Reported: 2009-06-30 18:33 UTC by Jeremy Katz
Modified: 2009-09-14 12:54 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2009-09-14 12:54:55 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
untested patch (4.68 KB, patch)
2009-06-30 18:39 UTC, Jeremy Katz
no flags Details | Diff

Description Jeremy Katz 2009-06-30 18:33:25 UTC
system-config-firewall only depends on rhpl for rhpl.translate, but is actually only working through a bit of an accident at present.

The usual case is to replace imports of rhpl.translate for _ and N_ with
  import gettext
  _ = lambda x: gettext.ldgettext(domain, x)
  N_ = lambda x: x 

system-config-firewall only does the import in one place (fw_config), but 
  from fw_config import *
doesn't actually put _ in your namespace as _ is a reserved character.  s-c-firewall ends up getting translations just because it also imports part of system-config-network which does a global override of the _ builtin.

Comment 1 Jeremy Katz 2009-06-30 18:39:52 UTC
Created attachment 350003 [details]
untested patch

Here's an (untested) patch that I think should fix things up for you and switch to not using rhpl in the process


Note You need to log in before you can comment on or make changes to this bug.