twisted / twisted

Event-driven networking engine written in Python.
https://www.twisted.org
Other
5.44k stars 1.14k forks source link

Add --quiet option to Trial #3406

Closed twisted-trac closed 15 years ago

twisted-trac commented 15 years ago
thijstriemstra's avatar @thijstriemstra reported
Trac ID trac#3406
Type enhancement
Created 2008-09-02 20:24:49Z

While testing trial --rterrors twisted on a device with very limited memory, it would eventually crash, most likely due to the memory limitation when trying to print the results to screen and write them to file. On unix a workaround would be trial --rterrors twisted > file.txt but this doesn't catch the warnings at startup:

/private/var/mobile/dev/software/twisted/twisted/conch/ssh/common.py:18: RuntimeWarning: PyCrypto not installed, but continuing anyways!
  RuntimeWarning)
/private/var/mobile/dev/software/twisted/twisted/python/reflect.py:391: DeprecationWarning: twisted.flow is unmaintained.
  return __import__(importName)
/private/var/mobile/dev/software/twisted/twisted/scripts/test/test_mktap.py:16: DeprecationWarning: mktap and related support modules are deprecated as of Twisted 8.0.  Use Twisted Application Plugins with the 'twistd' command directly, as described in 'Writing a Twisted Application Plugin for twistd' chapter of the Developer Guide.
  from twisted.scripts.mktap import run, getid
/private/var/mobile/dev/software/twisted/twisted/enterprise/util.py:19: DeprecationWarning: twisted.enterprise.util is deprecated since Twisted 8.0.0.
  category=DeprecationWarning)
/private/var/mobile/dev/software/twisted/twisted/test/test_persisted.py:161: DeprecationWarning: twisted.persisted.marmalade is deprecated
  from twisted.persisted import marmalade
/private/var/mobile/dev/software/twisted/twisted/words/im/__init__.py:8: UserWarning: twisted.im will be undergoing a rewrite at some point in the future.
  warnings.warn("twisted.im will be undergoing a rewrite at some point in the future.")

So perhaps something like a --quiet option, that will also not print anything to file unless I supplied the --logfile=log.txt option?

Searchable metadata ``` trac-id__3406 3406 type__enhancement enhancement reporter__thijs thijs priority__normal normal milestone__ branch__ branch_author__ status__closed closed resolution__invalid invalid component__trial trial keywords__ time__1220387089000000 1220387089000000 changetime__1220619414000000 1220619414000000 version__None None owner__ cc__thijs ```
twisted-trac commented 15 years ago
thijstriemstra's avatar @thijstriemstra set owner to @jml
twisted-trac commented 13 years ago
Automation's avatar Automation removed owner
twisted-trac commented 15 years ago
glyph's avatar @glyph set status to closed

This doesn't sound very well specified. Presumably if you run trial you want it to produce some output. Maybe you mean --only-failures or something, I don't know; but if your iphone crashes then the problem is that your iphone crashes, let's not add features to trial unless they solve a specific problem.

twisted-trac commented 15 years ago
exarkun's avatar @exarkun commented

Additionally, trial --reporter=summary should already cover this case.

twisted-trac commented 15 years ago
thijstriemstra's avatar @thijstriemstra commented

Also noticed #3003 just now :)