Debian Bug report logs - #890280
ufo2ft: please make the output reproducible

version graph

Package: src:ufo2ft; Maintainer for src:ufo2ft is Debian Fonts Task Force <debian-fonts@lists.debian.org>;

Reported by: Chris Lamb <lamby@debian.org>

Date: Mon, 12 Feb 2018 21:45:01 UTC

Severity: wishlist

Tags: fixed-upstream, patch

Found in version ufo2ft/1.1.0-1

Fixed in version 2.1.0-1

Done: Adrian Bunk <bunk@debian.org>

Bug is archived. No further changes may be made.

Forwarded to https://github.com/googlei18n/ufo2ft/pull/219

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, reproducible-bugs@lists.alioth.debian.org, Debian Fonts Task Force <pkg-fonts-devel@lists.alioth.debian.org>:
Bug#890280; Package src:ufo2ft. (Mon, 12 Feb 2018 21:45:04 GMT) (full text, mbox, link).


Acknowledgement sent to Chris Lamb <lamby@debian.org>:
New Bug report received and forwarded. Copy sent to reproducible-bugs@lists.alioth.debian.org, Debian Fonts Task Force <pkg-fonts-devel@lists.alioth.debian.org>. (Mon, 12 Feb 2018 21:45:04 GMT) (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: Chris Lamb <lamby@debian.org>
To: submit@bugs.debian.org
Subject: ufo2ft: please make the output reproducible
Date: Mon, 12 Feb 2018 21:40:31 +0000
[Message part 1 (text/plain, inline)]
Source: ufo2ft
Version: 1.1.0-1
Severity: wishlist
Tags: patch
User: reproducible-builds@lists.alioth.debian.org
Usertags: toolchain timestamps
X-Debbugs-Cc: reproducible-bugs@lists.alioth.debian.org

Hi,

Whilst working on the Reproducible Builds effort [0], we noticed
that ufo2ft generates .otf files that are not reproducible.

For example, here is showotf output of fonts-league-spartan:

│ │ │ │ │  HEAD table (at 188)
│ │ │ │ │  	Version=1
│ │ │ │ │  	fontRevision=2
│ │ │ │ │ -	checksumAdj=e32dbbe4
│ │ │ │ │ +	checksumAdj=e3309724
│ │ │ │ │  	magicNumber=5f0f3cf5 (0x5f0f3cf5, diff=0)
│ │ │ │ │  	flags=3 baseline_at_0 lsb_at_0 
│ │ │ │ │  	unitsPerEm=1250
│ │ │ │ │  	create[0]=0
│ │ │ │ │ -	 create[1]=d580d7b0
│ │ │ │ │ -	File created: Tue Jul  4 05:27:12 2017
│ │ │ │ │ +	 create[1]=d57f6a10
│ │ │ │ │ +	File created: Mon Jul  3 03:27:12 2017

… which shows that it varies on the timezone.

Patch attached:

  --- a/Lib/ufo2ft/fontInfoData.py
  +++ b/Lib/ufo2ft/fontInfoData.py
  @@ -13,6 +13,7 @@ used externally as well.
   
   from __future__ import print_function, division, absolute_import, unicode_literals
   
  +import datetime
   import logging
   import math
   import time
  @@ -516,7 +517,8 @@ def intListToNum(intList, start, length):
   
   def dateStringToTimeValue(date):
       try:
  -        t = time.strptime(date, "%Y/%m/%d %H:%M:%S")
  -        return int(time.mktime(t))
  -    except OverflowError:
  +        dt = datetime.datetime.strptime(date, "%Y/%m/%d %H:%M:%S")
  +        dt = dt.replace(tzinfo=datetime.timezone.utc)
  +        return int(dt.timestamp())
  +    except ValueError:
           return 0


 [0] https://reproducible-builds.org/


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      lamby@debian.org / chris-lamb.co.uk
       `-
[ufo2ft.diff.txt (text/plain, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Fonts Task Force <pkg-fonts-devel@lists.alioth.debian.org>:
Bug#890280; Package src:ufo2ft. (Mon, 12 Feb 2018 21:57:09 GMT) (full text, mbox, link).


Acknowledgement sent to Chris Lamb <lamby@debian.org>:
Extra info received and forwarded to list. Copy sent to Debian Fonts Task Force <pkg-fonts-devel@lists.alioth.debian.org>. (Mon, 12 Feb 2018 21:57:09 GMT) (full text, mbox, link).


Message #10 received at 890280@bugs.debian.org (full text, mbox, reply):

From: Chris Lamb <lamby@debian.org>
To: 890280@bugs.debian.org
Subject: Re: ufo2ft: please make the output reproducible
Date: Mon, 12 Feb 2018 21:53:53 +0000
forwarded 890280 https://github.com/googlei18n/ufo2ft/pull/219
thanks

I've forwarded this upstream here:

  https://github.com/googlei18n/ufo2ft/pull/219


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      lamby@debian.org / chris-lamb.co.uk
       `-



Set Bug forwarded-to-address to 'https://github.com/googlei18n/ufo2ft/pull/219'. Request was from Chris Lamb <lamby@debian.org> to control@bugs.debian.org. (Mon, 12 Feb 2018 21:57:10 GMT) (full text, mbox, link).


Information forwarded to debian-bugs-dist@lists.debian.org, Debian Fonts Task Force <pkg-fonts-devel@lists.alioth.debian.org>:
Bug#890280; Package src:ufo2ft. (Wed, 14 Feb 2018 19:51:09 GMT) (full text, mbox, link).


Acknowledgement sent to Chris Lamb <lamby@debian.org>:
Extra info received and forwarded to list. Copy sent to Debian Fonts Task Force <pkg-fonts-devel@lists.alioth.debian.org>. (Wed, 14 Feb 2018 19:51:09 GMT) (full text, mbox, link).


Message #17 received at 890280@bugs.debian.org (full text, mbox, reply):

From: Chris Lamb <lamby@debian.org>
To: 890280@bugs.debian.org
Subject: Re: ufo2ft: please make the output reproducible
Date: Wed, 14 Feb 2018 19:48:55 +0000
Chris Lamb wrote:

> I've forwarded this upstream here:
>
>  https://github.com/googlei18n/ufo2ft/pull/219

Note that the patch has been updated at the above URI after some
feedback.


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      lamby@debian.org / chris-lamb.co.uk
       `-



Added tag(s) fixed-upstream. Request was from bts-link-upstream@lists.alioth.debian.org to control@bugs.debian.org. (Mon, 19 Feb 2018 17:09:22 GMT) (full text, mbox, link).


Reply sent to Adrian Bunk <bunk@debian.org>:
You have taken responsibility. (Tue, 18 Sep 2018 10:15:07 GMT) (full text, mbox, link).


Notification sent to Chris Lamb <lamby@debian.org>:
Bug acknowledged by developer. (Tue, 18 Sep 2018 10:15:07 GMT) (full text, mbox, link).


Message #24 received at 890280-done@bugs.debian.org (full text, mbox, reply):

From: Adrian Bunk <bunk@debian.org>
To: 890280-done@bugs.debian.org
Subject: Fixed in 2.1.0-1
Date: Tue, 18 Sep 2018 13:12:48 +0300
Version: 2.1.0-1

The fix is included in 2.1.0-1.

cu
Adrian

-- 

       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Wed, 17 Oct 2018 07:29:55 GMT) (full text, mbox, link).


Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Wed May 17 10:14:26 2023; Machine Name: buxtehude

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.