Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

scons: 3.1.2 -> 4.0.0 #92920

Merged
merged 2 commits into from Jul 18, 2020
Merged

scons: 3.1.2 -> 4.0.0 #92920

merged 2 commits into from Jul 18, 2020

Conversation

primeos
Copy link
Member

@primeos primeos commented Jul 11, 2020

Motivation for this change

The build works and building e.g. xsettingsd with Scons 4.0.0 also succeeds, but I didn't manage to avoid disabling the tests so far.

Without disabling the tests the build fails with:
++ cp -f /nix/store/fscd8f71wmpwphcmi5mx8qnif2402x9m-run_setup.py nix_run_setup
++ /nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/bin/python3.8 nix_run_setup test
running test
WARNING: Testing via this command is deprecated and will be removed in a future version. Users looking for a generic test entry point independent of test runner are encouraged to use tox.
running egg_info
writing SCons.egg-info/PKG-INFO
writing dependency_links to SCons.egg-info/dependency_links.txt
writing entry points to SCons.egg-info/entry_points.txt
writing requirements to SCons.egg-info/requires.txt
writing top-level names to SCons.egg-info/top_level.txt
reading manifest file 'SCons.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'SCons.egg-info/SOURCES.txt'
running build_ext
Traceback (most recent call last):
  File "/build/SCons-4.0.0/SCons/Script/SConscript.py", line 420, in _get_SConscript_filenames
    dirs = kw["dirs"]
KeyError: 'dirs'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "nix_run_setup", line 8, in <module>
    exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\\r\\n', '\\n'), __file__, 'exec'))
  File "setup.py", line 40, in <module>
    setup(
  File "/nix/store/p5m9mjzkqmxj0a5vscbfwl08aaa42w4h-python3.8-setuptools-47.3.1/lib/python3.8/site-packages/setuptools/__init__.py", line 161, in setup
    return distutils.core.setup(**attrs)
  File "/nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/lib/python3.8/distutils/core.py", line 148, in setup
    dist.run_commands()
  File "/nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/lib/python3.8/distutils/dist.py", line 966, in run_commands
    self.run_command(cmd)
  File "/nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/lib/python3.8/distutils/dist.py", line 985, in run_command
    cmd_obj.run()
  File "/nix/store/p5m9mjzkqmxj0a5vscbfwl08aaa42w4h-python3.8-setuptools-47.3.1/lib/python3.8/site-packages/setuptools/command/test.py", line 238, in run
    self.run_tests()
  File "/nix/store/p5m9mjzkqmxj0a5vscbfwl08aaa42w4h-python3.8-setuptools-47.3.1/lib/python3.8/site-packages/setuptools/command/test.py", line 256, in run_tests
    test = unittest.main(
  File "/nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/lib/python3.8/unittest/main.py", line 100, in __init__
    self.parseArgs(argv)
  File "/nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/lib/python3.8/unittest/main.py", line 124, in parseArgs
    self._do_discovery(argv[2:])
  File "/nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/lib/python3.8/unittest/main.py", line 244, in _do_discovery
    self.createTests(from_discovery=True, Loader=Loader)
  File "/nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/lib/python3.8/unittest/main.py", line 154, in createTests
    self.test = loader.discover(self.start, self.pattern, self.top)
  File "/nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/lib/python3.8/unittest/loader.py", line 349, in discover
    tests = list(self._find_tests(start_dir, pattern))
  File "/nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/lib/python3.8/unittest/loader.py", line 405, in _find_tests
    tests, should_recurse = self._find_test_path(
  File "/nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/lib/python3.8/unittest/loader.py", line 483, in _find_test_path
    tests = self.loadTestsFromModule(package, pattern=pattern)
  File "/nix/store/p5m9mjzkqmxj0a5vscbfwl08aaa42w4h-python3.8-setuptools-47.3.1/lib/python3.8/site-packages/setuptools/command/test.py", line 55, in loadTestsFromModule
    tests.append(self.loadTestsFromName(submodule))
  File "/nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/lib/python3.8/unittest/loader.py", line 191, in loadTestsFromName
    return self.loadTestsFromModule(obj)
  File "/nix/store/p5m9mjzkqmxj0a5vscbfwl08aaa42w4h-python3.8-setuptools-47.3.1/lib/python3.8/site-packages/setuptools/command/test.py", line 55, in loadTestsFromModule
    tests.append(self.loadTestsFromName(submodule))
  File "/nix/store/7q4crsd8kvmma32ff2xw4w9ydj5k26cy-python3-3.8.3/lib/python3.8/unittest/loader.py", line 205, in loadTestsFromName
    test = obj()
  File "/build/SCons-4.0.0/SCons/Script/SConscript.py", line 661, in __call__
    return method(*args, **kw)
  File "/build/SCons-4.0.0/SCons/Script/SConscript.py", line 596, in SConscript
    files, exports = self._get_SConscript_filenames(ls, subst_kw)
  File "/build/SCons-4.0.0/SCons/Script/SConscript.py", line 422, in _get_SConscript_filenames
    raise SCons.Errors.UserError("Invalid SConscript usage - no parameters")
SCons.Errors.UserError: Invalid SConscript usage - no parameters

Unfortunately I don't really know what's going on here or how to best debug this.
@FRidh @jonringer do you have any ideas what's going on here? Is there something we should do about the build failure with the checks enabled (probably due to our abstractions) or should we just ignore it as SCons doesn't provide any tests anyway?

TODOs:

  • Properly reflect the Python 2 deprecation
  • Test the rebuilds
Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

Required since SCons 4.0.0 doesn't support Python 2.7 anymore.
@primeos primeos marked this pull request as ready for review July 18, 2020 08:52
@primeos
Copy link
Member Author

primeos commented Jul 18, 2020

nixpkgs-review result:

110 package updated:
aj-snapshot alfred aspcud bombono btanks cabal2nix carla conky d1x-rebirth-full d2x-rebirth-full dep2nix-unstable digikam digikam dxx-rebirth dxx-rebirth dxx-rebirth endless-sky faust2jack-unstable faust2jaqt-uns
table fceux-unstable ffado ffado fluxus foxtrotgps foxtrotgps gambatte giada git git git-with-svn glob2 godot goxel gpredict gpsd gpshell gringo gtklick gtkmathview hammer-e7aa734 hydra hydra jack1 jack2 jackmix
jackmix kexi klick kreport lprof lsp-plugins ltc-tools luppp lutris lutris lutris-original marble mariadb-galera mixxx mongodb mongodb mongodb mongodb nix-prefetch-scripts nix-prefetch-svn nix-update-source nova-
filters nsis ocaml4.10.0-dune-release opam opam perl5.28.3-SVN-Simple perl5.30.3-SVN-Simple pulseeffects qlandkartegt rapidsvn reposurgeon rhvoice-unstable rmlint scons (3.1.2 → 4.0.0) serf shotcut sonic-pi sound
tracker subversion subversion subversion subversion-client svn-all-fast-export svn2git svnfs swift-im swiften swiftformat Tambura tdm tetraproc the-powder-toy toluapp tuxguitar urjtag vcstool vdrift-git vdrift-gi
t-with-data viking webbrowser webcamoid xboxdrv xsettingsd ydiff

3 package marked as broken and skipped:
gpshell gtkmathview swiftformat

3 package failed to build:
d1x-rebirth-full d2x-rebirth-full tdm

98 package built:
aj-snapshot alfred aspcud bombono btanks cabal2nix carla conky d1x_rebirth dep2nix digikam dune-release endless-sky faust2jack faust2jaqt fceux ffado fluxus tangogps gambatte giada git-doc gitAndTools.gitFull gitAndTools.gitSVN gitAndTools.svn-all-fast-export gitAndTools.svn2git globulation2 godot goxel gpredict gpsd gringo gtklick hammer hydra-migration hydra-unstable jack1 jack2 jackmix jackmix_jack1 kdeApplications.marble kexi klick libsForQt5.kreport lprof lsp-plugins ltc-tools luppp lutris lutris-free lutris-unwrapped mariadb-galera mixxx mongodb mongodb-3_6 mongodb-4_0 nix-prefetch-scripts nix-prefetch-svn nix-update-source nova-filters nsis opam opam_1_2 perl528Packages.SVNSimple perl530Packages.SVNSimple pulseeffects qlandkartegt rapidsvn reposurgeon rhvoice rmlint scons serf shotcut sonic-pi soundtracker subversion subversion19 subversionClient subversion_1_10 svnfs swift-im swiften tambura tetraproc the-powder-toy toluapp tuxguitar urjtag vcstool vdrift vdrift-bin viking webbrowser webcamoid xboxdrv xsettingsd ydiff

All three failures are unrelated to this PR.

@primeos primeos merged commit 5b14758 into NixOS:staging Jul 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant