#9 More correctly unbundle flexcache
Merged 6 months ago by mrunge. Opened 7 months ago by music.
rpms/ music/python-pint flexcache  into  rawhide

file modified
+3 -2
@@ -74,10 +74,11 @@ 

  # The find-then-modify pattern keeps us from discarding mtimes on sources that

  # do not need modification.

  find pint -type f -exec \

-     gawk '/^from \.+_vendor import (appdirs|flexcache)/ {

+     gawk '/^from (\.*|pint)\._vendor import (appdirs|flexcache)/ {

          print FILENAME; nextfile }' '{}' '+' |

    xargs -r -t sed -r -i \

-       's/^from \.+_vendor (import (appdirs|flexcache))/\1/'

+       -e 's/^from (\.*|pint)\._vendor (import (appdirs))/\2/' \

+       -e 's/^(from )(\.*|pint)\._vendor( import (flexcache))/\1\4\3/'



  # We omit the “uncertainties” extra because python-uncertainties is not yet

The old approach works, but the exact replacement for pint._vendor.flexcache should be flexcache.flexcache, not just flexcache. Furthermore, this now correctly replaces “from pint._vendor” if that appears in the test suite.

These distinctions will actually matter when 0.20 adds a pint._vendor.flexparser and we start unbundling that.

Build succeeded.

Pull-Request has been merged by mrunge

6 months ago