The reason of the crash is that not all targets are always defined for
all packages. In our environment it happens when linked project is
created and sources have just been uploaded to one package.
Here is the crash:
Traceback (most recent call last):
File "../tools-testing/build-package", line 313, in <module>
sys.exit(main(sys.argv))
File "../tools-testing/build-package", line 309, in main
return build(apiurl, tproject, package, timeout)
File "../tools-testing/build-package", line 226, in build
hide_legend=True, csv=True)
File "/usr/lib/python2.7/site-packages/osc/core.py", line 5135, in get_prj_results
row = [pac] + [status[pac][tg] for tg in targets]
status[pac]]
KeyError: ('Fedora_18', 'i586', 'outdated')
Please note that this fix fixes only csv mode. For other modes osc still
can crash, but it's hard to reproduce here as we're not using them.
Signed-off-by: Ed Bartosh <bartosh@gmail.com>
Let "osc develproject" (with new alias "dp") display the devel package
if it doesn't match the package name. Deprecate "--raw" option which
only was a crude workaround for that anyway.
Add "osc setdevelproject" (alias "sdp") command to change a package's
devel project / package.
As long as the timeout is >= 0, Python's _ssl module will still use
non-blocking I/O but not poll() but select(). poll(&fd, 1, TIMEOUT)
seems to block _at least_ TIMEOUT time regardless of any errors.
Currently, with SUSE's internal IPv6 layout, this meant a hang of a
second per binary to fetch during "osc build".
Note: it is probably better to raise a ServiceRuntimeError in
Serviceinfo.execute instead of Package.commit because "execute"
has all the information about the failing service...
There are many places can't be covered by 2to3, especially the
str/unicode -> str/bytes change done in python3. This is a big patch
incorporating all changes made in order to make python3 suite.py run
without any single failure.
It
* adapt the introspect_handler_3 for case there are no __defaults__
* adds the ET_ENCODING variable for ET.fromstring ("unicode" in py3,
"utf-8" in py2)
* (re)adds various builtins to both python versions
- memoryview to python 2.6
- bytes compatible with py3 to 2.6 and 2.7
and it changes few parts of tests/common.py in order to be compatible
with python3
* new urlcompare method compares all components or url + parsed query
string in a dictionary, so the ordering, neither quoting does not matter
* bytes builtin has been added to 2.x and used in assertEqualMultiline
reintroduce unicode function - despite the fact I am pretty sure the
usage is plain wrong, because code says - return a unicode string from
utf-8 encoded one, which is probably not what was intended. I bet
something like encode the input as utf-8 was wanted.
raw_input has been removed and equals to input in py3. Unfortunatelly no
__future__ statement exists for that. Ensure all modules uses
osc.core.raw_input except osc.cmdln, where there is NameError way
implemented.
The most visible change in python3 - removal of print statement and all
the crufty
print >> sys.stderr, foo,
The from __future__ import print_function makes it available in python
2.6