Skip to content

The new doctesting framework doesn't like being run with nohup #14307

@kiwifb

Description

@kiwifb

When run inside nohup test are failing to run with the new doctesting framework in 5.9.beta0. An example

fbissey@QCD-nzi3 /home/work/fbissey/sandbox/sage-5.9.beta0 $ ./sage -t --long "devel/sage-main/sage/misc/inline_fortran.py"
Running doctests with ID 2013-03-19-22-26-09-85e3b5eb.
Doctesting 1 file.
sage -t --long devel/sage-main/sage/misc/inline_fortran.py
    [10 tests, 1.1 s]
----------------------------------------------------------------------
All tests passed!
----------------------------------------------------------------------
Total time for all tests: 1.1 seconds
    cpu time: 0.1 seconds
    cumulative wall time: 1.1 seconds

But when the same thing is run with nohup

nohup ./sage -t --long "devel/sage-main/sage/misc/inline_fortran.py" &

The output is

Running doctests with ID 2013-03-19-22-26-21-d52d31ab.
Doctesting 1 file.
sage -t --long devel/sage-main/sage/misc/inline_fortran.py
Process DocTestWorker-1:
Traceback (most recent call last):
  File "/home/work/fbissey/sandbox/sage-5.9.beta0/local/lib/python/multiprocessing/process.py", l
ine 258, in _bootstrap
    self.run()
  File "/home/work/fbissey/sandbox/sage-5.9.beta0/local/lib/python2.7/site-packages/sage/doctest/
forker.py", line 1655, in run
    sys.stdin = os.fdopen(0, "r")
OSError: [Errno 22] Invalid argument
    Bad exit: 1
**********************************************************************
Tests run before process failed:

**********************************************************************
----------------------------------------------------------------------
sage -t --long devel/sage-main/sage/misc/inline_fortran.py  # Bad exit: 1
----------------------------------------------------------------------
Total time for all tests: 0.0 seconds
    cpu time: 0.0 seconds
    cumulative wall time: 0.0 seconds

This is with the following version of nohup

nohup --version
nohup (GNU coreutils) 8.20
Packaged by Gentoo (8.20 (p1.0))
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute 

Depends on #12415

CC: @jdemeyer

Component: doctest framework

Author: Jeroen Demeyer

Reviewer: François Bissey

Merged: sage-5.9.beta1

Issue created by migration from https://trac.sagemath.org/ticket/14307

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions