1
0
mirror of https://github.com/openSUSE/osc.git synced 2024-09-20 17:26:15 +02:00
Commit Graph

3470 Commits

Author SHA1 Message Date
Andreas Schwab
ce63cd3e18 Properly parse error message in metafile.edit 2019-05-29 12:27:40 +02:00
Marco Strigl
d5c91d6a73
Merge pull request #568 from MaximilianMeister/fetch
cast bytes object to string during os.path.join
2019-05-28 13:36:06 +02:00
Maximilian Meister
1c825ec8b6
cast bytes object to string during os.path.join
this makes sure not to mix objects to prevent a TypeError

TypeError: Can't mix strings and bytes in path components

Fixes#567

Signed-off-by: Maximilian Meister <mmeister@suse.de>
2019-05-28 13:29:12 +02:00
Marco Strigl
497cb3af60
Merge pull request #512 from adrianschroeter/triggers
support different token operations (runservice, release and rebuild) …
2019-05-28 13:05:13 +02:00
6eac27ec1c support different token operations (runservice, release and rebuild) (requires OBS 2.10) 2019-05-27 14:50:34 +02:00
Stefan Knorr
4c16177ada Random drive-by typo fixes for osc command-line messages 2019-05-27 11:54:42 +02:00
Marcus Huewe
cf96f85590 Merge branch 'master' of https://github.com/sknorr/osc
Improve grammar in check_existing_requests and
check_existing_maintenance_requests.
2019-05-25 23:44:44 +02:00
Marcus Huewe
f1100d2a45 Merge branch 'master' of https://github.com/bmwiedemann/osc
Fix opts.define codepath in the build module (missing encode).
2019-05-25 23:36:31 +02:00
Marcus Huewe
0c9c616bd8 Merge branch 'master' of https://github.com/andreas-schwab/osc
Decode data in do_token before printing it.
2019-05-25 23:14:41 +02:00
Marcus Huewe
c4dd37936f Merge branch 'fix_offline_mode_for_build' of https://github.com/lethliel/osc
Do not make a http request if noinit is True in parse_repoarchdescr.
2019-05-25 23:10:49 +02:00
Bernhard M. Wiedemann
13a174bdcc Fix encode method call
This broke with
--define="%_buildhost foo"
2019-05-25 13:36:10 +02:00
Stefan Knorr
b14c9cfd92 Add "prioritize" as (preferred) alias for "priorize" command
"priorize" is not an English word, "prioritize" is the correct
version:
* https://www.merriam-webster.com/dictionary/priorize
* https://www.merriam-webster.com/dictionary/prioritize

The "priorize" command will continue to exist after this commit, but the
documented  version will be "prioritize".
2019-05-24 13:22:30 +02:00
Andreas Schwab
7ed9ff32ad osc token: decode data from trigger url 2019-05-23 09:53:05 +02:00
lethliel
178dfd16c3 fix offline build mode
The offline mode does not really work offline since
parse_repoarchdescr() uses get_buildconfig to store the
buildconfig in a temporary file.

Solution:

Use the same logic as in build.py. If in offline mode(noinit = True)
try to use the local _buildconfig file. If not in offline mode just
download the buildconfig from the server via get_buildconfig
2019-05-22 13:58:46 +02:00
Marco Strigl
c4979dcde2
Merge pull request #562 from lethliel/fix_status_outupt_of_attribute_deletion
[python3] fix outupt of status on attribute deletion
2019-05-22 13:08:43 +02:00
lethliel
1ab68d3bfb open 0.165.2 development 2019-05-22 13:00:55 +02:00
lethliel
260d5f585a fix outupt of status on attribute deletion
On osc meta attribute --attribue <name> --delete the returned
data is encoded. Therefore the sys.stdout.write(data) call fails.

Solution: Decode data

--> sys.stdout.write(decode_it(data))
2019-05-22 12:57:02 +02:00
lethliel
8b56405d10 release 0.165.1 2019-05-20 08:35:27 +02:00
Marcus Huewe
6fe6dbc724 Merge branch 'fix_broken_caller_logic_for_getbinaries' of https://github.com/lethliel/osc
Fix "--quiet" option in do_getbinaries.
2019-05-16 16:45:14 +02:00
lethliel
860548bc30 fix getbinaries in commandline (progress_meter)
change progress_meter = opts.quiet to
progress_meter = not opts.quiet
2019-05-16 15:21:16 +02:00
lethliel
5bd5fdb22c Revert "fix getbinaries quiet logic"
This reverts commit 82ac5f6f06.
2019-05-16 09:31:38 +02:00
Marco Strigl
8c14208ad0
Merge pull request #555 from lethliel/fix_get_binaries_quiet_logic
fix getbinaries quiet logic
2019-05-15 17:29:16 +02:00
lethliel
82ac5f6f06 fix getbinaries quiet logic
opts.quiet is passed to get_binary_file which is False by default.
So the following if progress_meter is always False unless -q is given.

So it needs to be if not progress_meter.
2019-05-15 17:22:51 +02:00
lethliel
877d5e50b6 fix triggerreason on empty packages.
When running osc triggerreason on newly created (empty) packages
the command failes with AttributeError: 'NoneType' object has no attribute 'text'
because root.find('explain') is NoneType.

Solution:

Check if root.find('explain') is None and print "No triggerreaseon found".
In this case also do not try to get the triggertime. It will result in the same error.
2019-05-15 11:45:20 +02:00
Stefan Knorr
84c8019383 Improve grammar of request supersede message 2019-05-14 20:05:38 +02:00
Marco Strigl
3266e43164
Merge pull request #551 from lethliel/python3_fix_add_directory
[python3] fix adding dirs as compressed archive
2019-05-14 15:23:52 +02:00
lethliel
597eadf2f4 fix adding dirs as compressed archive
The content in the todo dict are strings. In python3 the communicate
method expects a bytes-like object not a string.

Solution: Encode every element in todo to a new dict (enc_todo) and
pass this instead of todo
2019-05-14 10:24:17 +02:00
Marco Strigl
53d3cc7bb5
Merge pull request #550 from lethliel/python3_fix_get_commitlog
fix get_commitlog to decode correct.
2019-05-14 10:08:16 +02:00
lethliel
03777b7e4d fix get_commitlog to decode correct.
get_commitlog mixes bytes and strings when the output is
xml or csv.

This is fixed by decoding the commit message before replacing chars.
2019-05-14 10:01:02 +02:00
Marco Strigl
c5139fdff8
Merge pull request #538 from lethliel/fix_unimported_urldefrag
Import urldefrag function
2019-04-26 12:14:15 +02:00
lethliel
9aba391a11 Import urldefrag function
The function was not imported and so osc crashed when executed behind a proxy
2019-04-26 10:49:03 +02:00
Marco Strigl
c1c72645ad
Merge pull request #537 from dirkmueller/master
[python3] release command: fix exception on missing bytearray/str decode
2019-04-26 10:02:01 +02:00
3886b95ae4 [python3] release command: fix exception on missing bytearray/str decode 2019-04-25 22:28:19 +02:00
Marcus Huewe
a3de1bdad1 Merge branch 'master' of https://github.com/lnussel/osc
Remove group elements during copy_pac, link_pac, aggregate_pac.
2019-04-24 20:11:50 +02:00
lethliel
1dc836f48c open 0.166 development 2019-04-18 14:30:14 +02:00
lethliel
baf80268b7 release 0.165.0 2019-04-18 14:27:42 +02:00
Ludwig Nussel
9d4f584aeb Also remove groups on copypac 2019-04-17 11:42:29 +02:00
Marco Strigl
1ad7f4607d
Merge pull request #531 from lethliel/fix_addGitSource_issue_507
[python3] fix decoding in addGitSource
2019-04-16 17:00:16 +02:00
lethliel
0d55ddc1b3 [python3] fix decoding in addGitSource
open the file with mode 'w' instead of 'wb'. The 'b' is not needed.
Neither in python2 nor in python3.

Fixes github issue https://github.com/openSUSE/osc/issues/507
2019-04-16 16:55:06 +02:00
Marco Strigl
393290bfe5
Merge pull request #528 from lethliel/python3_fix_bsc1129889
[python3] add exception if encoding fails and try ISO-8859-1
2019-04-16 15:49:29 +02:00
Marco Strigl
fc8e6f8695
Merge pull request #529 from lethliel/python3_fix_bsc1131512
[python3] return value when adding attrs is bytes
2019-04-16 15:41:10 +02:00
Marco Strigl
202c50be3e
Merge pull request #530 from lethliel/fix_search_sorting_bsc1129757
[python3] fix sorting when using osc se
2019-04-16 15:38:40 +02:00
lethliel
d10c9b4cea [python3] fix sorting when using osc se
osc se did not sort the output anymore. The logic
in the existing results.sort(key=...) was wrong. Now it is using
key=itemgetter(0,1) has two columns and key=itemgetter(0) if there
is only one column.
2019-04-16 15:18:04 +02:00
lethliel
b7dea9ddcd [python3] return value when adding attrs is bytes
When adding attribute with osc meta attribute <prj> -a <attr> -s '<val>'
the api call gets executed successfull but the return value needs to be
decoded to print it correctly.
2019-04-16 14:57:19 +02:00
lethliel
5841bf759f add exception if encoding fails and try ISO-8859-1
In some rare cases the chardet encoding detection detects
a wrong encoding standard. Then we switch to latin-1 which
covers most if utf-8 does not work.
2019-04-16 14:40:13 +02:00
Marco Strigl
1fb2048476
Merge pull request #525 from lethliel/python3_activate_travis_tests
[python3] reactivate python3.x tests
2019-04-15 15:20:04 +02:00
Marco Strigl
71770555ac
Merge pull request #526 from lethliel/python3_fix_debquery_decoding
[python3] fix decoding issue in debquery.py
2019-04-15 15:10:21 +02:00
Marco Strigl
6c074fce20
Merge pull request #524 from lethliel/python3_packagequery_fix_decoding
[python3] fix decoding for packageqeury.py
2019-04-15 15:09:59 +02:00
Marco Strigl
6220711a5e
Merge pull request #523 from lethliel/python3_fetch_module
[python3] fetch.py python3 ready
2019-04-15 15:09:43 +02:00
Marco Strigl
2693d24a0a
Merge branch 'master' into python3_fetch_module 2019-04-15 15:09:31 +02:00