This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author nnorwitz
Recipients
Date 2003-03-30.20:25:06
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
Logged In: YES 
user_id=33168

Hmmm, sounds like a lot of work.  How about something like this:

    expected_max = resource.RLIM_INFINITY
    if expected_max != max:
        # read the file resource limit
        fsize_ulimit = os.popen('ulimit -f').read()
        try:
            # convert the file size to bytes (from 512 byte
blocks)
            expected_max = int(fsize_ulimit.strip()) * 512
        except ValueError:
            raise TestSkipped, "unable to determine expected
resource value"
    print expected_max == max

This works, but I'm pretty sure this is not portable.  On
Linux blocks are 1k.  This only works when the block size is
512 bytes.  Shall we close this bug as a test environment
problem and won't fix?
History
Date User Action Args
2007-08-23 14:10:38adminlinkissue678264 messages
2007-08-23 14:10:38admincreate