1
0
mirror of https://github.com/openSUSE/osc.git synced 2024-09-22 02:06:18 +02:00
Commit Graph

3441 Commits

Author SHA1 Message Date
Marcus Huewe
f12c7747d0 Merge branch 'approver' of https://github.com/adrianschroeter/osc
Introduce "osc request approval..." and "osc request cancelapproval"
commands.
2018-10-18 15:23:06 +02:00
e1fd0b4ee9 add support for approved requests (requires OBS 2.10) 2018-10-18 13:26:39 +02:00
Marcus Huewe
25014c326f Merge branch 'fix_413_get_deleted_sources' of https://github.com/lethliel/osc
Introduce --deleted option to "osc co" for checking out the files of
a deleted package (no package wc is established).
2018-10-18 12:59:55 +02:00
lethliel
0123bb71db fixes 413 checkout deleted package
* altered command do_checkout
  new option -D | --deleted. Can only be used with PACKAGE and needs
  -o to work

* what happens:
  core function checkout_deleted_package fetches the file list of the deleted
  package and saves it to given destdir. If destdir is not existent it
  creates the destination directory. Otherwise the files will be written
  in the existing directory.
2018-10-18 08:59:05 +02:00
Marcus Huewe
d83bf74984 Merge branch 'unclear_error_message' of https://github.com/lethliel/osc
Improve error message in rpmquery.py
2018-10-15 22:18:37 +02:00
lethliel
9ffe9b9288 improve error message if file is not a valid rpm
The current error message is quite confusing and nobody knows what
"invalid lead magic" means.
2018-10-09 10:16:27 +02:00
c5ec3ce807 support checkconstraints command without local checkout 2018-10-02 10:45:38 +02:00
lethliel
f643e37eb1 print error and exit if p.apiurl != -A <apiurl>
Print error and exit if osc -A <apiurl> sr is issued on a
package with a different apiurl in its working copy. This leads
to unexpected behavior, because the SR is created for the package
apiurl, not the apiurl given by the -A command line option.
2018-09-25 13:48:09 +02:00
Johannes Kastl
ba66a0bc1d change keep-link description to make it easier to understand 2018-09-17 20:50:27 +02:00
Marco Strigl
48e71b0255
Merge pull request #438 from andreas-schwab/token
Clarify use of osc token
2018-08-31 11:16:04 +02:00
Marcus Huewe
f1c31561cb Merge branch 'clean_xpath' of https://github.com/lethliel/osc
Let's get rid of this old cruft.
2018-08-30 14:13:00 +02:00
153032bc11 fix local multibuild flavor support when package does not exist ('_repository' case) 2018-08-22 11:20:40 +02:00
ae2656b415 open 0.164 development 2018-08-21 10:34:53 +02:00
d82b30636f release 0.163.0 2018-08-20 13:19:29 +02:00
Marcus Huewe
86e5757832 Refactor the do_vc code a bit
No functional changes.
2018-08-17 22:45:28 +02:00
Marcus Huewe
820c3adc71 Consider the "realname" config option in apiurl sections
This is a follow up fix for commit ef13d67 ("Export a real name
for vc to consume").
2018-08-17 22:45:17 +02:00
Marcus Huewe
6233f8bf0b Merge branch 'moreuserinfoforvc' of https://github.com/Conan-Kudo/osc
Adds support for full author identities in changes files (see also
https://github.com/openSUSE/obs-build/pull/214).
2018-08-17 21:14:30 +02:00
2566d6aa73 add podman build support 2018-08-14 13:02:16 +02:00
Andreas Schwab
4eae5d9a45 Clarify use of osc token
Clarify the fact that the parameters of osc token -t and osc token -d are
of different types.
2018-08-12 13:36:24 +02:00
lethliel
69983249ef cleanup xpath. submit/* is ignored by the API since 2012 2018-08-07 11:53:49 +02:00
ef13d67208 Export a real name for vc to consume 2018-08-01 09:43:14 -04:00
Marcus Huewe
bc57f89e9e Merge branch 'fix_indent_for_python3' of https://github.com/lethliel/osc
Fixes a single indentation.
2018-07-06 10:29:34 +02:00
lethliel
779b66f3c3 fixed indentation of return[].
It works in python2, but will break in python3
2018-07-06 09:54:59 +02:00
4cc87b2c57 fix DISTURL checkout for package containers using a multibuild flavor 2018-06-27 10:25:45 +02:00
Sean Kelly
b42e6f5e04 Support larger uids and gids 2018-06-25 16:55:47 -04:00
Marcus Huewe
b730f880cf Disable ssl session resumption
The old code could potentially yield to a use-after-free situation,
which results in UB. For this, consider the following scenario, where
osc performs several HTTPS requests (assumption: the server supports
ssl session resumption):

- HTTPS Request 1:
  * a new SSL *s connection is established, which also creates a new
    SSL_SESSION *ss => ss->references == 1
  * once the handshake is done, the ss is put into the session cache
    (see ssl_update_cache) => ss->references == 2
  - osc saves the session ss in a class variable
  - s is SSL_free()d, which calls SSL_SESSION_free => ss->references == 1

- HTTPS Request 2:
  * setup a new SSL *s connection that reuses the saved session ss
    => ss->references == 2
  * once the handshake is done, ssl_update_cache is called, which is a
    NOP, because s->hit == 1 (that is, the session was resumed)
  * osc saves the session ss in a class variable
  * s is SSL_free()d, which calls SSL_SESSION_free => ss->references == 1

...

> 2 hours later (see tls1_default_timeout)

...

- HTTPS Request 256:
  * setup a new SSL *s connection that reuses the saved session ss
    => ss->references == 2
  * once the handshake is done, ssl_update_cache is called, but is
    _no_ NOP anymore
  * ssl_update_cache flushes the session cache (this is done every
    255/256 (depending on the way we count) connections) => ss is
    SSL_SESSION_free()d => ss->references == 1
  * osc saves the session ss in a class variable
  * s is SSL_free()d, which calls SSL_SESSION_free:
    since ss->references == 1, ss is eventually free()d

- HTTPS Request 257:
  * setup a new SSL *s connection that reuses the saved session ss

Since ss does not exist anymore, the remaining program execution is UB.

(Note: SSL_free(...) is _NOT_ called, if M2Crypto 0.29 is used.
M2Crypto 0.30 calls SSL_free(...) again.)

Due to a bug in OpenSSL_1_1_0h (see openssl commit 8e405776858) the
scenario from above can be triggered with exactly 2 HTTPS requests (the
SSL_SESSION is not cached, because we configured SSL_VERIFY_PEER, but
no sid_ctx was set). This is fixed in openssl commit c4fa1f7fc01.

In order to reliably reuse a session, we probably need to listen to the
session cache changes. Such callbacks could be registered via
SSL_CTX_sess_set_new_cb and/or SSL_CTX_sess_set_remove_cb, but both
functions are not provided by M2Crypto. Another idea is to directly utilize
the session cache, but this also has to be implemented in M2Crypto first.
Yet another approach is to retrieve the session via SSL_get1_session, which
increases the session's refcnt, but this also needs to be implemented in
M2Crypto first (if we choose to use this approach, we also have to make
sure that we eventually free the session manually...).

Fixes: #398 ("SIGSEGV on \"osc commit\"")
2018-05-08 14:32:33 +02:00
jonsger
6bd8572cf7
Fix typo in "osc revert" help 2018-05-03 16:16:38 +02:00
Marcus Huewe
d6a04e5327 Merge branch 'master' of https://github.com/adrianschroeter/osc
Always pass the "--statistics" option to the build script (only affects
a vm build). It is not implemented as an option, because we already have
so many of them... (see also https://github.com/openSUSE/osc/pull/412).
2018-05-03 11:02:57 +02:00
Marcus Huewe
88274c92ed Merge branch 'fix_newline_in_verbose' of https://github.com/lethliel/osc
Print each unresolvable on a separate line.
2018-05-03 09:57:02 +02:00
0c3edd3fa0 always run build using --statistics. I could have made this
yet another option, but
* only very old build scripts don't know it, we should just require a recent one
* build script is ignoring it for chroot case

so why bother with another option?
2018-04-27 15:01:09 +02:00
bfcfddb0da fix some commands when used with / syntax between arguments 2018-04-27 14:41:08 +02:00
628f7e2cf5 - support "addcontainers" command 2018-04-27 09:16:13 +02:00
Marcus Huewe
d756f56af2 Show diff when creating a new comment (interactive_review)
Note that the diff is only shown, if it was requested before (that is
the "i" command was issued). The new behavior is consistent with the
other commands like "a", "d" etc.
2018-04-26 17:01:49 +02:00
lethliel
b7ada2cb5b fix missing newline in osc r -v
This adds a newline after unresolvable:. So the
messages are now well printed.
2018-04-26 15:38:25 +02:00
Marcus Huewe
cbd10644a2 Merge branch 'fix_IncompleteRead' of https://github.com/lethliel/osc
Retry 3 times in print_buildlog in case of an incomplete read. (Instead
of 3, the "http_retries" config option might be more appropriate.)
2018-04-25 11:02:52 +02:00
lethliel
1caa825e89 fixed IncompleteRead(0) error on long builds.
catch IncompleteRead() and retry until retry_counter is
reached. Then re-raise IncompleteRead()
2018-04-24 10:44:46 +02:00
lethliel
eb2647fd4f fix order of options valdiation. Now -P and -p is
honored if given by user.
2018-04-18 16:04:06 +02:00
fba9af7eee add new options to diff command:
--unexpand for local diffs only (bsc#1089025)
--meta for diffing meta files
2018-04-11 08:01:45 +02:00
Marcus Huewe
5341f3aae5 Merge branch 'fix_dod_get_binaries' of https://github.com/lethliel/osc
Support dod binaries in core.get_binarylist.
2018-03-14 14:06:13 +01:00
lethliel
9b42897413 fix getbinaries with DOD binaries
getbinaries of dod binaries do not have a size or mtime.
This will break. So just set to None and print unkown instead.
2018-03-14 13:45:38 +01:00
Marcus Huewe
a25209ac31 Merge branch 'improve_created_binaries_msg' of https://github.com/lethliel/osc
Improve message that is printed during "osc getbinaries...".
2018-03-13 15:16:12 +01:00
lethliel
e042c585c0 change output when creating binaries directory
was:
Creating binaries

is now:
Creating directory "binaries"
2018-03-13 15:00:46 +01:00
Marcus Huewe
caaefb0bf5 Fix and simplify util.safewriter.SafeWriter
Storing the error encoding in an "encoding" attribute "breaks" the
python3 "input" function: In essence, builtin_input_impl does a
getattr(sys.stdout, 'encoding'), which returns our error encoding
instead of the "real" stdout encoding. In order to avoid this, we
store the error encoding in an "_encoding" attribute.

Making SafeWriter a new-style class simplifies the code a lot.
2018-03-09 16:55:56 +01:00
305501f92c Revert "handle SSL connection closing ourself as advised in boo#1068470 bye"
This reverts commit 0ddb598743.

was incomplete and seems to be the wrong approach
2018-02-26 15:54:20 +01:00
Marcus Huewe
5fb71aa6d4 Merge branch 'fix_385' of https://github.com/lethliel/osc
Fix for python26, since it does not support an epath/xpath like
.//entry[@hash].

Fixes: #385 ("osc 0.162.x does not work anymore on SLE11")
2018-02-23 13:29:11 +01:00
Marco Strigl
e017a8e237 do not use complex path separator fixes #385
This is a fix for issue #385. osc commit breaks due to
the use of sfilelist.findall('.//entry[@hash]')

I now will iterate through the sfilelist and use

for entry in sfilelist.findall('entry'):
    if entry.get('hash'):
        ... execute hash code ...

This is a little bit slower, but should not break
on SLE11 anymore
2018-02-23 13:24:48 +01:00
0ddb598743 handle SSL connection closing ourself as advised in boo#1068470 bye
M2Crypto upstream maintainer.

Should fix hanging connections
2018-02-23 07:33:27 +01:00
Björn Geuken
030c2a41f8 Fix typo in example for osc search 2018-02-18 21:27:22 +01:00
Marcus Huewe
8948a26ae4 Fix --multibuild-package option handling in do_sendsysrq
Concatenating a str and a list does not work.
2018-02-09 15:35:52 +01:00
7fc251d81e fix sendsysrq command description 2018-02-09 10:08:13 +01:00
80352cbfc7 add sendsysrq command 2018-02-09 08:50:21 +01:00
Marcus Huewe
9c4f0d5d30 Ignore "--alternative-project <prj>" if it is equal to the wc's project
Without this change, using "--alternative-project <prj>" in combination
with "--multibuild-package <flavor>" yields to unexpected results (from
a user's point of view). Note that this may break existing (artificial)
workflows (e.g., using --alternative-project to ignore the package
meta's debuginfo flag), but these workflows should be rare and there
are options to achieve the same.

Fixes: #376 ("osc build -M something does not work with
--alternative-project")
2018-02-07 14:35:35 +01:00
Andreas Schwab
50222810f0 osc chroot: also mount devpts
This is needed for running expect, for example.
2018-01-28 16:53:52 +01:00
5e3fe8ba08 give a hint which package to install to get CA certificates 2018-01-26 09:46:52 +01:00
Marcus Huewe
d0213c63a9 All values in the conf.DEFAULTS dict should be strings
Non-strings cause errors during config value interpolation.

Fixes: #372 ("Commit causes crash: The 'build-jobs' config option
should be an integer")
2018-01-24 14:00:02 +01:00
Marcus Huewe
1a92c8b995 The 'build-jobs' config option should be an integer
This fixes the "config['build-jobs'] > 1" check in the build module.
2018-01-23 12:28:55 +01:00
Marcus Huewe
8cb0246c10 Merge branch 'fix_369_crash_at_req_issues' of https://github.com/lethliel/osc
Only include a tag if it "has" text in get_request_issues. Note
that the code in get_formatted_issues always assumes the presence
of the "label" tag.

Fixes: #369 ("crash trying to view diff of a request")
2018-01-22 14:46:21 +01:00
Marco Strigl
5b3d8633fa only assign issue detail if text for tag exists 2018-01-22 11:00:40 +01:00
Marco Strigl
2405134cbf fixes not working osc maintainer <prj>
The retrun at this point breaks the call, because in most
cases <prj> is not a binary. And the code always checks for the
binary first and then returns if no binary with the name <prj>
is found.
2018-01-11 11:57:22 +01:00
Marcus Huewe
0b241a9586 Consider "recommends" and "supplements" in build.create_deps
Fixes: #363 ("osc build -p ../rpms/tw doesnt send recommends to
the server which makes client side build behave differently to server
side build").
2017-12-26 23:28:14 +01:00
Marcus Huewe
ebb2f2ee0d Add support for querying weak dependencies
The following abstract methods are added to the PackageQueryResult
class: recommends(), suggests(), supplements(), and enhances().
Note that not all package/metadata formats have a notion of these
weak dependencies.

              rpm   rpmmd   deb   arch
recommends     x      x      x
suggests       x      x      x     x
supplements    x      x
enhances       x      x      x

(where "x" represents "supported"). In case of an unsupported weak
dependency, the implementation returns an empty list.

We need the weak dependency support in order to fix #363 ("osc build
-p ../rpms/tw doesnt send recommends to the server which makes client
side build behave differently to server side build").
2017-12-26 23:14:47 +01:00
ChrisWi
26f00c6749 change WARNING message for better understanding 2017-12-14 12:11:25 +01:00
lethliel
43be8f0e9c add meaningful error if no attribute name 2017-12-08 13:20:24 +01:00
Marcus Huewe
b1d6d8347b Fix "osc buildinfo --prefer-pkgs <dir>..." (finally!)
This is a follow-up commit for commit ce9a6d0 ("Fixed
\"osc buildinfo --prefer-pkgs...\"").
2017-12-06 18:04:30 +01:00
lethliel
aa01b1c52a reopen 0.163 development 2017-12-06 10:22:15 +01:00
lethliel
067fd4cd2d release 0.162.1 2017-12-05 14:29:03 +01:00
Marcus Huewe
9116d8ff97 Support expansion/unexpansion of a link when updating to certain rev
There is no good reason why "--revision <rev>" and "--expand-link" or
"--revision <rev>" and "--unexpand-link" should be mutually exclusive
during an "osc up" of a package wc.
Introduce the new "--linkrev <rev>" option to specify a rev of the link
target that is used during link expansion.
2017-12-03 16:45:36 +01:00
Marcus Huewe
f698103977 Send sha256 hashes for tracked files if the wc is pulled/linkrepair
In case of a pulled/linkrepair wc, it is possible that the backend
requests a hash for a tracked file, which is neither added, restored,
nor modified. For instance, this can happen if a new file was added
to the link target. Hence, for a pulled/linkrepair wc always send
the sha256 hashes of the tracked files.
2017-12-03 15:02:22 +01:00
e818989d21 0.163 development open 2017-11-28 15:13:26 +01:00
2b0f015de0 0.162.0 2017-11-28 15:12:29 +01:00
lethliel
f0325eb0b5 added code to get the sha256 hashes of files
This is needed for a new validation of the source server.

The source server will 'ask' for the sha256 sum of files which are new or
modified and osc calculates the sha256 sums for those files and sends them
back to the server.

The server checks the sha256 sums and if dies if something is wrong.
2017-11-27 16:18:19 +01:00
Marcus Huewe
03c25eb8f9 Merge branch 'return_external_2.6_compat' of https://github.com/lethliel/osc
Workaround for python26 due to missing subprocess.check_output.

Fixes: #355 ("subprocess.check_output() not in Python 2.6")
2017-11-21 14:25:55 +01:00
lethliel
7581856d9b added compat code for python 2.6
if subprocess has no method check_output us Popen instead
2017-11-21 14:06:31 +01:00
Marcus Huewe
5791d1bb5c Merge branch 'mount_sysfs' of https://github.com/lethliel/osc
Mount sysfs during "osc chroot". The current implementation
of "osc chroot" is a major pain for plain "su" users, because the
root password has to be entered several times - we should fix this.

Fixes: #354 ("Mount sysfs in chroot")
2017-11-21 12:34:15 +01:00
lethliel
00b6a9fe27 in chroot also mount /sys in addition to proc 2017-11-21 10:52:40 +01:00
Marcus Huewe
0f9ab38948 Merge branch 'fix_#351' of https://github.com/lethliel/osc
Fix logic for finding disabled repos in do_repositories.

Fixes: #351 ("Not all options for osc getbinaries is listed")
2017-11-09 11:56:36 +01:00
marco
12b17cfc5d consider arch when checking the disabled repos
At the moment just repo.name is considered. So if
the repo is disabled for s390 all other repo / arch
combination are not shown in the repo list.

To be able to change this r is now a list of dicts
containing the name and arch of the disabled repo.

None for repo if a complete arch gets disabled
None for arch if a complete repo gets disabled
2017-11-08 14:02:20 +01:00
Marcus Huewe
cb376a1a34 Merge branch 'config_replace_issue_313' of https://github.com/lethliel/osc
Store a newly created config file in $XDG_CONFIG_HOME/osc/. For backward
compatibility, ~/.oscrc is used, if present.

Fixes: #313 ("oscrc should be stored in $XDG_CONFIG_HOME on linux")
2017-11-08 12:23:07 +01:00
marco
6bc2d3f939 use XDG_CONFIG_HOME/osc/oscrc as default config
write oscrc to the default location for user-specific configuration.
If XDG_CONFIG_HOME is not set use ~/.config/osc/oscrc which is basically the same.

If there is already a ~/.oscrc use this one (for compat reasons). Existing user
installations should not get affected by this commit.

The order is the following:

Given config with -c
config defined in OSC_CONFIG
existing ~/.oscrc
default XDG_CONFIG_HOME/osc/oscrc
2017-11-08 11:17:11 +01:00
Alexander Bergmann
690dbf42ab Small documentation fix to clarify attribute usage. 2017-11-08 10:55:38 +01:00
Marcus Huewe
9d4390eed9 Close file before returning from core.dgst
The old f.close() call was never reached.
2017-11-07 17:52:34 +01:00
Marcus Huewe
3c1bb1cf0a Merge branch 'xz-support' of https://github.com/suihkulokki/osc
Support an xz compressed control.tar file. In case of a control.tar.xz and
a missing lzma module, an exception is thrown at runtime (for now, in order
to avoid a hard depedency to the lzma module, which is no standard module).
2017-10-30 22:24:00 +01:00
Riku Voipio
9166a7f075 debquery: support control.tar.xz
Similar to recent fixes in libsolv and obs-build. Since tarfile
on python2 doesn't do lzma, decompress the file into memory and
feed it as a fake file via StringIO to tarfile
2017-10-30 14:10:54 +02:00
marco
b52edb6513 Open 0.162 development 2017-10-26 14:47:40 +02:00
marco
fbcda8ae6e prepare 0.161.1 release 2017-10-26 14:21:33 +02:00
Marcus Huewe
a884b58313 Fix python 2.6 SyntaxError
Multiple context expressions are only supported since version 2.7.
It was introduced in commit f6f879d ("Fix potential shell injection
when running rpm2cpio").
2017-10-26 14:16:58 +02:00
marco
b7d3ae992c Open 0.162 development 2017-10-26 13:51:51 +02:00
marco
72f9f89e85 prepare 0.161 release 2017-10-26 13:33:06 +02:00
Marcus Huewe
06d0693f64 Merge branch 'show_issues_in_diff' of https://github.com/lethliel/osc
When showing a diff in the interactive review mode, also show the issues
that are associated with the request.
2017-10-20 17:39:27 +02:00
marco
895f168b91 show issues (bugs) in interactive review diff 2017-10-20 12:59:47 +02:00
marco
3a5bd607f8 fixes broken osc results on project level 2017-10-18 15:17:56 +02:00
Marcus Huewe
760a3e5558 Merge branch 'show_overview_in_diff' of https://github.com/lethliel/osc
Show request details, when displaying a diff in the interactive
review mode.
2017-10-11 13:30:48 +02:00
marco
4f518b5e59 prepend request summary to diff in interactive mode 2017-10-11 08:55:55 +02:00
Marcus Huewe
0eecdaf830 Add missing comment
Follow-up commit for f6f879d.
2017-10-10 16:36:58 +02:00
Marcus Huewe
f6f879dac5 Fix potential shell injection when running rpm2cpio
Actually, there is nothing that can be injected, except the "-h"
option. However, in case rpm2cpio evolves, we are on the safe side.
Also, document the potential shell injection in the cpio call
(the comment was accidentally removed in commit dbdc712) (the
current osc code is not affected, because we never pass filenames
via *files to core.unpack_srcrpm).
2017-10-10 16:24:42 +02:00
Marcus Huewe
a5c7611aee Support unusual filenames in "osc add <directory>"
This way, we can also support directories/files that contain
a newline "\n" etc.
2017-10-10 16:18:45 +02:00
Marcus Huewe
c3ba1fbf63 Eventually fix potential shell injections for find
It seems that the "find" binary has no way to indicate an
end of options for its arguments. Hence, we use os.walk to mimic
"find"'s behavior, which is also the cleaner solution.

Fixes: #340 ("osc add of directories does not quote the argument")
2017-10-10 16:18:39 +02:00
Marcus Huewe
d66ccb2a7d Cleanup babysitter a bit
In case of an exception, return status code 1 by default.
2017-10-06 13:25:25 +02:00
Marcus Huewe
6acc90d438 Exit with status 1 in case of a ServiceRuntimeError
Fixes: #344 ("'osc ci' exit code doesn't take source service results
       into account")
2017-10-06 13:19:15 +02:00
Marcus Huewe
760d4d65d7 Supersede existing requests if --yes is passed to "osc sr"
This basically reverts commit b2b59ca, because the old code performed
a "no" instead of a "yes" (see also the discussion in
https://github.com/openSUSE/osc/pull/269).

Fixes: #343 ("'osc sr --yes ...' doesn't supersede existing requests
       as promised")
2017-10-06 12:32:52 +02:00
Marcus Huewe
aea395a7e7 Document 'R' (replaced) file state
Fixes: #336 ("Missing explanation for status 'R'")
2017-10-03 22:05:41 +02:00
Marcus Huewe
f52cf7745a Take --repo/--arch options in "osc prjresults --xml..." into account
Fixes: #341 ("prjresults doesn't support repo/arch options")
2017-09-28 15:55:11 +02:00
Marcus Huewe
8a81a68028 Cleanup url construction in core.show_results_meta
The old code was flawed, because, for instance,
core.show_results_meta(apiurl, project, arch=['x86_64']) resulted
in a wrong http request: GET <apiurl>/build/<project>/_result&arch=x86_64
(note the "&" instead of the correct "?"). The drawback of the new
implementation is that we have to do the proper quoting manually.
2017-09-28 15:52:25 +02:00
Marcus Huewe
2d327df4e7 Allow multiple --repo and --arch options in "osc prjresults"
This harmonizes "osc prjresults --help" with osc's actual behavior.
Also, core.get_prj_results expects lists (or None) instead of strings
for the corresponding repo/arch parameters.
2017-09-28 15:29:48 +02:00
Marcus Huewe
dbdc712018 Really fix potential shell injections
This is a follow-up commit for commit c9c0f8a. Using core.run_external
with shell=True is too error-prone.

Fixes: #340 ("osc add of directories does not quote the argument")
2017-09-28 14:48:30 +02:00
Marcus Huewe
63c2aa3630 Do not run diff3 in the shell
This fixes a potential shell injection.

See also: #340 ("osc add of directories does not quote the argument")
2017-09-28 12:03:53 +02:00
Marcus Huewe
c9c0f8a731 Fix potential shell injections
Also, document a potential shell injection in core.unpack_srcrpm
(via the "files" parameter), which cannot be exploited, because
"files" is not used by the current osc code.

Fixes: #340 ("osc add of directories does not quote the argument")
2017-09-28 00:09:42 +02:00
Marcus Huewe
08504a1509 Merge branch 'lintlog_in_interactive_review' of https://github.com/lethliel/osc
Add support for showing rpmlint logs during interactive review.
2017-09-26 23:47:38 +02:00
marco
b59d40c57c show lintlog (li) in interactive mode 2017-09-26 20:20:02 +02:00
Marcus Huewe
3389db2c8f Merge branch 'repotype-pacsuffix-hint' of https://github.com/Conan-Kudo/osc
Use the buildconfig's binarytype to determine the correct pacsuffix
(TODO: cleanup Buildinfo pacsuffix code a bit).
2017-09-26 14:06:29 +02:00
Neal Gompa
ef9b308d50 Add pacsuffix hint using BinaryType from build config 2017-09-26 07:57:59 -04:00
Marcus Huewe
c2922e8a67 Open 0.161 development 2017-09-26 12:45:48 +02:00
73e8e3e97b prepare 0.160.0 release
mainly needed for new container support
2017-09-22 09:06:18 +02:00
Andrew Shadura
ca8fe4273a
Allow whitespace before ${cmd_name}. 2017-09-02 13:30:37 +02:00
Marcus Huewe
b07ba53ad0 Allow slash separated arguments in "osc rpmlintlog" 2017-09-01 10:51:28 +02:00
Marcus Huewe
38af00d509 Merge branch 'rpmlint' of https://github.com/lethliel/osc
Add new "osc rpmlint" command to retrieve the rpmlint.log file (if
present).
2017-09-01 10:49:16 +02:00
marco
99309db315 show rpmlint.log
Provide function to show the content of rpmlint.log.
The core function get_rpmlint_log will later be used in the interactive
request mode to provide the rpmlint logs to the reviewer.

I add the osc rpmlint | rpmlintlog | lint command also.
2017-09-01 10:27:05 +02:00
Marcus Huewe
c2a4d14c42 Merge branch 'patch-2' of https://github.com/jnweiger/osc
Fix UnboundLocalError in do_submitrequest.
2017-09-01 09:45:35 +02:00
Jürgen Weigert
2e6c838d66 submitreq entire project fix
`osc submitreq TARGETPROJ`
bails out with unbound variable t. This is true. the variable should be target_project.
2017-08-31 14:58:22 +02:00
3a41ae64f0
osc tr: show the time when the event happened 2017-08-31 13:57:21 +02:00
Marcus Huewe
e0bce5652a Merge branch 'show_comments_in_reviews' of https://github.com/lethliel/osc
Show the comments of a request during interactive review.
2017-08-25 13:23:17 +02:00
marco
7804a8c577 show user comments in interactive mode 2017-08-25 11:51:55 +02:00
Marcus Huewe
28368ecd4a Document possible action types for "osc rq --type <TYPE>"
The "group" action type is omitted on purpose, because it is not/was
never supported.
2017-08-24 12:14:25 +02:00
Marcus Huewe
1c21c67659 Do not ignore --type parameter in "osc review list --type..."
There is no reason why we should ignore the --type parameter in this
case.
2017-08-24 12:01:56 +02:00
marco
10e6619250 renamed get_group to get_group_meta. 2017-08-21 10:37:07 +02:00
Marcus Huewe
8746ea7ee3 Merge branch 'meta_group' of https://github.com/lethliel/osc
Add "group" subcommand to "osc meta".
2017-08-18 15:42:27 +02:00
marco
a261c73cce add meta group function to edit / show group meta 2017-08-18 15:32:27 +02:00
Marcus Huewe
902b48fd86 Add withfullhistory parameter to core.get_request_list
If withfullhistory is set to True (default: False), the returned
request collection contains full history information.

Requested by vpereira
2017-08-17 16:48:02 +02:00
Marcus Huewe
d401eb2c69 Add queries keyword argument to core.search
queries is a dict of optional http query parameters, which are passed
to the makeurl call.
2017-08-17 16:47:05 +02:00
Marcus Huewe
1524214060 Merge branch 'add_package_filter' of https://github.com/lethliel/osc
Add --target-package-filter option to do_request.
2017-08-17 10:34:41 +02:00
marco
af8b1e77f7 add --target-package-filter option to osc review
This will filter the requests you get to review based on
the tgt_package in the action element (if not action type is 'group').

This helps reviewers who want to just review a subset of requests or
do _not_ want to review some packages.

Examples:

osc review list --interactive --target-package-filter='^python.*' -G opensuse-review-team
osc review list --interactive --target-package-filter='^(?!ghc).*' -G opensuse-review-team
2017-08-17 10:14:02 +02:00
Bernhard M. Wiedemann
3dcd359eeb Check digest of modified files
this reverts a semantic change introduced by commit
48a35fed91
that caused files with updated timestamps to always be in "M" state.
2017-08-17 04:32:08 +00:00
Marcus Huewe
d126d07787 Fix typo in docstr of do_triggerreason
The command is called "triggerreason" instead of "reason".
2017-08-15 16:39:32 +02:00
Marcus Huewe
a170e1236b Merge branch 'fix_#314' of https://github.com/lethliel/osc
Add "--multibuild-package" option to do_triggerreason
2017-08-15 16:38:45 +02:00
marco
ad6b9cfd0a added -M switch to osc triggerreason 2017-08-15 15:18:41 +02:00
Marcus Huewe
48a35fed91 Add config option for the Package.status mtime heuristic
By default, the "status_mtime_heuristic" config option is disabled.
2017-08-15 13:31:10 +02:00
Bernhard M. Wiedemann
47834b3279 allow to get old status behaviour back 2017-08-12 22:10:41 +02:00
Bernhard M. Wiedemann
f1f6e9501d speedup osc status
by using mtime metadata
before checking digests.
This slightly changes the semantic by assuming that modified files
will always have updated timestamps.

With this change it is possible to do osc status
on a checkout of openSUSE:Factory that contains 40GB of source tarballs
in seconds instead of minutes:
time .../osc/osc-wrapper.py status > /dev/null

real    0m33.652s
user    0m32.590s
sys     0m1.060s

Without the patch it took 22x as long:
real    12m14.545s
user    1m50.084s
sys     0m20.566s
2017-08-12 22:07:25 +02:00
Bernhard M. Wiedemann
461d83d722 cleanup status code
to only call os.path.join once
2017-08-12 22:07:25 +02:00
Marcus Huewe
d34e0ace77 Also consider the project name in findpacs
Otherwise, we could merge two packages that belong to different projects.
Actually, we should also check the apiurls...
2017-08-04 14:51:34 +02:00
Marcus Huewe
853ab4f758 Fix computation of files dict in Osc._commit
The old implementation was unable to commit specific files from
packages, which have the same name, but belong to different projects.
2017-08-04 14:48:01 +02:00
Marcus Huewe
194d179e66 CLI part for committing a deleted, but non-existent package
That is, a package which has state 'D', but its package working
copy does not exist anymore.
2017-08-04 14:19:22 +02:00
Marcus Huewe
8f68626735 Support the commit of a deleted, but non-existent package
That is, a package which has state 'D', but its package working
copy does not exist anymore.
2017-08-04 14:02:56 +02:00
Marcus Huewe
8ce386c76a Remove all untracked files during "osc clean"
Now we also take files into account that match the "exclude_glob"
config option. The new behavior is consistent with the command's
description.
2017-08-03 17:21:20 +02:00
Marcus Huewe
2c353a5696 Merge branch 'set_build_files_for_fissile' of https://github.com/jimmykarily/osc
Print built artifacts for a fissile build.
2017-08-02 12:23:49 +02:00
Michael Schroeder
c3e0bbccb2 Container support: use multiple container extensions when checking the cache
The container may end in .tar.xz, .tar.gz, or .tar
2017-08-02 11:02:14 +02:00
Tim Hardeck
a8cc111851 Set build files for fissile 2017-08-01 15:01:53 +02:00
Marcus Huewe
c2fc655557 Merge branch 'fix_chroot_procfs' of https://github.com/lethliel/osc
Mount proc during "osc chroot". Eventually, we should implement
"osc chroot" via the obs-build script.
2017-07-31 16:28:52 +02:00
Marco Strigl
5726c66335 implented signal handler to umount proc 2017-07-31 14:41:45 +02:00
Dimitris Karakasilis
b6c064cf40 Fix typos "fissile.ymp" -> "fissile.yml" 2017-07-25 16:06:04 +03:00
Michael Schroeder
e6d492ee38 Support 'fissile' build type 2017-07-21 10:58:52 +02:00
49e8d10594 open development for 0.160 2017-07-19 00:50:31 +02:00
4f524b4d43 prepare 0.159 release 2017-07-19 00:48:15 +02:00
af5a38f4c8 Add compatibility with Debian's obs-build
In Debian and Ubuntu build is renamed to obs-build for disambiguation
purposes.
Add a simple check to use the correct paths if running on Debian and
use /usr/bin/obs-build and /usr/lib/obs-build if so.
2017-07-07 17:47:43 +01:00
Michael Schroeder
9ed700e930 Fix --set-container-derived-from option passing
We now use dir:// as with the repos. Also pass the option with
the "--option=value" form.
2017-07-03 13:34:35 +02:00
Ludwig Nussel
c941a02c73 Allow requesting maintainership for group and project
Useful e.g. for factory-maintainers
2017-07-02 15:59:45 +02:00
Marcus Huewe
c9dfe03a46 Use the correct path in core.createPackageDir
The old implementation only worked, if cwd was a project working
copy (even in this case, it may did the wrong thing...).
2017-06-29 14:20:58 +02:00
Marcus Huewe
ffe68fd9f4 Check whether project_dir points to a project wc (in do_importsrcpkg)
If we abort early, the user gets a more meaningful error message.

Fixes: #301 ("Inconsistent working copy")
2017-06-29 14:11:27 +02:00
a8612f4ecc Allow to cat/less files from deleted packages 2017-06-24 14:25:05 +02:00
Bernhard M. Wiedemann
a472fcb522 Allow to override man-page date
to enable reproducible builds of osc packages
2017-06-17 17:40:42 +02:00
Marco Strigl
fcef29131c pass --buildflavor to build script 2017-05-31 07:00:46 +02:00
Marcus Huewe
5d480fd370 Merge branch 'rdiff_issues_only' of https://github.com/lethliel/osc
Add --issues-only option to the rdiff command.
2017-05-28 19:23:34 +02:00
Marcus Huewe
23a6b4cfe9 Remove superfluous "pass" statements in edit_text 2017-05-28 19:01:50 +02:00
Marcus Huewe
9614cea39b Merge branch 'fix_#175' of https://github.com/lethliel/osc
Only accept valid user inputs.
2017-05-28 18:58:15 +02:00
67d1b50461 "osc buildhistory": show build duration 2017-05-22 12:42:51 +02:00
Marco Strigl
c19fb0e057 fixes issue #175 / invalid input at prompt 2017-05-18 11:13:44 +02:00
Marcus Huewe
e809cc8ef1 Merge branch 'fixparam' of https://github.com/bmwiedemann/osc
Fixes metvars in some help texts.
2017-05-17 23:43:14 +02:00
Marcus Huewe
900ee88bfa Fix "osc results --xml..."
For now, "osc results --xml..." ignores the "--show-excluded" option
(that's what we did in the past).

Fixes: PR#297 ("results --xml causes a stack trace")
2017-05-17 23:35:07 +02:00
Michael Schroeder
2b7cef3b33 Prepare for md5sum checking of containers
We do not want to use an old container if a new version is built
on the server. They don't have a rebuild count or something like
that (yet).
2017-05-17 11:20:03 +02:00
Michael Schroeder
7dae421d77 Support derived images for kiwi docker builds
Kiwi currently rejects the --set-container-derived-from option,
but this will hopefully change.
2017-05-16 14:02:37 +02:00
Michael Schroeder
8bffeb70e5 Support docker builds 2017-05-16 11:14:52 +02:00
Marco Strigl
fa5c97971e added switch to show only issues in rdiff 2017-05-11 09:22:42 +02:00
Marco Strigl
bea940c02d open 0.159 development 2017-05-10 16:50:23 +02:00
Marcus Huewe
7d3f8cd255 Only serialize "creator" attribute if it is neither None nor the empty string
Follow-up fix for commit eed18c6. Storing an empty creator attribute may lead
to validation errors etc. (see also PR#295).
2017-05-08 21:41:29 +02:00
Marco Strigl
320ff1bd41 release 0.158 2017-05-08 13:30:48 +02:00
Marcus Huewe
eed18c6a2e Initialize Request.creator with the empty string instead of None
Old obs versions have no creator attribute. In this case, string
formatting operations will fail if the "creator" attribute is
initialized with None (affects some codepaths).
An alternative would be to officially resurrect the deprecated
"Request.get_creator" method, which could return something like
"unknown" if no creator information is present.

This is a follow-up fix for the commits d68507f and 7d54b5c.
2017-05-04 20:49:35 +02:00
Marcus Huewe
d5393481cb Merge branch 'buildopt' of https://github.com/bmwiedemann/osc
Adds a "--build-opt" option to "osc build" in order to pass
arbitrary options to the build script.
2017-04-26 00:24:48 +02:00
efbd032da9 fix wipebinaries
don't do a second wipe all after doing the intended wipe by a filter.

Eg: osc wipebinaries home:adrianSuSE -r standard -a i586 --build-disabled

wiped first --build-disabled only, but did a second wipe all afterwards
2017-04-24 16:35:15 +02:00
Bernhard M. Wiedemann
f4771ce67a allow to pass any option to the build command
so that we do not have to patch osc for every parameter added to build
e.g. "--vm-custom-opt" in my case

similar in nature to gcc'c -Wl, option
2017-04-19 15:33:08 +02:00
Bernhard M. Wiedemann
eb25d6dfce use proper placeholder strings in help text 2017-04-19 15:27:23 +02:00
7d54b5c685 Fixing request handling for OBS < 2.8
request creator is only delivered by OBS 2.8 and newer. Makeing this not a hard
condition therefor. (introduced in d68507fa95)

Also fixes test suite failure
2017-04-18 09:41:44 +02:00
a059629e74 Fix inconsistency of request/review list -U vs -G
"osc review/request list" using -G did added the local project as target
project filter unlike -U. (If local work dir is a check out)
2017-04-18 09:12:48 +02:00
Marcus Huewe
c96928ce9a Avoid (useless) info message during interactive review
It is perfectly fine, if a request has no src actions (the
wording of the old message could be interpreted as an error...).
2017-04-12 17:16:09 +02:00
Marcus Huewe
164435dcb9 Readd Request.get_creator method (for backward compatibility)
Request.get_creator is used by some factory bots (see comment
in issue #286).

Note: Request.get_creator is deprecated and the "creator" attribute
should be used instead.
2017-04-12 14:24:04 +02:00
Marcus Huewe
20e7a132ab Cosmetic: use "... is not None" instead of "not ... is None" 2017-04-12 13:03:16 +02:00
Marcus Huewe
d68507fa95 Drop Request.get_creator method in favor of a new "creator" attribute
This implements the Request api change that was proposed in commit
6965dc5 ("Adjust request testcases to the upcoming Request api
change").

Fixes: #286 ("get_creator() does not return request creator")
2017-04-12 12:58:23 +02:00
Marcus Huewe
a271a33a53 Merge branch 'fix_issue_#236' of https://github.com/lethliel/osc
Fixes --no-cleanup in combination with --separate-requests
2017-04-11 12:41:24 +02:00
Marco Strigl
2e76f91980 fixes issue #236 2017-04-11 11:38:47 +02:00
Marco Strigl
055f577c6b filter excluded repos for package by default 2017-04-07 11:13:20 +02:00
Marcus Huewe
b0b4cb9ed8 Merge branch 'comment_interactive_req' of https://github.com/lethliel/osc
Add support for creating comments during interactive review.
2017-04-07 09:36:04 +02:00
Marco Strigl
6a6a5686df requests can now be commented in interactive mode 2017-04-07 09:09:33 +02:00
0d941e8766 show package status when repository configuration is broken
it was just dropped before due to lack of status element for the package
2017-04-07 08:50:57 +02:00
Marcus Huewe
3397acc756 Try to autodetect a local package when running "osc build"
Note that this detection might fail... in the this case osc will
eventually error out and suggest to rerun with "--local-package".
2017-03-31 15:51:08 +02:00
Marcus Huewe
7a4f7b0b9d Fix typo in "service runall" docs and list the "service runall" command 2017-03-31 10:34:52 +02:00
Marcus Huewe
ae591a82fc Document deprecated "service disabledrun" and "service localrun" commands
Fixes: #282 ("service disabledrun is not documented")
2017-03-31 10:32:55 +02:00
Marco Strigl
678c79224c added --blame switch to osc meta command 2017-03-22 08:32:05 +01:00
Marco Strigl
30b5af2d86 open 0.158 development 2017-03-21 14:31:06 +01:00
Marco Strigl
3df1724235 release 0.157.2 2017-03-21 13:33:10 +01:00
Marcus Huewe
45e27c01af Correctly update a conflict file ('C') that is going to be deleted
Deleting a conflict file (state 'C') during an update operation results
in an inconsistent working copy. To fix this, we remove the conflict
file from the _in_conflict list.
2017-03-20 19:20:59 +01:00
340a72ee83 never take releasename blindly (eg. on linkpac). It needs to be set
explicit
2017-03-20 16:05:39 +01:00
3ab3ff0b1c list appimage build results 2017-03-15 10:32:11 +01:00
Marcus Huewe
8bb903f41c Make error handling in attribute_branch_pkg more robust 2017-03-14 22:50:48 +01:00
3e2bb0ec1d add support for highly experimental native appimage.yml support 2017-03-14 19:02:01 +01:00
6b91b282b8 cat/less/blame command: default to expand to stay in sync with checkout
this allows us also to drop the nasty fallback code
2017-03-14 19:02:01 +01:00
Ludwig Nussel
8f175484f7 Add plugin directory to search path
Some osc plugins ship with extra modules that are not globally installed
as python modules. So expand search path.
2017-03-14 13:39:04 +01:00
Marcus Huewe
9d0725b2d4 Fix local service run for non-existent (server-side) package
If a package does not exist on the server, the
Serviceinfo.getProjectGlobalServices call results in a 404. In this
case, we try it again with the _project package (note: this does not
take potential "linked" services into account, if the local package
is a _link).

Fixes: #277 ("404 on running service for non commited package")
2017-03-10 11:08:31 +01:00
Marco Strigl
e94c9cc280 multibuild compatibility mode for old apis 2017-03-09 14:55:30 +01:00
Marcus Huewe
ff19a5f539 Fix SSL.Connection instantiation in case of an old M2Crypto
Do not pass a family parameter to SSL.Connection's constructor if it
does not support it. If the family parameter is not supported, we
_try_ to fallback to socket.AF_INET, which is implicitly used by
older versions of the SSL.Connection class.

Fixes: #274 ("osc 0.157 Exception AttributeError: "Connection
instance has no attribute 'ssl_close_flag'"")
2017-03-09 13:34:17 +01:00
Marco Strigl
8f6e292637 reopen 0.158 development 2017-03-09 10:51:35 +01:00
Marco Strigl
ba9b3d8dab release 0.157.1 2017-03-08 13:10:35 +01:00
670bd90e29 fix local build of kiwi images using obsrepositories:// (affects newer python3-kiwi) 2017-03-08 13:01:08 +01:00
Marco Strigl
1cde520db5 open 0.158 development 2017-03-08 10:17:25 +01:00
Marco Strigl
7f428cccdf release 0.157.0 2017-03-08 09:25:02 +01:00
ccafb430b8 support operation in checked out package for cat/less/blame 2017-03-07 15:07:44 +01:00
Marcus Huewe
0d79510fa0 Merge branch 'comment_command_integration' of https://github.com/lethliel/osc
New "comment" command.
2017-03-07 13:32:19 +01:00
Marco Strigl
68f10bdb14 integrated comments command 2017-03-07 08:42:21 +01:00
Felix Zhang
f8e61cfd28 Add missing whitespaces in commandline options 2017-03-07 10:30:30 +08:00
008a6009f8 add blame command 2017-03-02 16:05:48 +01:00
Marcus Huewe
e324a36b41 Merge branch 'token_syntax_verify' of https://github.com/lethliel/osc
Bail in some cases if wrong args were supplied
2017-03-02 10:37:58 +01:00
Marco Strigl
d49c741b0d added syntax check if no token opt is set 2017-03-02 09:02:19 +01:00
cf656e30d7 getbinaries: make .AppImage files executable
shouldn't be a security issue, since they are always in subdirectories
2017-02-27 09:45:37 +01:00
Oliver Kurz
7f985cf874 Fix outdated doc URL to maintenance setup 2017-02-23 16:02:09 +01:00
Marcus Huewe
8c82243ad5 Merge branch 'fix-sr-yes' of https://github.com/srinidhibs/osc
Add missing check for opts.yes to do_submitrequest.
2017-02-22 20:02:16 +01:00
Marcus Huewe
74e397b12c Merge branch 'multibuild' of https://github.com/lethliel/osc
Adds a "--multibuild-package" option to the following commands:
buildlog, remotebuildlog, buildinfo, build, buildhistory, jobhistory,
rebuild, restartbuild/abortbuild, wipebinaries, getbinaries
2017-02-20 19:47:19 +01:00
B S Srinidhi
b2b59ca929 - Fix handling of "--yes" argument to "osc sr" 2017-02-20 14:01:55 +05:30
Marco Strigl
2969c9c52e added multibuild switch (-M) to commands 2017-02-17 11:53:14 +01:00
Marcus Huewe
8efcb0b14d Fix ret code in do_list in case of a non-existent file 2017-02-13 21:45:16 +01:00
Peter Simons
d86e960e30 Lex the contents of $PAGER to support pager commands with arguments.
Closes https://github.com/openSUSE/osc/issues/264.
2017-02-11 20:21:02 +01:00
Marco Strigl
8cf89fa122 fixes osc checkout error with checkout_rooted=1
see bsc#1012592
2017-02-08 13:55:36 +01:00
Marcus Huewe
025ececfdc Merge branch 'recipe_type_guessing' of https://github.com/lethliel/osc 2017-02-02 12:52:49 +01:00
Marco Strigl
b16f1c9c90 improved build recipe guessing 2017-02-02 12:25:43 +01:00
Marcus Huewe
b0d905aa38 Print error for a failed service run in do_submitrequest
Additionally, we do not treat a "running" service run as an
error (the api will complain, if it is still running).
2017-01-31 23:35:43 +01:00
Marcus Huewe
3b3bb21645 Fix IPv6 support in myHTTPSConnection.connect
So far, the AF_INET family was implicitly used. Now, we try all families,
which are returned by socket.getaddrinfo.

Fixes: #261
2017-01-29 22:43:42 +01:00
Marco Strigl
24d70c03dd quote the proj and pkg on checkout url 2017-01-19 14:53:28 +01:00
Marcus Huewe
41187aa705 Merge branch 'fix_urlgraberror_handling' of https://github.com/OlegGirko/osc 2017-01-18 18:18:15 +01:00
Oleg Girko
361fec753a Fix URLGrabError exception handling.
URLGrabError class has no exception attribute,
use strerror to print error instead.

Signed-off-by: Oleg Girko <oleg.girko@jolla.com>
2017-01-17 23:27:08 +00:00
885dd3fecd show build results of multibuild packages by default
Be in sync with webui. Also it is assumed that a user wants to see
all build results of the source change he did and not only for a subset.
2017-01-17 17:16:00 +01:00
943a53d4d8 add unpublish command 2017-01-16 11:58:02 +01:00
Marcus Huewe
4c39b63162 Fix "osc results --csv ..."
Follow-up fix for commit 665d2bda72.
Fixes https://github.com/openSUSE/open-build-service/issues/2548
2017-01-12 15:33:26 +01:00
Marco Strigl
4893049312 added commands for constraints/worker checking 2016-12-30 14:10:35 +01:00
9fffefb2d2 - open 0.157 development 2016-12-20 08:29:01 +01:00
Marco Strigl
78b404158e release 0.156.0 2016-12-19 14:47:45 +01:00
Andreas Schwab
c5a7d266fb Respect repository and arch arguments in restartbuild 2016-12-18 16:04:34 +01:00
Marcus Huewe
1c03e32a57 Merge branch 'add_multibuild_to_results' of https://github.com/lethliel/osc 2016-12-13 16:49:56 +01:00
Marco Strigl
665d2bda72 added support for multibuild / locallink feature
new option -m shows all subpackages and results of the subpackages.
2016-12-13 14:43:36 +01:00
1cb3f9eed5 Add '--vm-memory' option to osc build 2016-11-29 09:07:20 +01:00
Hemmo Nieminen
326abe0c8b Backport a fix from Python 2.7 upstream for urllib2.
This change makes basic authentication fail after first unsuccessful
attempt (instead of automatically retrying) and thus prevents unnecessary
failed login attempts.

This change also allows printing the contents of an HTTP 401 message to
the user.
2016-11-22 11:13:24 +02:00
Marcus Huewe
05ad9efae3 Avoid stale ~/.osc_cookiejar file
Always clear the cookiejar, if ~/.oscrc's mtime is "greater" than
~/.osc_cookiejar's mtime. This fixes issue #86.
2016-11-19 13:01:05 +01:00
Marcus Huewe
25ccfde43c Speed up Project.checkout_missing_pacs a bit
This is a follow-up commit for 613e7b1a95.
2016-11-18 13:00:55 +01:00
Hemmo Nieminen
613e7b1a95 Alter osc update operation's default behaviour.
Make update operation behave as checkout does and do not checkout linked
packages from the same project (by default) during a project wide update.
2016-11-16 10:12:12 +02:00
Marcus Huewe
7be66bc57a Adjust error message in do_getbinaries
This is a follow-up change for commit f7918fcc10.
2016-11-15 14:06:33 +01:00
Marcus Huewe
e4d6e06e1c Merge branch 'getbinaries-project' of https://github.com/Ericsson/osc 2016-11-15 14:05:51 +01:00
Matias Hilden
82dbd10af2 Ignore build descr directory in build-root substitution for local packages
If build-root contains %(package) substitution, --local-package builds
would substitute absolute path there. This is different than the rule used
in osc chroot (uses relative path), causing the chroot to fail by default.

This commit removes the directory part from both build-root substitutions.
2016-11-14 13:48:06 +02:00
Hemmo Nieminen
f7918fcc10 Support downloading a project's binaries from a non-checkout directory. 2016-11-11 16:17:39 +02:00
2befb71663 allow to specify a log message in lock command 2016-11-03 08:41:56 +01:00
Marcus Huewe
9800a7a706 do_wipe: replaced sys.stdout.write calls with print calls 2016-10-31 19:32:08 +01:00
Marcus Huewe
06120b3323 Merge branch 'add-wipe-subcommand' of https://github.com/Ericsson/osc 2016-10-27 18:32:34 +02:00
Matias Hilden
dd4675096a Add '--wipe' option to osc chroot for deleting buildroots
Co-Author: Juha Kallioinen <juha.kallioinen@ericsson.com>
2016-10-27 09:05:35 -07:00
290d96e0b0 add comment about extending env variables for services 2016-10-20 13:12:15 +02:00
8c3f5e9ae2 highlight scheduled jobs with dispatch problems (due to constraints) 2016-10-20 12:59:08 +02:00
Marco Strigl
e0fae072eb improved watched output of osc results
before joining the results on a osc r -w a newline is printed now
2016-10-07 10:07:23 +02:00
Marcus Huewe
6ec62da3cc Add "apiurl" attribute to the Serviceinfo class
Follow-up commit for 8c45eb64ade699ce3d8717f460b3064ca3ab3a58 (just to
make sure that the "apiurl" attribute is always part of the Serviceinfo
class...)
2016-10-04 13:22:00 +02:00
Adam Spiers
8c45eb64ad pass apiurl to source services (#234)
Some source services need to know the apiurl, e.g. to lookup values
in the ~/.oscrc config file.

Closes #234.

https://github.com/openSUSE/osc/issues/234
2016-10-01 22:50:33 +01:00
Marcus Huewe
b4d4d3c027 do_vc: don't contact the api if the "email" config option is set 2016-09-23 16:37:23 +02:00
Marcus Huewe
2816f325ca Fix logic error in do_my
A dict doesn't work here (however, this codepath shouldn't be reached at
all).
2016-09-13 12:39:24 +02:00
Marcus Huewe
e9cc000987 Fix non-existent user handling in do_my/get_user_projpkgs_request_list
This fixes the issue reported in PR #227.
2016-09-13 12:34:48 +02:00
Marcus Huewe
07e0628d9e get_package_results: added None check 2016-09-09 16:24:26 +02:00
ssedlmaier
a536ef5e64 get_package_results: check actual package status
At the moment only the project status is taken into account when determining when to stop watching a build.
This leads to wrong behavior when a package is in 'blocked' for a longer time.
In this state the project status and code is 'published' but the package remains at 'blocked'.
With this additional check this problem is fixed.
2016-09-09 14:46:28 +02:00
Marcus Huewe
bdec204600 treat code 500 as 414 in get_project_sourceinfo
Depending on, e.g., the apache2 configuration, status 500 is returned in case
of an "uri too long" error.
2016-09-09 13:34:21 +02:00
Marcus Huewe
3b1409fd33 Sigh... fix error message 2016-09-09 13:23:55 +02:00
Marcus Huewe
008c456942 Removed debug output
Introduced in commit 2953d65220.
2016-09-09 13:22:40 +02:00
Marcus Huewe
2953d65220 Hint to the --noservice option in do_commit in case of a missing service
Also, this simplifies the service related error handling in do_commit/_commit
a bit.
2016-09-09 13:20:15 +02:00
Marcus Huewe
78e0aa90f5 Fix "args" handling in class PackageNotInstalled 2016-09-09 13:14:35 +02:00
Marcus Huewe
8e7189b391 Restore support for "osc add prj/dir"
This is used to turn "dir" into a package and add it to the version
control (got broken in commit b6f7d1be6c).
Integrated the obscpio code that was introduced in commit
b6f7d1be6c into core.addFiles (XXX: we
should get rid of the run_external(..., shell=True) code).
2016-08-26 17:12:09 +02:00
Marcus Huewe
00c8876791 core.addFiles: improve usability a bit (as suggested by darix)
The previous errors are in fact just warnings.
2016-08-26 16:28:19 +02:00
Marcus Huewe
e7dc0c740a Removed bogus check in get_package_results (fixes #224)
The bogus check is twofold: the first error is due to a wrong
refactoring (repostate was intended to be the "code" attribute
and "code" was supposed to the "code" attribute of the status
node) (see commit f3a1d12a). The second error is a logic error
in the original code, because the package state "succeeded" and
the repostate "unpublished" is a valid combination. Consequently,
the check didn't make any sense...
2016-08-18 01:24:34 +02:00
Andreas Schwab
0c00108521 get_prefer_pkgs: don't ignore debuginfo packages 2016-08-17 09:44:36 +02:00
Marcus Huewe
05ab19bda7 Merge branch 'master' of https://github.com/andreas-schwab/osc
babysitter.run: decode entities in error summary
2016-08-17 01:52:07 +02:00
Marcus Huewe
b5679dee81 Introduced wrongly spelled "--seperate-requests" option again
Just for backward compatibility - will be removed in the
future. See commit b9a53e3527.
2016-08-17 01:43:19 +02:00
Jim McDonough
b9a53e3527 Fix spelling of --separate-requests 2016-08-16 11:40:34 -04:00
Andreas Schwab
9f00759e02 Support arm packages in pkg-prefer 2016-08-08 10:35:14 +02:00
Andreas Schwab
9be4295c73 - babysitter.run: decode entities in error summary 2016-08-04 12:45:30 +02:00
dd1228c872 fix reading of local package directory in release command (osc#218) 2016-08-02 14:09:18 +02:00
9a3f33d5e3 open 0.156 development 2016-07-29 16:06:53 +02:00
a2a6cc95f5 version 0.155.0 2016-07-29 16:03:59 +02:00
Marcus Huewe
83c1064cfe Merge branch 'master' of https://github.com/sleep-walker/osc 2016-07-08 15:28:44 +02:00
Marcus Huewe
58adc14dd4 Merge branch 'fix_osc_co_outdir_project' of https://github.com/Ericsson/osc 2016-07-08 11:48:52 +02:00
Bernhard M. Wiedemann
1ef4449e80 mention "key" in no-verify help text
to make it easier to find with
man osc | grep key
2016-07-05 17:11:48 +02:00
Tomáš Čech
66596c5d0a Return different return code on KeyboardInterrupt
As I haven't found any good source for choice of exit code, I took value
130 found here:

http://tldp.org/LDP/abs/html/exitcodes.html
2016-07-02 19:19:32 +02:00
f2faa82ac7 fix local package caching for snapcraft 2016-07-01 11:15:12 +02:00
Esa Kulmala
c4e4064778 fixed output dir handling for osc checkout <project> 2016-06-30 09:51:48 +03:00
b6f7d1be6c explicit "osc add" of a directory offers to create an archive for uploading it
Question: what can be a trigger to update it?
          checking for mtimes in directories where an .obscpio exists?
2016-06-30 08:19:23 +02:00
d623cb8552 add support for snapcraft builds 2016-06-30 08:06:29 +02:00
Marcus Huewe
30213d0da4 Merge branch 'fix-obsolete' of https://github.com/sebix/osc 2016-06-17 09:17:24 +02:00
Sebastian Wagner
61ddf8542e
Unify obsolete warnings for commandline
Signed-off-by: Sebastian Wagner <sebix@sebix.at>
2016-06-16 23:53:07 +02:00
Marcus Huewe
89fd90ee23 cosmetic + logic fix in get_results 2016-06-10 14:41:35 +02:00
Marcus Huewe
ca9da9df05 fixed "osc results" output in case of a missing status node
In this case, the code from the result element is used.
2016-06-10 14:40:12 +02:00
Michael Schroeder
95b6087c5b Use the preinstall filename if the hdrmd5 is not available 2016-06-09 16:40:39 +02:00
Michael Schroeder
55da852a90 Add support for preinstall iamges
Adapted from a submission from Ericsson by Esa Kulmala, thanks a lot!
2016-06-09 16:24:30 +02:00
37990f48b2 add "osc service runall"
This is up for discussion, but I try to simplify the interface here:
- obsolete "localrun" and "disabledrun". Still implemented, but not anymore
  recommended and documented. can hopefully removed later.
- "runall" is running all services local, also buildtime services
  - files get replaced by the service
  - can be used to get final tar balls to be used with tools like quilt
2016-06-08 09:17:15 +02:00
015ab4cd40 Merge pull request #208 from b1-systems/project_meta_revision_ctrl
Add revision control options to meta project commands
2016-06-08 09:10:21 +02:00
abe0ffad76 Merge pull request #207 from adrianschroeter/master
add "osc service runall"

no feedback yet, but it is not removing functionality, so let's try in real life
2016-06-08 09:10:14 +02:00
Marcus Huewe
acbd2c17c7 Revert "Simplify core.http_request"
This reverts commit c53a7681ef (for now!).
It seems to break local obs instances (see issue #202) (this needs
further debugging). Moreover, it breaks the python 3.4 - excerpt
from a travis run:

======================================================================
ERROR: test_added_missing2 (test_commit.TestCommit)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/opt/python/3.4.2/lib/python3.4/urllib/request.py", line 1111, in do_request_
    mv = memoryview(data)
TypeError: memoryview: _io.BufferedReader object does not have the buffer interface

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/travis/build/openSUSE/osc/tests/common.py", line 122, in wrapped_test_method
    test_method(*args)
  File "/home/travis/build/openSUSE/osc/tests/common.py", line 122, in wrapped_test_method
    test_method(*args)
  File "/home/travis/build/openSUSE/osc/tests/common.py", line 122, in wrapped_test_method
    test_method(*args)
  File "/home/travis/build/openSUSE/osc/tests/common.py", line 122, in wrapped_test_method
    test_method(*args)
  File "/home/travis/build/openSUSE/osc/tests/common.py", line 122, in wrapped_test_method
    test_method(*args)
  File "/home/travis/build/openSUSE/osc/tests/test_commit.py", line 290, in test_added_missing2
    p.commit()
  File "/home/travis/build/openSUSE/osc/tests/osc/core.py", line 1471, in commit
    self.put_source_file(filename, tdir)
  File "/home/travis/build/openSUSE/osc/tests/osc/core.py", line 1319, in put_source_file
    http_PUT(u, file = tfilename)
  File "/home/travis/build/openSUSE/osc/tests/osc/core.py", line 3243, in http_PUT
    def http_PUT(*args, **kwargs):    return http_request('PUT', *args, **kwargs)
  File "/home/travis/build/openSUSE/osc/tests/osc/core.py", line 3231, in http_request
    fd = urlopen(req, data=data)
  File "/opt/python/3.4.2/lib/python3.4/urllib/request.py", line 153, in urlopen
    return opener.open(url, data, timeout)
  File "/opt/python/3.4.2/lib/python3.4/urllib/request.py", line 453, in open
    req = meth(req)
  File "/opt/python/3.4.2/lib/python3.4/urllib/request.py", line 1116, in do_request_
    data))
ValueError: Content-Length should be specified for iterable data of type <class '_io.BufferedReader'> <_io.BufferedReader name='/tmp/osc_test571whun4/osctest/added_missing/.osc/_in_commit/bar'>
2016-06-02 21:59:40 +02:00
Karsten Keil
fca93a8b60 Add revision control options to meta project commands 2016-06-02 08:23:47 +02:00
28c12686b9 add "osc service runall"
This is up for discussion, but I try to simplify the interface here:
- obsolete "localrun" and "disabledrun". Still implemented, but not anymore
  recommended and documented. can hopefully removed later.
- "runall" is running all services local, also buildtime services
  - files get replaced by the service
  - can be used to get final tar balls to be used with tools like quilt
2016-06-01 17:10:31 +02:00
2364a08236 handle "_project" package always as local package 2016-05-31 09:26:28 +02:00
Marcus Huewe
c53a7681ef Simplify core.http_request
There is really no need for mmap...
2016-05-16 18:48:57 +02:00
Marcus Huewe
8466e49d59 - request_interactive_review: handle 404 during get_results more gracefully
Catch exception and just print the error instead of exiting
the interactive review.
2016-04-22 15:16:53 +02:00
Marcus Huewe
ce9a6d0f46 Fixed "osc buildinfo --prefer-pkgs..."
Was broken since ages (literally!)...
(see commit d5b795a02b).
2016-04-14 16:25:48 +02:00
564918f37a open 0.155 development 2016-04-11 10:50:10 +02:00
941e5b0289 prepare 0.154.0 release.
A small release, but brings the critical stuff to work with new git handling
of OBS 2.7
2016-04-11 10:48:05 +02:00
a3684394a1 show branch errors again 2016-04-11 10:45:40 +02:00
24290ebf95 switch to new obsinfo service 2016-04-08 09:07:38 +02:00
65201ad1bc set OSC_VERSION environment for source services
will be needed by new obs_scm service
2016-04-01 12:57:00 +02:00
Marcus Huewe
c5f56e7f6c - fixed boo#896633 2016-03-19 22:01:52 +01:00
Marcus Huewe
3298732576 - refactored Serviceinfo.read a bit 2016-03-04 10:22:21 +01:00
Marcus Huewe
b480206829 - Fix for commit d6bd44a9a4cf585d12c9d7e597dbddccea34a1c3... 2016-03-04 10:20:39 +01:00
Marcus Huewe
d6bd44a9a4 - Serviceinfo.execute: create tmpdir in the package wc
The advantage is that we can use os.rename instead of shutil.move
to move the files.
2016-03-04 09:40:58 +01:00
f6324f2aa0 open 0.154 development 2016-03-04 08:37:33 +01:00
3a0353eef1 0.153.0 release 2016-03-04 08:37:33 +01:00
aa74e98fb3 add new service commands (merge and wait) 2016-03-04 08:37:33 +01:00
Nelson Manuel Marques
72c2bd7cfd FIX https://github.com/openSUSE/open-build-service/issues/1591 2016-03-02 17:47:22 +00:00
779c7763cc add repository strategy options to branch command 2016-03-02 17:13:11 +01:00
Bernhard M. Wiedemann
bbefe024e5 add vm-user option
this needs latest obs-build to work
2016-02-18 11:31:59 +01:00
d4336dc19a - print created submit request ID before handling supersedes
So it is printed even when something goes wrong with superseding (boo#966731)
2016-02-15 15:32:26 +01:00
Marcus Huewe
6a69ecc137 - oops... unbreak copy_pac again (fixes #181)
Got broken in commit ffb37960ff.
2016-02-12 10:39:54 +01:00
Marcus Huewe
e8783d2501 - introduced new "request_show_source_buildstatus" config option
If enabled, it always shows the source buildstatus during
"osc rq show <id>" or "osc rq list --interactive". By default, it is
disabled.
2016-02-10 18:27:35 +01:00
Marcus Huewe
add34d65cb - support --source-buildstatus during interactive review 2016-02-10 18:19:22 +01:00
Marcus Huewe
75f6b3fbc1 - do_status: "cluster" package states in the output
This only affects "osc st" in a prj wc.
2016-02-10 13:54:24 +01:00
Marcus Huewe
ec6fab6793 - simplified show_upstream_xsrcmd5 a bit 2016-02-09 14:42:50 +01:00
Marcus Huewe
d646915c04 - allow to directly expand a non-link during "osc up -e" 2016-02-08 17:24:35 +01:00
Marcus Huewe
244a704033 - Package.status: handle a dangling symlink more gracefully
More precisely, treat it as unversioned.
2016-02-07 22:58:23 +01:00
Marcus Huewe
f3a1d12a96 - refactored package result code a bit (fixes #180)
Note: this commit "breaks" the existing get_package_results api, because
it returns a generator, which yields a result xml, instead of a list of
result dicts.
2016-02-07 00:55:23 +01:00
Marcus Huewe
ffb37960ff - do_copypac: rewrote client side copy code (fixes #181)
Use the "standard" commit procedure (a.k.a. cmd=commitfilelist).
Additionally, refactored the corresponding code in the Package class
a bit.
2016-02-05 17:16:42 +01:00
Marcus Huewe
51ccd6741c - use atime instead of mtime when guessing the repo arch
atime is more reasonable (e.g. in case of an offline build).
2016-02-05 16:11:11 +01:00
Marcus Huewe
5d068b091a - do_buildlog: support "osc bl repo"
In this case, "osc bl repo" behaves more or less the same as "osc rbl repo"
(in case no corresponding .osc/_buildinfo file exists, we default to
repo and hostarch).
2016-02-05 16:10:43 +01:00
Marcus Huewe
8a78be684e - removed broken "install" command from the ui
The command was hidden since 2009 (so there shouldn't be much breakages).
This also fixes #185.
2016-02-05 11:56:22 +01:00
Marcus Huewe
89ac49f659 fetch.py: reworded Fetcher.failureReport message a bit
Based on PR#182.
2016-02-05 11:28:47 +01:00
b40d856e67 add --limit option to buildhistory 2015-12-07 10:05:08 +01:00
Marcus Huewe
b15f97bcd0 - conf._build_opener: make sure no certs are checked if "sslcertck" is disabled
Since python >= 2.7.9 urllib2/httplib verifies the ssl cert by default - so
make sure that this "builtin" ssl check is disabled as well if
"sslcertck" is disabled. Fixes #179.
Note: eventually, we should abandon m2crypto and use urllib2/httplib to
verify the ssl cert.
2015-11-28 22:39:49 +01:00
25118ceccc - support --vm-telnet option for KVM builds
latest build package is required.
2015-11-25 14:20:55 +01:00
Johannes Lahti
a364a4c456 Added missing localrun help text to do_service 2015-11-12 10:37:03 +02:00
Egbert Eich
f17bef21e5 Make '-o' option work also when checking out complete projects
Signed-off-by: Egbert Eich <eich@freedesktop.org>
2015-11-10 16:43:33 +01:00
Egbert Eich
43ffb9f3ac maintenancerequest: simplify sytnax to create request for single package
The syntax to create a maintnancerequest for a single currently package
is:
  osc mr SOURCEPROJECT SOURCEPACKAGES RELEASEPROJECT
which means that the source project, the package name and the release
project have to be specified on the command line.
Often times the workflow is such that the user will already be inside
of the subdirectory containing the checked out package.
To simplify the submission when the user is in a package subdirectory
this patch adds the syntax:
  osc mr .
to indicate that the source project and source target is to be taken
from the meta information in this package directory.

Signed-off-by: Egbert Eich <eich@freedesktop.org>
2015-11-10 16:38:41 +01:00
df9c3000b0 - add --linkrev option to branch command 2015-10-23 11:08:30 +02:00
e9766d5d5b - seperate add and enable channel command for better command description
- adapt to new api mode handling
2015-10-22 09:40:09 +02:00
Marcus Huewe
dc32cde545 - do_request: also print comments when running "osc rq show <reqid>"
Fixes #171.
2015-10-19 13:14:53 +02:00
Andreas Schwab
4e83af8294 branch_pkg: fix use of undefined variable 2015-10-07 16:27:55 +02:00
Marcus Huewe
400352c61e - do_branch: do not checkout server service files if "--checkout" is specified
Otherwise one has to checkout the expanded sources without the
server service files before doing a commit.
2015-10-03 22:24:58 +02:00
Marcus Huewe
cc3979cc7f - do_maintenancerequest: fixed TypeError ("'NoneType' object is not iterable")
Broken since commit ba7e20bcd1.
2015-09-24 18:25:22 +02:00
Marcus Huewe
070daecaf5 - build.Buildinfo: improved error formatting
Use the same formatting for an "unresolvable" error as in "osc results -v"
2015-09-23 18:29:51 +02:00
4342d9a6e1 Correction of grammatical errors
"exists" is a Python keyword, and wrong outside the 3rd person
singular in English.
2015-09-16 10:17:15 +02:00
5d6882e0e1 Collax support 2015-09-10 11:35:27 +02:00
Marcus Huewe
e697a70921 - Package.__get_files: check for broken files meta
Fixes #170.
2015-09-07 19:28:56 +02:00
7bb0c4b730 fix extra parameters for manual release as wanted by api 2015-09-07 12:39:15 +02:00
0b34cb4567 - fix enable channel logic for given channel package 2015-09-04 11:10:20 +02:00
Marcus Huewe
c902d174d8 - conf.parse_apisrv_url: strip trailing slashes from the path
Since commit ca2f1a90c8 a section like
[https://api.opensuse.org/] was not associated with an
"apiurl=https://api.opensuse.org" entry anymore.
2015-08-20 14:45:02 +02:00
Ludwig Nussel
d534218421 fix exception
TypeError: can only concatenate list (not "tuple") to list
2015-08-17 17:36:45 +02:00
Oleg Girko
4d3fcd9dc1 Fix Python 3 support.
This change fixes errors when running test suite with Python 3.

Signed-off-by: Oleg Girko <ol@infoserver.lv>
2015-08-13 12:44:19 +01:00
Oleg Girko
c62c9f54a0 Add support for TLS SNI if M2Crypto supports it.
Currently osc can't access API URLs which share the same IP address
with other SSL-enabled sites, complaining about certificate
not matching hostname.

This change solves this problem by instructing M2Crypto.SSL.Connection
to send the desired hostname to https server using TLS SNI extension,
thus allowing the server to present the right certificate and choose
the right virtual site.

This is useful for those who can't afford to have a separate IP address
for OBS API.

For TLS SNI to work correctly, M2Crypto should be patched:
https://bugzilla.osafoundation.org/show_bug.cgi?id=13073
Some distributions (like Fedora) already include this patch.

For unpatched M2Crypto osc degrades to operation without TLS SNI.

Signed-off-by: Oleg Girko <ol@infoserver.lv>
2015-08-13 11:11:42 +01:00
a031dbd083 show review comments in an own line. Before they started in the same line, but reached on typical
screens anyway the second line if they had more than a few chars.
2015-08-13 08:07:34 +02:00
f9e54d0488 Merge pull request #145 from OlegGirko/api-fix-root-path
Add support for non-root paths in API URLs.
2015-08-13 07:52:35 +02:00
3b203e67a9 Merge pull request #148 from lnussel/master
allow force commit
2015-08-13 07:50:58 +02:00
7352a47930 Merge pull request #155 from arunpersaud/ET.parse_error
More meaningful error if ET.parse runs into problems. Fixes #153.
2015-08-13 07:50:08 +02:00
f788fddb6c Merge pull request #152 from jelly/xml_parse_error
When lxml fails to parse the _service file show error message instead of backtrace
2015-08-13 07:49:40 +02:00
Daniel Gollub
beb46cc012 Support prefer-pkg for live-build 2015-08-12 16:29:22 +02:00
ba7e20bcd1 - maintenance request offers to supersede old, but still open requests
bnc#940731
2015-08-07 10:17:40 +02:00
Marcus Huewe
7370950cab Merge branch 'get_group-error-messagge' of https://github.com/DimStar77/osc 2015-08-06 15:12:48 +02:00
Marcus Huewe
0442cdf5f4 - improved a comment a bit 2015-08-06 14:23:45 +02:00
Marcus Huewe
3f6eaeaff9 Merge branch 'master' of https://github.com/b1-systems/osc 2015-08-06 14:21:39 +02:00
Marcus Huewe
da40039bbc Merge branch 'master' of https://github.com/andreas-schwab/osc 2015-08-06 13:58:49 +02:00
0e32b71491 core: fix get_group error message 2015-08-06 12:52:34 +02:00
Marcus Huewe
e435a84440 - made "osc rq <prj> <pkg>" output more precise, in case of no results 2015-08-04 12:51:45 +02:00
Stefan Seyfried
0360381087 fix an "400 Bad Request" when running against old API
Updating a whole project against an old API server (experienced with
2.3.5) leads to:
	Server returned an error: HTTP Error 400: Bad Request
	unknown parameter 'nofilename'
So just retry without nofilename if an 400 is thrown.
2015-07-29 14:30:47 +02:00
f7cfe4cdc8 - fix search of requests "I" created. fixes obs#1002
This is using the request collection api call now instead of xpath query.
More searches should be adapted similar most likely.

"osc my sr" is not a good name for this since it is not limited to
submit actions. But "osc my rq" is used for incoming requests.
2015-07-29 11:05:05 +02:00
083f23f77b support new package instances on branching when using -N parameter 2015-07-21 13:03:07 +02:00
Andreas Schwab
71297e31f4 Don't use gmtime for a time difference
The gmtime function is intended to be used for calendar time.
2015-07-21 11:45:35 +02:00
Andreas Schwab
7896937f50 Remove use of %Z with gmtime
%Z doesn't make sense for a time returned by gmtime.
2015-07-21 11:45:35 +02:00
Andreas Schwab
d5b0d8fe52 print_jobhistory: Remove unused variables 2015-07-21 11:45:35 +02:00
Marcus Huewe
e9d7ac9c82 - do_addchannels: handle wrong args more gracefully 2015-07-15 20:46:38 +02:00
Marcus Huewe
0daec6a5f1 - do_addchannels: cleanup and beautify
No changes w.r.t. to semantics.
2015-07-15 20:43:09 +02:00
Marcus Huewe
8d10a3f76f - removed debug output
Introduced in commit 76023d5643.
2015-07-15 20:01:32 +02:00
569efcace8 - make the enablechannels command also working for entire project 2015-07-15 15:22:26 +02:00
76023d5643 add "addchannels" and "enablechannel" commands 2015-07-14 16:03:35 +02:00
Marcus Huewe
fa4f24f06b - RpmQuery.rpmvercmp: support tilde ('~') 2015-07-03 14:22:00 +02:00
Daniel Gollub
64838ffd51 Support native Debian packages in pkg-prefer
fixes #158
2015-07-02 15:08:39 +02:00
cf9d65b09d - do not hide api side error message 2015-07-01 09:47:53 +02:00
f59b60e206 - release 0.152.0 2015-06-30 15:34:32 +02:00
381071a332 support maintenance_release requests with acceptinfo data (OBS 2.7) 2015-06-30 14:29:18 +02:00
Marcus Huewe
cbdc1389db - do_repourls: do not hardcode the download_url
Instead ask the api for the download_url configuration element.
2015-06-29 23:59:59 +02:00
Marcus Huewe
a80b286ac9 - fixed #147
Introduced new PackageQueryResult class and adapted existing
modules accordingly.
2015-06-23 17:52:37 +02:00
Marcus Huewe
84ba8c6e17 - fixed fullfilename calculation in the Pac class
Now, the fullfilename is calculated using the canonname of a
bdep instead of using the bdep's binary attribute (the canonname
and binary attribute can differ (e.g. ConsoleKit-64bit-0.4.6-3.2.ppc.rpm
vs. ::import::ppc64::ConsoleKit-64bit-0.4.6-3.2.ppc.rpm))
2015-06-16 17:37:40 +02:00
10aa2203bb - support target package in accepted maintenance_incident 2015-06-11 12:41:22 +02:00
caef99c3d9 - allow diffing of maintenance requests 2015-06-11 11:05:08 +02:00
e052839027 - support acceptinfo in maintenance_incident requests 2015-06-11 10:24:24 +02:00
1509db3ff1 - allow to use "osc chroot" also with lxc build-type 2015-06-09 17:26:57 +02:00
Marcus Huewe
4dc236dea4 - added "lock" command to lock a project or package 2015-05-30 16:27:54 +02:00
Arun Persaud
ac93a3934e More meaningful error if ET.parse runs into problems. Fixes #153. 2015-05-24 11:11:22 -07:00
Oleg Girko
ca2f1a90c8 Add support for non-root paths in API URLs.
Currently osc supports API URLs without path only,
like https://api.example.com (if there is pathname, it's just ignored).
With this change API URLS with path, like https://example.com/api
are supported correctly.

This is useful for those who can't have OBS api, webui and main site
on different domains and buy separate X.509 certificates for them,
or just can't afford to have separate IP addresses for them
(please note that currently osc doesn't support TLS SNI).

Signed-off-by: Oleg Girko <ol@infoserver.lv>
2015-05-14 16:46:10 +01:00
Jelle van der Waa
92dbd59814 When lxml fails to parse the _service file, instead of showing a backtrace
print a userfriendly error which line and column contains the XML syntax error
2015-05-13 14:35:17 +02:00
Michael Schroeder
f8f4119b88 Don't filter out \b,\v,\f,\r in logfiles 2015-05-07 15:51:51 +02:00
Marcus Huewe
e4919568eb - do_build: added --trust-all-projects option
--trust-all-projects can be used to disable the trusted project check
2015-05-05 23:39:58 +02:00
Marcus Huewe
de9191f146 - updated distributions that are used in the new project template
Also enabled debuginfo generation by default.
2015-05-05 22:46:26 +02:00
464652ab85 show possible used incident projects on "maintained" command
FATE#318944
2015-05-05 14:01:10 +02:00
Ludwig Nussel
826808d7cf allow force commit
useful to workaround https://github.com/openSUSE/open-build-service/issues/913
2015-04-29 13:44:12 +02:00
Andreas Schwab
ab111f4204 - do_deleterequest: fix help text 2015-04-27 11:04:46 +02:00
Marcus Huewe
a800f8f3fc Merge branch 'master' of https://github.com/andreas-schwab/osc 2015-04-27 10:49:48 +02:00
6de9cb4e03 - add support for buildtime source service mode 2015-04-24 09:47:48 +02:00
6886a0d58c - use "group:" prefix instead of "group/" like in other commands 2015-04-24 09:47:12 +02:00
Egbert Eich
95cfc2b96c Add missing tags for maintainer/bugowner
This was missed in 9937cb9ddf.

Signed-off-by: Egbert Eich <eich@suse.de>
2015-04-22 15:00:07 +02:00
Egbert Eich
9937cb9ddf Add support for searches for groups with -i, -b and -m
Involved parties can be persons or groups; add support for those.

Signed-off-by: Egbert Eich <eich@suse.de>
2015-04-22 12:40:07 +02:00
Andreas Schwab
dc8ab2ee30 Pass disk/swap/logfile options to obs-build also for VM type emulator 2015-04-17 11:10:54 +02:00
Andreas Schwab
b7912a78dd - do_buildhistory: split args on slash 2015-04-11 08:51:26 +02:00
e610cb569a Merge pull request #138 from k0da/threads
Pass threads option to obs-build
2015-04-08 10:30:14 +02:00
1a58102139 Merge pull request #135 from andreas-schwab/master
create_submit_request: fix return value when falling back to create_main...
2015-04-08 10:29:52 +02:00
dde0547558 Merge pull request #134 from k0da/master
ppc64le can build ppc64 in KVM
2015-04-08 10:29:20 +02:00
Marcus Huewe
40f4a61cbc - change_request_state: manual xml parsing is error-prone 2015-04-07 15:27:40 +02:00
Marcus Huewe
eda2e75655 - ServiceInfo.execute: cmd is a list...
See also pull request #141
2015-03-26 14:37:14 +01:00
8d39549253 fix crash, when source service failed 2015-03-18 09:02:48 +01:00
2258bc6d04 - fix regression of 72e38569ae
which broke "osc service run" command
2015-03-16 08:13:29 +01:00
19944be5b6 - 0.151.0 release 2015-03-12 19:49:30 +01:00
Ludwig Nussel
72e38569ae fix osc shell injection 2015-03-12 19:35:31 +01:00
Marcus Huewe
7116509330 - do_build: --noinit and --offline are _not_ mutually exclusive
Thanks to darix for the hint!
2015-03-10 15:49:35 +01:00
Dinar Valeev
e12f1b43c4 Pass threads option to obs-build
Currently --jobs sets only -smp flag for VM, in some cases we want
to pass threads as well. So the command line would like -smp 4,threads=4

Signed-off-by: Dinar Valeev <dvaleev@suse.com>
2015-03-10 11:58:08 +01:00
Marcus Huewe
cff76bdfbd - added "name" attribute to the RequestHistory class
This fixes "AttributeError: RequestHistory instance has no attribute 'name'"
2015-03-09 20:20:39 +01:00
Andreas Schwab
4357c8fcd4 create_submit_request: fix return value when falling back to create_maintenance_request 2015-03-09 11:21:22 +01:00
2d3a51139e - display updatelink option when showing submit actions 2015-03-09 09:01:00 +01:00
ecd76148b8 - add support for updating the link in target package in submit action
This is also changing the request format to post OBS 1.0, but
that was also the case before when a source update option was used.
2015-03-09 08:45:07 +01:00
Bernhard M. Wiedemann
00c7b9dbfc fix typo in help message (bnc#918906)
https://bugzilla.opensuse.org/show_bug.cgi?id=918906
2015-02-21 08:49:56 +01:00
4bd0436033 - fix mismatch in given time, backend delivers always UTC unix time seconds 2015-02-17 10:26:04 +01:00
453be845af - fix crash on buildhistory with source linked packages
revision is a md5 string in that case (github issue#136)
2015-02-12 12:52:32 +01:00
Marcus Huewe
8f5bf385be - do_status: mention 'S' state in the help text 2015-01-21 03:01:29 +01:00
Dinar Valeev
5cc8a05d46 ppc64le can build ppc64 in KVM
Little Endian host can do build in Big Endian VM

Signed-off-by: Dinar Valeev <dvaleev@suse.com>
2015-01-14 14:57:28 +01:00
d53278d94d - syntax fix 2015-01-13 16:50:47 +01:00
a3c23a575c - open 0.151 development 2015-01-09 15:50:46 +01:00
df9c28bba5 - prepare 0.150.0 release 2015-01-09 15:44:00 +01:00
0d66a5b1dc - add makeoriginolder option in request actions 2015-01-09 15:19:36 +01:00
Florian Bergmann
8a70a0f285 Added readline support to cmdln-module.
This was already fixed in the original module:
https://github.com/trentm/cmdln/issues/1

Signed-off-by: Florian Bergmann <fbergmann@suse.de>
2015-01-09 13:33:31 +01:00
fbbf945deb - trying a fallback in maintenance project detection
Evergreen project users not using their Evergreen:Maintenenace attribute
submit to the wrong place atm.
2015-01-09 11:21:51 +01:00
Marcus Huewe
8c8618ac91 - fixed corner case in __del__ method
For a detailed explanation see
d093c2b43b
2015-01-03 13:06:12 +01:00
Marcus Huewe
3547ef95ef Revert "Fix condition for using urllib2 workaround"
This reverts commit 2f14cedcff.

Actually, this was meant to fix https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=762825,
which was (probably) caused due to the following:
- commit 320238350f introduced a codepath, which
  should not be needed for python >= 2.7.1 (see also
  https://hg.python.org/cpython/rev/64287)
- this codepath uses the "reset_retry_count" method, which is not present in
  Debian Jessie's libpython2.7-stdlib: libpython2.7-stdlib_2.7.8-11 backports
  a patch from python's 2.7.9 branch, which removes the "reset_retry_count"
  method (https://hg.python.org/cpython/rev/c1edc4e43eb1).

This fixes bnc#911080 and github issue #131.
2014-12-23 04:34:40 +01:00
Marcus Huewe
68d10dfe8b Revert "- reset retry counter on 404 answer for all python 2.7.x versions"
This reverts commit 320238350f.
With python >= 2.7.1 this codepath should not be needed (see also
https://hg.python.org/cpython/rev/64287).

Conflicts:
	osc/conf.py
2014-12-23 03:46:32 +01:00
Marcus Huewe
b2ec0c263a Merge branch 'repr' of https://github.com/jelly/osc 2014-12-17 12:30:50 +01:00
9cddc53afc - add mr --release-project option for kgraft updates 2014-12-12 13:44:24 +01:00
Jelle van der Waa
0495439093 Add __repr__ for Repo class 2014-12-10 09:51:50 +01:00
Michael Schroeder
7ca0b2d04e send conflicts/obsoletes for local packages as well
Also sends the missing "I" entry, so the backend has no longer
to guess the version from the self-provides.
2014-12-09 13:12:34 +01:00
Michael Schroeder
7acaba2d8a add obsoletes, conflicts, evr query methods 2014-12-09 13:04:55 +01:00
Marcus Huewe
e1e2dd8676 - fixed #129
Basically, this was broken since commit bb75ce34fd.
2014-12-08 22:19:28 +01:00
Marcus Huewe
42d3e815c1 - do_status: mark a frozen package with an "F" 2014-11-21 16:12:26 +01:00
Marcus Huewe
fddf2e3e6c - Package.mark_frozen: also print the name of the affected package
This is needed if mark_frozen is (indirectly) called from Project.update
(otherwise it is not clear for which project an "osc pull" has to be performed).
2014-11-21 16:00:07 +01:00
Denis Pynkin
d17b497867 Added configuration options for kernel and initrd selection during KVM build
Some distributions have no initrd images compatible with KVM builds and
sometimes we need to use not system kernel version.

New options in configuration file:
- build-kernel -- kernel used for VM builds
- build-initrd -- initrd image used for VM builds
2014-11-20 19:09:53 +03:00
Michael Schroeder
f47c39521d Verify hdrmd5 of packages if specified in the buildinfo
Needed for buildenv builds that want specific packages.
2014-11-17 12:40:54 +01:00
Marcus Huewe
930dfc1999 - parse_repoarchdescr: added openSUSE_Tumbleweed to the repository list 2014-11-17 10:12:35 +01:00
Marcus Huewe
ad92e8abb7 - fixed #122 ("osc chroot fails to use the osc build buildroot directory")
Renamed osc chroot's "--root" option to "--login-as-root" (kept the short
option "-r"). Added new "--root /path/to/buildroot" option (this is consistent
with "osc build --root...").
2014-11-14 15:54:55 +01:00
87021e41fe - fix crash regression 'issue#124' 2014-11-12 14:40:24 +01:00
de702bb8ed - follow the request order of the api (sorting according to priorization) 2014-11-11 08:26:17 +01:00
Michael Schroeder
6ccf64fc2f fix buildenv data name, it needs to be "buildenv"
The repo server is kind of picky...
2014-11-07 13:52:06 +01:00
Michael Schroeder
d5b795a02b osc build: add support for _buildenv upload 2014-11-07 13:41:34 +01:00
Marcus Huewe
165d2385da - edit_message: restore old filename suffix
Due to the refactoring in commit bb75ce34fd
the suffix defaulted to '.txt'.
2014-11-02 20:12:16 +01:00
6a4423ff62 - better example for osc api -e 2014-10-31 14:14:06 +01:00
bb75ce34fd - add "osc api --edit" option 2014-10-31 09:22:25 +01:00
Marcus Huewe
3e57d58729 - do_meta: fixed description (partly fixes #120) 2014-10-27 01:31:47 +01:00
Marcus Huewe
27bdf6cbdd - do_addremove: if a "deleted" file exists in the wc, track it again 2014-10-21 22:31:30 +02:00
Marcus Huewe
26ffaa9de8 - do_addremove: fixed "corner case"
Assume $PWD/x is a directory and /path/to/pkg/x is an unversioned file.
Without this fix, "osc ar /path/to/pkg" did not add the file "x".
2014-10-21 22:23:28 +02:00
Marcus Huewe
e8f0e78672 - do_addremove: use local variable instead of an attribute (cosmetic) 2014-10-21 22:15:54 +02:00
Marcus Huewe
c69237b14d - open 0.150 development 2014-10-21 11:09:09 +02:00
Marcus Huewe
4c4650f0e9 - prepare 0.149 bugfix release 2014-10-21 11:02:30 +02:00
Marcus Huewe
ca7ad96ec9 - raise more specific exceptions 2014-10-20 13:29:03 +02:00
Marcus Huewe
67caa8b555 - oops, fixed typo
Call "update_needed" instead of "needs_update"
2014-10-11 13:29:47 +02:00
e3bb5fba23 - support multiple parallel maintenance workflows
for the same projects. So do not use project "maintains", but the
attribute to be able to switch between maintenance, security and PTF
working contexts for example.
2014-10-07 16:40:42 +02:00
Marcus Huewe
a7c92eb18f - do not hardcode path to the build scripts and removed legacy check 2014-10-01 14:45:48 +02:00
Adam Spiers
e1cdf86bdf fix osc service exit code
Commands like "osc service disabledrun" would always return exitcode 0
even when the source service failed.  This broke any scripts which
wrapped around osc service.
2014-09-30 12:51:13 +01:00
Marcus Huewe
e44a452d3e - fixed #99 ("do_package_tracking = 0") 2014-09-26 13:41:53 +02:00
Sjoerd Simons
2f14cedcff Fix condition for using urllib2 workaround
See https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=762825
2014-09-26 09:54:03 +02:00
Marcus Huewe
603cf3b713 - fixed #113 ("osc creq -s ...") 2014-09-23 13:05:10 +02:00
Marcus Huewe
45bf1945d0 - do_createrequest: remove --diff option
This never worked and makes no sense (IMHO): use "osc request" for things
like that.
2014-09-23 12:45:44 +02:00
00ecb4de15 - fix crash with not existing priorities 2014-09-12 09:02:38 +02:00
3d07bd8460 - fix description rendering in history elements 2014-09-11 14:34:22 +02:00
ea092a7f23 - roll 0.148 release for new request history support 2014-09-11 12:33:30 +02:00
bd82e236ee - display request priorities, if important or critical
- add "osc rq priorize" command to re-priorize existing requests
 - allow also "osc rq ls" shortcut
2014-09-11 11:25:24 +02:00
b0479fa760 - support new history including review history of OBS 2.6 2014-09-11 11:08:13 +02:00
Denis Pynkin
e0d96a49b3 Initialize variable 's_built' during image build.
Fixed images local build failure because of
uninitialized variable 's_built'.
2014-09-09 16:07:35 +03:00
6a7535d2e7 open 0.148 development 2014-08-26 09:53:19 +02:00
3606506d1e - prepare 0.147 release 2014-08-26 09:50:19 +02:00
3b6f7f1269 - make it possible to list by given review states
it used the state always for request and review state before, which makes no sense.

makes the code a bit nicer as well hopefully as well
2014-08-25 17:02:56 +02:00
3adb160e0f support groups in maintainership requests 2014-08-19 14:34:18 +02:00
Marcus Huewe
b07a4d0b37 Merge branch 'w291' of https://github.com/berendt/osc
Conflicts:
	osc/build.py

Resolved merge conflict.
2014-08-14 17:24:28 +02:00
Christian Berendt
1751bdc47f Resolve PEP8 issue E231
* E231 missing whitespace after ':'
2014-08-13 17:30:12 +02:00
Christian Berendt
d35983d5b8 Resolve PEP8 issue W291
* W291 trailing whitespace
2014-08-12 15:01:16 +02:00
Ludwig Nussel
1b6e2ac745 support the ls expand option also for projects
packages of linked projects can be listed using the expand option
2014-08-11 17:06:18 +02:00
Marcus Huewe
902adde28b - do_localbuildlog: support %(apihost)s in build-root config setting 2014-08-04 11:15:34 +02:00
7649481167 - use "set_version" service by default on "osc add git://..." 2014-07-22 09:31:54 +02:00
6a6e614661 - switch to xz default for "osc add git://" ... 2014-07-22 09:30:43 +02:00
Marcus Huewe
e9233a5eab - parse_repoarchdescr: remove duplicates from repo_names 2014-07-21 14:32:54 +02:00
Marcus Huewe
e90a60a8c8 Merge branch 'livebuild' of https://github.com/jblunck/osc 2014-07-16 10:51:06 +02:00
Marcus Huewe
ea349d9ad0 - do_buildinfo: fixed "osc buildinfo -p <path>" 2014-07-15 20:38:19 +02:00
f8a1fa2ebc - give a better hint to the user, when a search role is not defined 2014-07-10 09:50:52 +02:00
Jan Blunck
475d2a298d Add support for livebuild buildtype
This commit allows for 'osc build' to do local builds of type livebuild.
Debian livebuild is the native Debian live image building system.

Signed-off-by: Jan Blunck <jblunck@infradead.org>
2014-07-08 21:18:01 +02:00
Jan Blunck
b2ad3ebabc Make get_built_files() take the buildtype instead of the pactype
It is possible that two different build types use the same package type.
Therefore we need to make get_built_files() work on the build type.

Signed-off-by: Jan Blunck <jblunck@infradead.org>
2014-07-04 16:42:53 +02:00
Marcus Huewe
d86e28744f - parse_repoarchdescr: allow an unsupported arch during the guessing phase
This makes the error message in some cases more precise (for instance
"osc build openSUSE_13.21 x86_641")
2014-07-02 23:56:34 +02:00
Marcus Huewe
e662fd815b - parse_repoarchdescr: improved yet another error message 2014-07-02 23:13:42 +02:00
Marcus Huewe
a8d0b948af - parse_repoarchdescr: improved error messages a bit
Moved reading/writing of .osc/_build_repositories into the Repo class.
2014-07-02 22:07:01 +02:00
Dinar Valeev
ee15c4cb11 Add ppc64le to Debian arch map
Signed-off-by: Dinar Valeev <dvaleev@suse.com>
2014-06-25 15:05:17 +02:00
Marcus Huewe
cb9a5d5a17 - show_project_sourceinfo: quote package names 2014-06-24 23:05:38 +02:00
Marcus Huewe
0389a0343c - renamed {show,get}_sourceinfo to {show,get}_project_sourceinfo 2014-06-23 10:58:20 +02:00
Marcus Huewe
d45b3e49c0 - get_sourceinfo: workaround for too long request uri (status code 414) 2014-06-23 09:51:49 +02:00
Marcus Huewe
2f8db7fea0 - speedup update of a project working copy
The new code tries to reduce the number of http requests for unchanged
packages (that is, packages that do not need an update).
In the worst case (the project wc's packages are unchanged and contain
services, for example), the new code needs #http requests of the old code + 1
http requests. But we can improve, once the "noservice" patch
(see http://lists.opensuse.org/opensuse-buildservice/2014-06/msg00067.html)
is merged.
Note: the semantics of the update process itself did not change.
2014-06-22 15:41:14 +02:00
Marcus Huewe
fdfbcdc6eb - babysitter: catch URLGrabError exception 2014-06-08 22:32:35 +02:00
Marcus Huewe
a754164067 - use HTTPError.hdrs instead of HTTPError.headers
There are situations where a HTTPError instance has no headers
attribute.
2014-06-08 21:33:06 +02:00
Marcus Huewe
444a503bca - fixed #89 ("osc commit fails with do_package_tracking = 0") 2014-06-04 16:17:06 +02:00
Marcus Huewe
fff6f3ddb1 Merge branch 'fix-bl-strip-time' of https://github.com/rudimeier/osc 2014-06-04 15:49:59 +02:00
Marcus Huewe
7efd6db501 - added support for a per apiurl "build-root" option
Resolution order:
OSC_BUILD_ROOT env var > apiurl build-root option > general build-root option
2014-06-04 15:33:30 +02:00
Marcus Huewe
e2abfe9e6a - OscConfigParser: added "proper" parameter to the has_option method
This can be used to check if the option belongs to the section or is
just "inherited" from the defaults.
2014-06-04 15:29:50 +02:00
Ruediger Meier
7fc5936faf core: fix, buildlog --strip-time failed to remove time
If a time field is not complete within the same read block
then it can't be found by time_regex in buildlog_strip_time().

Fixed by simply reading line by line. I couldn't measure any
performance difference neither for real nor user time. IMO no
need to optimize for more lines per data chunk. Maybe it's
even more fluent now for interactive users.

BTW we can safely simplify time_regex.

Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2014-05-23 09:19:07 +00:00
Ruediger Meier
1d7b954022 core: streamfile() can read line by line
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2014-05-23 09:17:01 +00:00
Ruediger Meier
6bb8ca437b core: style, de-duplicate read() calls
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
2014-05-23 09:10:48 +00:00
Marcus Huewe
a833120ebd do_updatepacmetafromspec: added "updatepkgmetafromspec" alias 2014-05-22 13:01:44 +02:00
7f21679413 - do not forward requests if accept fails (issue 91) 2014-05-21 15:45:07 +02:00
c7222540e3 - restore default behaviour of setlinkrev command
The purpose of the default is to freeze the link
to the current version in the link target. It did
entirely drop the rev attribute which basically
unfreeze the link (same as -u).
2014-05-16 10:30:15 +02:00
Marcus Huewe
c873252d70 - do_build: do not suppress --download-api-only option
Or was there a particular reason for not displaying this option in
"osc build -h"?
2014-05-15 17:48:11 +02:00
3e7f355a0a - show errors when request change failed 2014-05-15 18:09:47 +02:00
Michael Schroeder
42c357336e take epoch into account when calculating the filename
ArchLinux has the epoch in the canonname, Debian discusses doing
this as well.
2014-05-13 13:29:41 +02:00
f20b26007e - fix another place of group handling for set_bugowner 2014-05-09 10:31:17 +02:00
Marcus Huewe
38fbe8fb11 - do_maintainer: introduced setBugownerHelper method
Do not swallow urllib2.HTTPError exceptions with code != 403
2014-05-08 16:07:42 +02:00
Marcus Huewe
87fc39fee4 - do_maintainer: do not set bugowner/create bugowner request action twice 2014-05-08 15:41:15 +02:00
Marcus Huewe
47af622031 - do_maintainer: fixed typo (that cause a TypeError) 2014-05-08 15:26:29 +02:00
Marcus Huewe
474dcf6843 - handle ImportError of a plugin more gracefully
See bnc#876538 for the details.
2014-05-06 18:51:12 +02:00
Michael Schroeder
5a65b06927 support installonly/noinstall tags for mock buildengine 2014-04-30 16:26:03 +02:00
Marcus Huewe
5e22cd3f4f - do_submitrequest: use continue to start next loop iteration (instead of "next"...) 2014-04-28 15:09:29 +02:00
Marcus Huewe
c398cb344a - fixed testsuite (and indention)
Broken by commit 0e3641610e
2014-04-16 15:56:59 +02:00
0e3641610e support maintenance release request with acceptinfo data (OBS 2.6) 2014-04-16 15:47:58 +02:00
Marcus Huewe
d6e6c0538e - get "osc build --prefer-pkgs ..." working with Arch 2014-04-03 17:41:41 +02:00
Marcus Huewe
0b7e49b648 - open 0.146 development 2014-04-03 09:32:21 +02:00
Marcus Huewe
2170abb612 - prepare 0.145.0 release 2014-04-03 09:31:51 +02:00
Andreas Schwab
9ab3c5becc print_buildlog: don't strip tabs 2014-03-15 22:27:33 +01:00
Marcus Huewe
d243241b1c - added support for "osc requestmaintainership PROJECT" (if cwd is no package wc) 2014-03-12 16:41:46 +01:00
Marcus Huewe
c66a75018e - do_submitrequest: consider the "--yes" option if the wc has local modifications 2014-03-12 10:50:46 +01:00
Marcus Huewe
8c506e5929 - fixed "osc -H ..." in combination with a proxy 2014-03-11 19:40:27 +01:00
Marcus Huewe
9034b27814 - fixed creation of ~/.osc_cookiejar
A "PyCFunction_Type" like os.open takes no keyword arguments.
2014-03-10 22:36:56 +01:00
Marcus Huewe
720c685868 - core.Package.commit: make sure a _meta is created for newly added packages
Fixed typo (introduced in commit 6469efb9ed).
2014-03-06 10:25:30 +01:00
Marcus Huewe
6469efb9ed - core.get_local_origin_project: added check for None 2014-03-06 09:56:13 +01:00
714de8519c - support release --set-release option 2014-03-05 16:03:23 +01:00
46b8f2613f - fix --no-checks description 2014-03-04 09:12:26 +01:00
Marcus Huewe
8b058b3a47 - do_setlinkrev, set_link_rev: fixed #72
Also refactored set_link_rev code a bit so that the new _set_link_rev
function could be used by link_pac in the future.
2014-03-03 22:44:30 +01:00
Andreas Schwab
1dc8109ef8 Fix missing unquote in meta pkg check
Fixes issue #77
2014-02-28 00:42:47 +01:00
Ludwig Nussel
f065dc4765 show source revision in submit requests 2014-02-27 16:46:49 +01:00
Scott Bahling
a33c40eb53 Fix handling of meta command within local working directory
* Fix osc ignoring -A apiurl command option when arguments are
  less than 2 and executed within local working copy

* Enhance handling of meta command within local working copy.
  - meta prj: Try to use project and apiurl of local working copy
    if no arguments are passed
  - meta pkg: Try to use project and apiurl of local working copy
    if one argument is passed (single argument assumed to be package
    name), and try to use project, package and apiurl if no
    arguments are passed
2014-02-27 16:45:44 +01:00
c4f0397b0f Takes care when the commit is in project level 2014-02-27 16:45:44 +01:00
014551e786 Move the user interaction for linked package into commandline.py 2014-02-27 16:45:44 +01:00
fdd58e23c8 - roll 0.144.0 release 2014-02-27 10:42:03 +01:00
Ludwig Nussel
955c46495b replace sys.exit(0) to avoid backtrace 2014-02-27 08:39:54 +01:00
Marcus Huewe
d92098a864 - Package.commit: fixed spelling error and added FIXME comment 2014-02-25 14:09:04 +01:00
Marcus Huewe
d8e0b82b10 - fixed core.edit_meta
The change introduced in commit a20c6f5d99
broke the creation of new packages.
2014-02-25 14:06:20 +01:00
a20c6f5d99 Allow commits to linked pakages.
If the package is linked to a different project, osc will ask
permision to branch the package in the current project before
commiting.

Show a message in osc meta pkg -e in the same case.
2014-02-24 16:02:47 +01:00
Marcus Huewe
87e24c3aa6 - do_commit: added --no-message option
Commit without specifying a log comment. Fixes #73.
2014-02-12 14:52:39 +01:00
Sascha Peilicke
3c0dbaba7f Add flag '--noverify' next to '--no-verify'
Align with other '--no$bla' flags. Note that the alternative is added
after '--no-verify', optparse uses the first arg for the stored config
variable.
2014-02-12 12:26:59 +01:00
Marcus Huewe
b5d47ebd8c - do_maintainer: fixed support for groups
Ideally, the whole method will be refactored one day...
2014-02-11 11:56:44 +01:00
Marcus Huewe
49ed086d0b - do_vc: added a --file <filename> option
Can be used to read changes from <filename>.
2014-02-05 17:50:31 +01:00
98a625e89e - show also error details on request accept error 2014-02-04 14:35:30 +01:00
2c6415264d - fix "osc build $repo aarch64" call without specifing a spec file. aarch64 is not recognized as architecture due to wild parameter guessing 2014-02-03 17:33:49 +01:00
e1007e1bd8 - show api error on failure of request/review accept 2014-01-30 11:52:24 +01:00
0557fecd02 - support bugowner set of groups 2014-01-24 17:01:35 +01:00
cb14b06a74 open 0.144 development 2014-01-24 10:51:00 +01:00
af2dffb002 prepare 0.143 2014-01-24 10:48:46 +01:00
7fcb1bbe3e - fix set bugowner command 2014-01-24 10:29:00 +01:00
9e07851310 - fix "osc up -S" including service files, regression in 0.142 from commit 930974b4ab 2014-01-21 18:09:20 +01:00
Marcus Huewe
cf35fb441f - do_request: support float values for --days (affects list) 2014-01-14 11:04:04 +01:00
Marcus Huewe
edd199af3b - _load_plugins: handle NameError more gracefully 2014-01-10 15:58:33 +01:00
Marcus Huewe
9a8679a21e - core: added wrapper for os.utime (workaround for bnc#857610)
It seems that os.utime raises EINVAL if the file resides on a nfs
share. Since osc itself does not rely on the correct utime, we simply
ignore this exception.
2014-01-09 14:15:30 +01:00
Marcus Huewe
a4632969e4 - core.Package.commit: only update store if the commit was successful
This fixes bug #65
2014-01-09 13:56:34 +01:00
Marcus Huewe
5e5427f9be - ServiceInfo.execute: also cleanup dirs
Fixes #67.
2014-01-09 10:24:48 +01:00
Michal Vyskocil
111fd87715 passx encode/decode functions
The string.encode('bz2') does not work in python3. Implement
passx_encode/passx_decode functions compatible with python 2.6, 2.7 and
3.3.

Add a simple unit test.
2014-01-08 15:43:57 +01:00
Vitezslav Cizek
f85c76bd42 correctly specify --delete option when using rsync 2014-01-08 15:18:02 +01:00
Michal Vyskocil
5d5185cbc6 chmod handling
* prefer os.open instead of open && os.chmod
 * prefer os.fchmod when fd exists
2014-01-06 11:12:02 +01:00
Marcus Huewe
550039f746 - core.request_interactive_review: be able to edit a "maintenance_incident"
Fixes #64.
2013-12-16 10:59:07 +01:00
Michal Čihař
e9793df634 Fixed typo in authentication 2013-12-09 19:26:15 +01:00
Marcus Huewe
daf5da2f18 Merge branch 'master' of https://github.com/bartosh/osc 2013-12-06 10:57:25 +01:00
Marcus Huewe
d04c36189e - core.http_request: remove timeout cruft 2013-12-05 18:30:40 +01:00
Ed Bartosh
2d29c35f46 Fixed traceback in get_prj_results
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>
2013-12-05 16:46:30 +02:00
f202fbd111 add option for deleterequests using auto-accept 2013-12-05 10:23:53 +01:00
Dinar Valeev
359d5c5a84 ppc64le can be built on ppc64
In case vm-type is KVM, we can build Little Endian packages on Big
Endian host.

Signed-off-by: Dinar Valeev <dvaleev@suse.com>
2013-12-03 08:25:13 +01:00
Andreas Schwab
b2e94ff3af Fix wipebinaries 2013-12-01 19:01:58 +01:00
Marcus Huewe
2d7f644f44 Merge branch 'master' of https://github.com/thorstenb/osc 2013-11-28 11:52:02 +01:00
602841f14b - fix upload of binary files via POST api call (use right content type) 2013-11-27 11:13:08 +01:00
Thorsten Behrens
9561a99d6b Do not pass on unicode password from keyrings.
Seems at least gnome keyring returns a unicode string here
needlessly, which calling code then trips over.
2013-11-21 23:46:45 +01:00
99b3af9a41 - open 0.143 development 2013-11-21 10:32:17 +01:00
de3e141256 - roll 0.142 release 2013-11-21 10:27:49 +01:00
Sascha Peilicke
89eb129e4d Same output as "osc branch" for mbranch command
Users can just copy-paste the "osc co ..." command in their shell and be
more productive.
2013-11-18 13:48:09 +01:00
Marcus Huewe
73048d1159 - yet another fix for the previous commit 2013-11-15 11:42:58 +01:00
Marcus Huewe
b2493a25ae - fix for 6a36b5180a
It is ridiculous that we have duplicated code for "osc sr" and
"osc createrequest"...
2013-11-15 11:39:21 +01:00
Marcus Huewe
6a36b5180a - do_submitrequest: automatically supersede existing requests if "--yes" was specified
Fixes #58
2013-11-15 11:13:27 +01:00
a7ea5043ae - allow also to execute a token with a registered service 2013-11-13 18:23:44 +01:00
B S Srinidhi
bd3a6d2fc8 Include filelimit=0 when querying full serverside diff
Without this change, "osc rdiff -p" simply returns "(XXX lines skipped)"
2013-11-11 01:39:32 +05:30
Dinar Valeev
82a5350a11 Add ppc64le architecture
This commit adds PowerPC64 Little Endian architecture support

Signed-off-by: Dinar Valeev <dvaleev@suse.com>
2013-11-06 09:11:05 +01:00
63e1124c09 - add support to handle authentification token support 2013-10-31 09:12:17 +01:00
67802e6a41 - support restartbuild and abortbuild
small refactoring but keep api compability
2013-10-28 18:30:32 +01:00
Sascha Peilicke
43499172af Kill Danny's awesome english 2013-10-28 10:21:21 +01:00
ad9a32ca8f - handle also gateway timeout error code when watching build results 2013-10-22 17:58:53 +02:00
Marcus Huewe
e89bc8197b - fixed #52 ("osc dumps on ci") 2013-10-22 13:49:14 +02:00
Marcus Huewe
b85beda33b Merge branch 'master-develproject-unset' of https://github.com/saschpe/osc 2013-10-21 18:04:43 +02:00
Michael Schroeder
930974b4ab prepare for the serviceinfo element having an xsrcmd5 in the error case 2013-10-18 14:58:18 +02:00
Sascha Peilicke
569e89fede Add --unset parameter to setdevelproject
Allows to unset the devel project (much like setlinkrev -u).
2013-10-18 11:50:07 +02:00
Sascha Peilicke
5ef2d4035c Merge pull request #37 from k0da/master
Add ppc64p7 architecture
2013-10-18 02:31:30 -07:00
Sascha Peilicke
3d72e60321 Improve devel project commands.
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.
2013-10-07 14:31:50 +02:00
Sascha Peilicke
42f9f2bf3e Set socket timeout to 0 by default.
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".
2013-09-30 17:23:02 +02:00
Marcus Huewe
7f1d7f6258 - do_request: added --no-devel option in order to disable the forwarding to the devel project (if the request is accepted)
Original patch by "Dominique Leuenberger a.k.a. Dimstar" <dimstar@opensuse.org>
(I just renamed the option from "--nodevel" to "--no-devel").
2013-09-25 15:36:54 +02:00
f5ec5734e3 - set mtime (if specified) after copying from .osc/ directory.
Patch by Roman Drahtmüller
2013-09-23 17:11:52 +02:00
38edcb605f - drop double read(), the copy_pac method is doing that already and python 2.6 is crashing here 2013-09-17 16:39:23 +02:00
744ce9155f - release 0.141 2013-09-17 13:49:53 +02:00
Sascha Peilicke
529e1d4716 Fix copypac with _pattern files
Some _pattern packages do have indeed a _meta.
2013-09-16 17:27:01 +02:00
Marcus Huewe
bf2e372c30 - added new "osc clean" command
"osc clean" removes all untracked files from a package working
copy.
2013-09-12 16:14:14 +02:00
aef9f7e6d2 - _sslcert is stored in meta space 2013-09-05 14:54:15 +02:00
edda98eaff - add signkey --sslcert option to fetch the optional create ssl certificate instead of gpg key 2013-08-30 09:41:13 +02:00
Marcus Huewe
b2b2d54312 - oscerr.ServiceRuntimeError: fixed docstr 2013-08-29 15:35:40 +02:00
Marcus Huewe
1614123f82 - babysitter: catch ServiceRuntimeError
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...
2013-08-29 15:22:25 +02:00
Marcus Huewe
1176983a9a - core.edit_submitrequest: fixed (logic) typo 2013-08-28 23:03:25 +02:00
Marcus Huewe
77f9030016 - core.Action: added basic support for a "group" action
Request.format_action is no staticmethod anymore because the formatting
of a "group" action needs the request id.
2013-08-28 23:00:35 +02:00
a8e7b6edd0 - report valid error on "group" request actions for now 2013-08-16 11:53:21 +02:00
Marcus Huewe
c78da6c496 - _load_plugins: also add imported modules to the class
This is needed for backward compatibility. New plugins
(which do not care about "old" osc versions) should not
use "self.<imported modname>.<something>" anymore
to refer to the imported module. Instead use
"<imported modname>.<something>" (this will only work with
osc > 0.140.1).
2013-08-15 17:26:07 +02:00
1c412c14ee - show warning on auto accepting requests 2013-08-14 18:30:43 +02:00
bdc772ef10 - sync appliance building using obsrepositories with bs_worker code 2013-08-14 18:30:43 +02:00
Marcus Huewe
420f61cdca - OscConfigParser: check explicitly for python3 when importing "configparser" (patch by Kay Hayen <kay.hayen@gmail.com>)
There's a another python module around which is also called
"configparser" but which does not seem to be api compatible => so
do not import it.
2013-08-14 15:19:03 +02:00
2be979361e All rename cases require delete=False 2013-08-13 11:54:11 +02:00
6461c9faf0 add --last parameter for build logs to show last finished log file, if currently building 2013-08-13 10:38:43 +02:00
531251a86c Fix file descriptor leaks during download
This makes it possible to build packages which
require more than 512 packages for building.
2013-08-12 18:31:27 +02:00
Marcus Huewe
bcacedcd96 - babysitter.run: added new argv parameter
This way other python scripts can execute osc commands via the
babysitter. Example:

>>> from osc import babysitter, commandline
>>> cli = commandline.Osc()
>>> babysitter.run(cli, ['osc', 'ls', '<project>'])
2013-08-07 23:25:31 +02:00
Marcus Huewe
aacbf6a03b - core: added new _editor_command function
Used by "run_editor" and "_edit_message_open_editor" to retrieve
the editor command.
2013-08-03 19:34:47 +02:00
Marcus Huewe
132a2d128f - run_editor: added fallback if shlex.split raises a SyntaxError
Fall back to a plain split in order to support an arbitrary $EDITOR
value.
2013-08-03 19:23:25 +02:00
Marcus Huewe
0e30e56ded - run_editor: use shlex.split instead of plain split in order to build a proper cmd for $EDITOR 2013-08-03 17:20:03 +02:00
Ionuț Arțăriși
2dac43aecf rephrase trust prompt
'always' is a key word in that sentence and it should be the first word;
it also sounds like better English this way
2013-07-25 17:19:04 +02:00
Marcus Huewe
67a0671c8a - _load_plugins: follow-up fix for commit 58d716a6f7
Only add functions to the Osc class which are defined in the _current_
module.
2013-07-23 12:10:31 +02:00
Miroslav Suchý
12ffb4e3c4 correctly refer to exception
this is left-over from 87d354e1a0

Addressing:
Traceback (most recent call last):
  File "/usr/bin/osc", line 26, in <module>
    r = babysitter.run(osccli)
  File "/usr/lib/python2.7/site-packages/osc/babysitter.py", line 60, in run
    return prg.main()
  File "/usr/lib/python2.7/site-packages/osc/cmdln.py", line 335, in main
    self.postoptparse()
  File "/usr/lib/python2.7/site-packages/osc/commandline.py", line 136, in postoptparse
    override_verbose = self.options.verbose)
  File "/usr/lib/python2.7/site-packages/osc/conf.py", line 873, in get_config
    add_section(conffile, url, user, passwordx)
  File "/usr/lib/python2.7/site-packages/osc/conf.py", line 712, in add_section
    except OscConfigParser.ConfigParser.DuplicateSectionError:
AttributeError: class OscConfigParser has no attribute 'ConfigParser'
2013-07-17 10:22:29 +02:00
41adda44f6 - add support for manual release of sources with binaries (FATE #315250) 2013-07-08 15:59:14 +02:00
Marcus Huewe
2b9a7d166e - fixed "get_prj_results(...)" when calling with status_filter='U' 2013-07-04 22:15:14 +02:00
0437ab9be0 - support for kiwi appliance builds using obsrepositories:/ directive 2013-07-04 16:41:59 +02:00
Marcus Huewe
87aaa9aac4 - checker.check: always close fd 2013-07-04 14:24:29 +02:00
1d7cb3d1db - add armv6hl definition 2013-07-04 11:04:31 +02:00
Marcus Huewe
58d716a6f7 - _load_plugins: add all functions from the plugin to the Osc class
Adding only functions which starts with "do_" breaks the old
behavior.
2013-06-26 10:18:14 +02:00
Marcus Huewe
4996b1d1ac - do_copypac: fixed help text of the --revision option (as suggested by darix)
It "copies" the specified revision instead of "linking" it.
2013-06-21 15:11:20 +02:00
Marcus Huewe
668a017565 - open 0.141 development 2013-06-21 15:10:54 +02:00
dbd38296fa - tag it as 0.140 2013-06-20 10:46:37 +02:00
Marcus Huewe
58532bbac7 - small fix for commit d338254bb7
catch HTTPError instead of TypeError
2013-06-17 17:37:40 +02:00
Sascha Peilicke
d338254bb7 Display meaningful message for queries w/o project
Like: osc rq list -U $USER -t change_devel
2013-06-17 16:26:00 +02:00
Sascha Peilicke
4007800880 Catch specific exception. Catch-all is calling for error 2013-06-17 16:21:32 +02:00
Marcus Huewe
0ac1d32945 - oscssl.verify_certificate: also print cert info if http_debug is set
If http_debug is set we redirect sys.stdout to an StringIO
instance in order to do some header filtering (see conf module)
so we have to use the "original" stdout for printing the certificate
information.
2013-06-15 08:53:26 +02:00
Marcus Huewe
b6c9505274 - reworked the plugin loading mechanism
Using the "old" exec approach isn't possible anymore because it'll break all
plugins which aren't compatible with python3 (for instance the usage of
python2's "print" statement will lead to an error). In order to circumvent
this problem we do the following:

- import the plugin/module
- update the module's global symbol table with the "globals()" of the
  commandline module
- bind the module's "do_*" functions to the "Osc" class

This basically mimics the old "exec" semantics.
2013-06-13 20:10:12 +02:00
467757b76d - do not show unpublished information in dirty situation 2013-06-13 16:42:25 +02:00
da8c123d85 - show the situation that packages succeeded to build, but are not yet published (way to many questions due to that) 2013-06-13 16:27:58 +02:00
Dinar Valeev
51b549db3a Add ppc64p7 build definitions 2013-06-07 13:28:57 +02:00
Juergen Weigert
4b48cc611f fixed plugin crash message: include the plugin name
Two occurences.
2013-06-06 12:36:48 +02:00
Juergen Weigert
c7a15b9dab fixed plugin crash message: include the plugin name 2013-06-06 11:55:50 +02:00
Marcus Huewe
4736763c22 - reverted commit 9acda37d5f
Now "get_built_files" always returns a tuple which consists of two strings.
So no cast is needed anymore.
2013-06-03 16:32:39 +02:00
Danny Al-Gaaf
96183f41f3 OscConfigParser.py: silence pylint false positive E0702
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 15:20:56 +02:00
Danny Al-Gaaf
a3cf8e8552 OscConfigParser.py: fix __delitem__
Two issues:
- There is no _find() member in ConfigLineOrder. Use _find_section()
  instead
- Use 'key' instead of 'line' as argument for _find_section() since
  'line' is used before assignment.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 15:14:15 +02:00
Danny Al-Gaaf
a5d14bfd48 checker.py: "More than one statement on a single line"
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 14:58:58 +02:00
Danny Al-Gaaf
6a6b25f9cb fetch.py: fix "More than one statement on a single line"
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 14:58:15 +02:00
Danny Al-Gaaf
f889edabfa core.py: add missing spaces
Add missing spaces around operators and spaces after comma.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 14:56:24 +02:00
Danny Al-Gaaf
3ac21eb1e3 build.py: add missing spaces
Add missing spaces around operators and spaces after comma.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 14:47:16 +02:00
Danny Al-Gaaf
b55d4d6b99 util/archquery.py: remove unnecessary semicolon
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 14:30:08 +02:00
Danny Al-Gaaf
2f197c698b build.py: remove unnecessary semicolon
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 14:28:59 +02:00
Danny Al-Gaaf
2062333977 core.py: fix bad indentation
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 14:26:58 +02:00
Danny Al-Gaaf
7e3a901596 build.py: fix bad indentation
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 14:19:44 +02:00
Danny Al-Gaaf
6db0431cb7 fetch.py: fix bad indentation
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 14:16:58 +02:00
Danny Al-Gaaf
e1ea202802 cmdln.py: fix reimport of 're'
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 14:13:19 +02:00
Danny Al-Gaaf
b99a05e167 cmdln.py: remove some reimports of sys
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 14:07:04 +02:00
Danny Al-Gaaf
c84f413c10 oscssl.py: remove reimport of m2 from M2Crypto
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 13:47:48 +02:00
Danny Al-Gaaf
ca306fbb29 commandline.py: remove some unnecessary pass statements
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 13:42:28 +02:00
Danny Al-Gaaf
42b8d5ff45 commandline.py: fix "More than one statement on a single line"
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 13:38:49 +02:00
Danny Al-Gaaf
c261a80d46 commandline.py: remove comma, causing trouble
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 13:06:01 +02:00
Danny Al-Gaaf
00e3932e43 commandline.py: wrap some really long lines
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 13:03:46 +02:00
Danny Al-Gaaf
8403c92059 commandline.py: add missing spaces
Add missing spaces around operators, add missing spaces after comma.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 12:41:50 +02:00
Danny Al-Gaaf
439e03501d commandline.py: remove unnecessary semicolon
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 12:18:43 +02:00
Danny Al-Gaaf
e1b8022ca0 commandline.py: fix bad indentation
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-27 12:16:44 +02:00
Danny Al-Gaaf
9acda37d5f build.py: add cast to be able to use str.splitlines()
Cast some variables  to str() to be able to use str.splitlines().

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-26 20:25:44 +02:00
Danny Al-Gaaf
e6f8a1a7b3 cmdln.py: fix "More than one statement on a single line"
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-26 15:27:05 +02:00
Danny Al-Gaaf
f0a92430e8 cmdln.py: fix bad indentation
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-26 11:24:17 +02:00
Marcus Huewe
cdd73ba983 - fetch.OscFileGrabber: fix for commit 9ab5a37113
We still have to support older urlgrabber versions where the class
"URLGrabber" is an old-style class and therefore we cannot use a "super(...)"
call. This fixes issue #32
2013-05-23 15:04:20 +02:00
eea716f11f - support listing of deleted source files "ls -D $PROJECT $PACKAGE" 2013-05-17 10:37:51 +02:00
Gui Chen
9ab5a37113 fix OscFileGrabber missing 'opts' attribute issue
given urlgrabber version 3.9.1, MirrorGroup trys to access
grabber.opts, but the derived grabber OscFileGrabber hasn't
this attribute

Signed-off-by: Gui Chen <gui.chen@intel.com>
2013-05-14 10:16:10 +02:00
Andreas Schwab
ae2f9515ef Fix examples in link_template 2013-05-10 20:57:03 +02:00
Michal Čihař
f2a1bde695 Fix typo in help 2013-05-07 09:29:59 +02:00
954c2fc2b2 - fix request ... --or-revoke command for automated request accept/revoking 2013-05-06 18:45:51 +02:00
Marcus Huewe
41661d741a - babysitter: print out headers in case of status 5XX 2013-05-02 22:33:04 +02:00
Marcus Huewe
69150040c2 - do_submitrequest: --diff is not supported in a project working copy
This (partly) fixes issue #29.
2013-05-02 22:18:14 +02:00
Marcus Huewe
5e0ef46aed - fixed issue #28 ("calling with -H option causes traceback") 2013-05-02 14:55:31 +02:00
90d51da3d2 - add --message option for creating set_bugowner requests 2013-05-02 11:38:53 +02:00
71c40acc51 - fix using --set-bugowner-request on explicit specified containers 2013-05-02 11:08:27 +02:00
69e6e586c7 - fix print syntax 2013-05-02 11:05:48 +02:00
ce998fbc29 - fix spelling typo 2013-05-02 10:57:15 +02:00
a8f14bed60 - allow to set bugowner/maintainership for a given binary 2013-05-02 10:50:05 +02:00
Marcus Huewe
cdc1245960 - pass a str to exec() instead of an open file object
An open file object isn't supported anymore by python3.
This fixes issue #26.
2013-04-30 17:44:38 +02:00
Marcus Huewe
0c0ffe50fb - Serviceinfo.execute: always cleanup (remove) tmpdir
This fixes issue #24.
2013-04-26 20:44:53 +02:00
9595aa9f09 - show also groups in maintainer/bugowner search 2013-04-22 17:09:33 +02:00
Marcus Huewe
a8def0f433 - build: fixed typo (patch by darix)
typo was introduced in commit d3648be24b
2013-04-22 16:26:31 +02:00
Marcus Huewe
51e6fca88f - fetch: check if errno == 14 before accessing the URLGrabError's code attribute
Unfortunately the class URLGrabError does not define constants for the
different error codes therefore we have to hardcode the errno (alternatively
we can define them in our fetch module).
2013-04-22 15:54:55 +02:00
Marcus Huewe
5a8baf9b88 - util.ar: do not import StringIO from the cStringIO module
The class ArFile inherits from StringIO but StringIO from cStringIO
is just a function (this got broken by commit 87d354e1a0).
2013-04-22 09:24:48 +02:00
Marcus Huewe
439dafbdc5 - ServiceInfo.execute: fixed NameError 2013-04-22 09:17:38 +02:00
Marcus Huewe
d28cddfede - use a buffer instead of a memoryview if python version < 2.7
(forgot to remove this code in commit 034d2e4746)
2013-04-18 15:04:58 +02:00
Marcus Huewe
034d2e4746 - http_request: do not use a memoryview for python27
python27's mmap does not behave like a bytearray therefore we
cannot directly pass it to the memoryview.
2013-04-18 14:19:45 +02:00
2b06180efa - anotehr python3 syntax fix 2013-04-16 15:57:30 +02:00