Opened on 09/18/2017 at 07:15:15 PM

Closed on 10/04/2017 at 12:44:26 PM

Last modified on 10/08/2019 at 05:56:41 PM

#5729 closed defect (fixed)

remove_redundant_translations fails due to the presence of system file

Reported by: diegocarloslima Assignee: jwangenheim
Priority: P2 Milestone: Adblock-Browser-for-Android-1.3.0
Module: Adblock-Browser-for-Android Keywords:
Cc: jwangenheim Blocked By:
Blocking: Platform: Adblock Browser for Android
Ready: yes Confidential: no
Tester: Unknown Verified working: yes
Review URL(s):


How to reproduce

  1. On a mac, access through Finder adblockbrowser/mobile/android/base/locales/adblockbrowser/. It will produce a .DS_Store file on that folder.
  2. Run python get API_KEY

Observed behaviour

The script fails with the following error:

Traceback (most recent call last):
  File "", line 98, in <module>
  File "", line 84, in remove_redundant_translations
    if not filecmp.dircmp(locale_path, default_locale_path).diff_files:
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 238, in __getattr__
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 174, in phase3
    xx = cmpfiles(self.left, self.right, self.common_files)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 238, in __getattr__
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 143, in phase2
    for x in self.common:
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 238, in __getattr__
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 132, in phase1
    a = dict(izip(imap(os.path.normcase, self.left_list), self.left_list))
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 238, in __getattr__
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 124, in phase0
    self.left_list = _filter(os.listdir(self.left),
OSError: [Errno 20] Not a directory: '/Users/dlima/Workspace/adblockbrowser/mobile/android/base/locales/adblockbrowser/.DS_Store'

Expected behaviour

The script should complete successfully. Files (and ideally hidden directories) should be ignored in remove_redundant_translationsfunction

Attachments (0)

Change History (6)

comment:1 Changed on 09/19/2017 at 07:40:47 AM by jwangenheim

  • Owner set to jwangenheim

comment:2 Changed on 09/19/2017 at 10:09:02 AM by jwangenheim

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

comment:3 Changed on 10/04/2017 at 12:43:16 PM by abpbot

comment:4 Changed on 10/04/2017 at 12:44:26 PM by jwangenheim

  • Milestone set to Adblock-Browser-for-Android-next
  • Resolution set to fixed
  • Status changed from reviewing to closed

comment:5 Changed on 10/23/2017 at 01:41:13 PM by traynard

  • Verified working set

Confirmed with Diego that this is a build issue

comment:6 Changed on 08/19/2019 at 05:48:12 PM by sunnyydv12


Last edited on 10/08/2019 at 05:56:41 PM by kzar

Add Comment

Modify Ticket

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