Home Home > Build-service
Sign up | Login

Deprecation notice: openSUSE Lizards user blog platform is deprecated, and will remain read only for the time being. Learn more...

Archive for the ‘Build Service’ Category

[gsoc] osc code cleanup – summary of week 4

June 19th, 2011 by

Hi,

here’s a small summary of the 4th (coding) week. I spent most of the
time with writing the RemoteFile classes and the BuildResult class
(+ testcases of course:) ).

TODO for this week:

  • improve RemoteFile classes
  • add APIInfo class:
    – resolve url-like parameters (api://foo/bar repo/arch)
    – raise an exception if required parameters are missing
    – initialize optional parameters with the config default
    – encapsulate “context-sensitivity” logic (sometimes parameters
    should be read from the working copy (like apiurl, project or
    package))

Marcus

[gsoc] summary of week 3

June 10th, 2011 by

Hi,

here’s a small summary of the 3rd (coding) week. This week I spent
most of my time with developing the remote model classes. The goal
was to put most of the code into a base class from which all remote
models will be derived (if you’re interested how it works have a
look at it). So far we have classes for:

  • a remote project (RemoteProject – manages project metadata)
  • a remote package (RemotePackage – manages package metadata)
  • a request (Request)

TODO for this week:

  • add exception handling to the httprequest.py module
  • add a RemoteFile class which can be used to access a remote file
    like a buildlog, prjconf or a source file
  • add a BuildResult class:
    – get the build results for a project or package
    – get the buildlog of a package
    – get the binary/binaries from the api

[gsoc] summary of week 2

June 3rd, 2011 by

Hi,

here’s a small summary of the 2nd (coding) week. This
week I spent most of my time with working on an OO-style class
for doing http requests:

  • it’s possible to switch the http(s) implementation without touching any
    library code
  • supports response validation (if a schema was specified for the request)

Currently I’m still working on the “remote models”:

  • decided to use lxml.objectify:
  • – goal is to encapsulate the xml logic solely into the object itself
  • – example workflow:
    prj = RemoteProject(‘some_name’)
    prj.title = ‘dummy’
    prj.description = ‘foo bar’
    repo = prj.add_repository(name=’openSUSE_Factory’)
    repo.add_path(project=’openSUSE:Factory’, repository=’standard’)
    repo.add_arch(‘i586’)
    # change arch to x86_64
    repo.arch[0] = ‘x86_64’
    repo.save()

Minor stuff:

  • decided to use the “logging” module:
    this way we can easily add “debug” and “info” etc. messages and it’s up to
    the “client” which messages it wants to display (I’m not talking about
    the messages which are displayed when “osc up” is called or something like
    that)

Kraft 0.43 Release

May 26th, 2011 by

Kraft helps in the officeYesterday I did a new release of Kraft, the KDE application to create and manage business documents in the small enterprise. It is version 0.43, the former one was 0.42, release in april 2011. Both releases, where the latter is a kind of maintenance release of the first are the result of a comparable high development effort of the underlying code in catalog handling and document lists in Kraft.

The document lists consisting of a latest, complete and time sorted view are now fully based on one Qt interview model feeding the views. That was a step because the original code was based on Qt3’s treewidget code. The result is convincing: the time needed to build up all views with a couple of thousand documents went down from around 20 seconds with the old implementation (which of course was not optimized) to almost nothing now. A nice result.

The catalog management got also a fundamental change, it can handle an arbitrary depth of catalog chapters now instead of only one. That makes a catalog chapter hirarchie in which templates can be moved around by drag and drop. Complete sub chapters can now be moved now from the catalog to the document quickly to speed up the assembly of documents covering standard workflows. Moreover this change in the underlying catalog data structure was an important prerequisite to implement reading of standard catalog formats such as DATANORM in later releases.

Krafts development is still going slowly, but steadily. There are quite some ideas on how to move on with Kraft:

  • Kraft Mobile – spin off a mobile app working on the new form factors providing useful functionality
  • support for DATANORM and friends, which would allow reading standard template catalogs provided by suppliers.
  • Alkimia support which would head into accounting functionality together with the other KDE financial applications
  • continue on shared Kraft, which utilizes the Owncloud project as a document and catalog sharing platform
  • support sub documents and more structured documents in Kraft
  • more project management capabilities in Kraft

All of these ideas are interesting and quite some work. I haven’t decided yet. If you think you want to influence Krafts future, let me know your arguments, most preferably on the Kraft mailinglist. If you even feel like you want to work on an interesting KDE application, please let me know, I’d be happy to share everything 🙂

GSoC – new osc user interface proposal

May 23rd, 2011 by

Hi,

as a part of our Google Summer of Code Project to cleanup osc our
first task was to define a new commandline user interface for osc.
The current user interface is quite “inconsistent” (with regard to
the expected arguments for different commands) and has some other
“flaws”.
Here are some examples to show some flaws of the current user
interface:

* inconsistent ui:
– osc results project package –repo repo –arch arch
– osc rebuild project package repo arch
– osc build repo arch
– osc ls project package repo arch -b
– osc ls project package -r repo -a arch -b
– osc undelete project package_1 … package_N
– osc rdelete project package_1

* counterintuitive commands:
– osc abortbuild project package
– osc abortbuild project package repo arch
– osc abortbuild (in a package working copy)
– osc abortbuild –repo repo –arch arch (in a package working copy)
– osc abortbuild repo arch (in a package working copy)
=> treats “repo” “arch” as “project” “package”

* “duplicated” commands:
– diff, rdiff
– buildlog, remotebuildlog, localbuildlog
– delete, rdelete, rremove

Additionally we support lots of commands and the output of
“osc –help”is quite long. In order to tackle this problem we decided
to introduce “groups” with subcommands, for instance:
attribute list
attribute create…
attribute set…

As a result we get rid of “god commands” (commands which supported
lots of different options for different things (like osc meta)) and
the new commands are easier to use because they support less arguments
and/or options (note: this doesn’t mean we lose functionality – the
functionality is just moved to another command/command group).

The attached table is just a _proposal_ for a new commandline user
interface.

Some additional explanations:

The biggest change with regard to our current user interface is the
introduction of an url-like syntax:
For example:
osc ls api://project/package
instead of
osc ls project package

In this case “api” means that the request is issued to the default
apiurl (in most cases https://api.opensuse.org) which can be
configured in the ~/.oscrc.
To issue the “list” request to a different obs instance one can use:
osc ls https://api.somehost/project/package
or
osc ls alias://project/package
“alias” is an alias for this apiurl which can be configured in the
~/.oscrc.

If you see this url-like syntax for the first time you might think
that it makes things much more complicated (and even more to type)
but it is advantageous:

– in most cases it is obvious if a command is a remote command or
local working copy command
– this way we get rid of ambiguities:
Suppose we support the following command (“<foo>” indicate that
“foo” is an optional argument):
binaries get api://project/package <repo/arch>
binaries get <repo/arch>
(if $PWD is a package working copy
the project and package arguments will be read from it)

Possible invocations are:
osc binaries get api://foo/bar standard/i586 # get all binaries
for this repo and arch
osc binaries get api://foo/bar # get all binaries for all repos
and all arches

# now suppose $PWD is a package working copy:
osc binaries get standard/i586 # get all binaries for this repo
and arch (project and package are read from the working copy)

osc binaries get api://foo/bar # gets all binaries for all repos
and all arches (project is “foo” and package is “bar”)

In the latter invocation we’re still in a package working copy
but ignore it and use the project and package arguments which
were specified.

Note: in this case a special (like the url-like) syntax is required
otherwise osc is unable to distinguish between a project/package and
repo/arch argument.

Once again this is just a _proposal_ – feedback is very welcome!
(please send the feedback to the opensuse-buildservice@opensuse.org mailinglist – thread)

Marcus

init, list, meta, attribute, request, submitrequest, review, link, copy, maintenance, branch, delete, undelete, diff, checkout, status, add, addremove, commit, update, resolved, distributions, results, buildlog, buildmeta, build, chroot, log, service, abortbuild, rebuild, binaries, search, my,
importsrcpkg, person, cat, less, repair, pull, signkey, vc, mv, config, revert, api, aggregate, mkpac, setlinkrev, linktobranch, detachbranch

setlinkrev, linktobranch and detachbranch might be grouped into group “other”.
Deleted commands:

cmd replacement reason
deleterequest args request create –delete args
reqeuestmaintainership args request create –role maintainer args
changedevelrequest args request create –changedevel args
request approvenew project <package> request –interactive-review could be used (but it’s no real replacement)
request log id request show id –log
linkpac link
copypac copy
releaserequest maintenance releaserequest
createincident maintenance createincident
maintenancerequest maintenance request
mbranch maintenance branch
getpac use branch
rdelete delete
updatepacmetafromspec
rdiff diff
linkdiff no replacement atm (current implementation partly broken); diff could support it
repourls isn’t needed IMHO
prjresults results
remotebuildlog buildlog
localbuildlog buildlog –local
buildinfo buildmeta info
buildconfig buildmeta config
triggerreason buildmeta triggerreason
dependson buildmeta dependson
buildhistory buildmeta history
jobhistory buildmeta jobhistory
info not needed anymore
getbinaries binaries get
wipebinaries binaries wipe
list –binaries binaries list
search –binary binaries search
bugowner no real replacement use person maintainer -b (if we support this)
maintainer person maintainer
maintainer project –add user –role role person add api://project role user
maintainer project –delete user person delete api://project user
whois person meta
meta user person meta
cat/less http://api/source/project/package/file not needed (IMHO)
repairlink repair link
repairwc repair wc
signkey signkey it’s not context-sensitive anymore
rremove do we really need this?
aggregatepac aggregate
develproject meta meta should display the xml in a nice way so that it’s easy to see whether a develprj is defined or not
repositories meta meta should display the xml in a nice way so that all repos are displayed

new commandline user interface

init

cmd subcmd prj wc pkg wc params/opts note
init api://project
init api://project/package

list

cmd subcmd prj wc pkg wc params/opts note
ls x list all remote packages for the wc project
ls x list all remote files for the wc package
ls api://
ls api://project
ls api://project/package
ls api://project/package/file just for backward compatibility

meta

cmd subcmd prj wc pkg wc params/opts note
meta x shows/edits project meta
meta x shows/edits package meta
meta api://project
meta api://project/package
meta api://project/_prjconf

attribute

cmd subcmd prj wc pkg wc params/opts note
attribute is not context sensitive
attribute list api://project show all attributes
attribute list api://project attribute show specific attribute
attribute set api://project attribute newval set attribute to newval
attribute create api://project attribute create new attribute
attribute delete api://project attribute delete attribute
attribute list api://project/package show all attributes
attribute list api://project/package/binary show all attributes – /binary works for all commands below, too
attribute list api://project/package attribute show specific attribute
attribute set api://project/package attribute newval set attribute to newval
attribute create api://project/package attribute create new attribute
attribute delete api://project/package attribute delete attribute

request

cmd subcmd prj wc pkg wc params/opts note
request is not context sensitive
request create –submit api://project/package api://tgt_projet/<package>
request create –submit api://project/package api://tgt_projet/<package>
request create –changedevel api://project/package api://tgt_projet/<package>
request create –role role user api://project/<package>
request create –grouprole role group api://project/<package>
request create –bugowner user api://project/<package> alternatively we treat bugowner as a “role” and use –role bugowner…
request create –delete api://project/<package>
request list api://<project>/<package> list all/project/package requests
in the following we support both: “api://id” and “id” (if the latter format is specified the default apiurl is used – regardless if the cmd is executed in a wc)
request show api://id apart from –brief also support –log which just shows the statehistory + current state
request supersede api://id api://supersede_id
request accept api://id
request decline api://id
request revoke api://id
request reopen api://id
request wipe api://id
request checkout (x) api://id if the package’s package belongs to the wc’s project the package will be added to this project (if it already exists an error will be printed)

submitrequest

cmd subcmd prj wc pkg wc params/opts note
submitrequest x semantic change: creates a sr for all local packages (instead of all remote)
submitrequest x wc has to be a source link
submitrequest x api://tgt_project/<tgt_package>
submitrequest api://project/package api://tgt_project/<tgt_package>

review

cmd subcmd prj wc pkg wc params/opts note
review accept api://id
review decline api://id
review reopen api://id
review susersede api://id api://supsersede_id
review add api://id –user user –group group –package package –project project at least one option is required
review list api://<project>/<package> just for convenience; “request list –state review” should lead to the same result

link

cmd subcmd prj wc pkg wc params/opts note
link api://link_project api://project
link api://link_project/link_package api://project/&tl;package>

copy

cmd subcmd prj wc pkg wc params/opts note
copy api://copy_project api://project could be supported
copy api://copy_project/copy_package api://project/&tl;package>

maintenance

cmd subcmd prj wc pkg wc params/opts note
maintenance releaserequest x
maintenance releaserequest api://project
maintenance createincident <api://project>
maintenance request api://project <api://tgt_project>
maintenance branch package <tgt_project> XXX: this voilates the url schema

branch

cmd subcmd prj wc pkg wc params/opts note
branch api://project/package <api://tgt_project/tgt_package>

undelete

cmd subcmd prj wc pkg wc params/opts note
undelete api://project/<package>

delete

cmd subcmd prj wc pkg wc params/opts note
delete api://project/<package> multiple arguments can be specified
delete /path/to/package
delete /path/to/file

diff

cmd subcmd prj wc pkg wc params/opts note
diff x
diff x
diff /path/to/file multiple args are supported
diff /path/to/package
diff /path/to/project
diff api://project/package
diff api://project/package api://original_project/original_package

checkout

cmd subcmd prj wc pkg wc params/opts note
checkout api://project/<package> checking out a file is not supported anymore
checkout x package adds the package to the wc
checkout x package adds the package to the wc

status

cmd subcmd prj wc pkg wc params/opts note
status x
status x
status /path/to/project_or_package_or_file multiple arguments are supported

add

cmd subcmd prj wc pkg wc params/opts note
add /path/to/dir_or_file multiple arguments are supported
add URL create a _service file

addremove

cmd subcmd prj wc pkg wc params/opts note
addremove x
addremove x
addremove /path/to/package multiple arguments are supported

commit

cmd subcmd prj wc pkg wc params/opts note
commit x
commit x
commit /path/to/project_or_package_or_file multiple arguments are supported

update

cmd subcmd prj wc pkg wc params/opts note
update x
update x
update /path/to/project_or_package multiple arguments are supported

resolved

cmd subcmd prj wc pkg wc params/opts note
resolved /path/to/file multiple arguments are supported

distributions

cmd subcmd prj wc pkg wc params/opts note
distributions api://

results

cmd subcmd prj wc pkg wc params/opts note
results x
results x
results api://project/<package>

buildlog
if repo/arch is not specified the config values will be used (default_repo, default_arch)

cmd subcmd prj wc pkg wc params/opts note
buildlog x <repo/arch>
buildlog x <repo/arch> –local
buildlog api://project/package <repo/arch>

buildmeta
if repo/arch is not specified the config values will be used (default_repo, default_arch)

cmd subcmd prj wc pkg wc params/opts note
buildmeta info x <repo/arch> <build_descr> distingiush between repo/arch build_descr, /arch build_descr via the file extension of build_descr
buildmeta info api://project/package <repo/arch> <build_descr> distingiush between repo/arch build_descr, /arch build_descr via the file extension of build_descr
buildmeta config x <repo/arch> <build_descr>
buildmeta config api://project/package <repo>
buildmeta triggerreason x <repo/arch>
buildmeta triggerreason api://project/package <repo/arch>
buildmeta dependson x <repo/arch>
buildmeta dependson api://project/package <repo/arch>
buildmeta log x <repo/arch> same as buildlog (just for consistency)
buildmeta log x <repo/arch> –local same as buildlog (just for consistency)
buildmeta log api://project/package <repo/arch> same as buildlog (just for consistency)
buildmeta history x <repo/arch>
buildmeta history api://project/package <repo/arch>
buildmeta jobhistory x <repo/arch>
buildmeta jobhistory x <repo/arch>
buildmeta jobhistory api://project/<package> <repo/arch>

build
if repo/arch is not specified the config values will be used (default_repo, default_arch)

cmd subcmd prj wc pkg wc params/opts note
build x <repo/arch> <build_descr>

chroot
if repo/arch is not specified the config values will be used (default_repo, default_arch)

cmd subcmd prj wc pkg wc params/opts note
chroot x <repo/arch> <build_descr> build_descr is not needed for the command itself

log

cmd subcmd prj wc pkg wc params/opts note
log x
log x
log api://project/<package>

service

cmd subcmd prj wc pkg wc params/opts note
service run x <service_name>
service disabledrun x
service remoterun api://project/package

abortbuild
if repo/arch is not specified the config values will be used (default_repo, default_arch)

cmd subcmd prj wc pkg wc params/opts note
abortbuild x <repo/arch> to abort all builds specifiy –all
abortbuild x <repo/arch> to abort all builds specifiy –all
abortbuild api://project/<package> <repo/arch> to abort all builds specifiy –all

rebuild
if repo/arch is not specified the config values will be used (default_repo, default_arch)

cmd subcmd prj wc pkg wc params/opts note
rebuild x <repo/arch> to rebuild all packages specifiy –all
rebuild x <repo/arch> to rebuild all packages specifiy –all
rebuild api://project/<package> <repo/arch> to rebuild all packages specifiy –all

rebuild
if repo/arch is not specified the config values will be used (default_repo, default_arch)

cmd subcmd prj wc pkg wc params/opts note
binaries get x <repo/arch> to get all binaries specifiy –all
binaries get x <repo/arch> to get all binaries specifiy –all
binaries get api://project/<package> <repo/arch> to get all binaries specifiy –all
binaries list x <repo/arch> to list all binaries specifiy –all
binaries list x <repo/arch> to list all binaries specifiy –all
binaries list api://project/<package> <repo/arch> to list all binaries specifiy –all
binaries wipe x <repo/arch> to wipe all binaries specifiy –all
binaries search api://<project> search_term
binaries wipe api://project/<package> <repo/arch> to wipe all binaries specifiy –all

my

cmd subcmd prj wc pkg wc params/opts note
my requests
my submitrequests
my projects
my packages

search

cmd subcmd prj wc pkg wc params/opts note
search search_term

importsrcpkg

cmd subcmd prj wc pkg wc params/opts note
importsrcpkg x /path/to/srpm

person
For groups we can add a new “group” command

cmd subcmd prj wc pkg wc params/opts note
person meta api://username <–edit>
person maintainer api://project/<package> show maintainer of the project/package
person maintainer api://project/<package> show maintainer of the project/package
person add api://project/<package> user role
person delete api://project/<package> user <role>

cat

cmd subcmd prj wc pkg wc params/opts note
cat api://project/package/file

less

cmd subcmd prj wc pkg wc params/opts note
cat api://project/package/file

repair

cmd subcmd prj wc pkg wc params/opts note
repair link x
repair link api://project/package <api://into_project/<into_package>>
repair wc x
repair wc x

pull

cmd subcmd prj wc pkg wc params/opts note
pull x

signkey

cmd subcmd prj wc pkg wc params/opts note
signkey api://project

vc

cmd subcmd prj wc pkg wc params/opts note
vc

mv

cmd subcmd prj wc pkg wc params/opts note
mv x filename new_filename should we support this for packages, too?

config

cmd subcmd prj wc pkg wc params/opts note
config section option
config section option value

revert

cmd subcmd prj wc pkg wc params/opts note
revert x
revert /path/to/file multiple arguments are supported

api

cmd subcmd prj wc pkg wc params/opts note
api api://path/to/something

aggregate

cmd subcmd prj wc pkg wc params/opts note
aggregate api://project/package api://tgt_project/<tgt_packge>

mkpac

cmd subcmd prj wc pkg wc params/opts note
mkpac x package_name

setlinkrev

cmd subcmd prj wc pkg wc params/opts note
setlinkrev x
setlinkrev api://project/<package>

linktobranch

cmd subcmd prj wc pkg wc params/opts note
linktobranch x
linktobranch api://project/package

detachbranch

cmd subcmd prj wc pkg wc params/opts note
detachbranch x
detachbranch api://project/package

(please send the feedback to the opensuse-buildservice@opensuse.org mailinglist – thread)

Unity 2D to enter GNOME:Ayatana soon…

May 19th, 2011 by

In the past days I’ve been packaging and fixing some issues on Unity 2D for inclusion on the GNOME:Ayatana repository in the openSUSE Build Service.

This gave me an excellent opportunity to test a few components share by both, Unity and Unity 2D, which is the case of ‘unity-place-applications’ and ‘unity-place-files’, both using Zeitgeist which is already in Factory for the upcoming openSUSE 12.1. We thank the integration of this packages to Federico Quintero. Thanks Fred.

A few more additional packages need some care and once they get updated and tested they will be uploaded to GNOME:Ayatana, at which time I will provide an installer (1-Click) for those willing to test Unity-2D. Unity 2D will be the first application to use the indicators I have prepared in the past which all all found working, except 1, the AppMenu (strangely it works on GNOME2 panel without issues).

This is how Unity 2D looks like. There are transparencies because I enabled ‘composite’ on metacity, which works very nicely. As far as I could understand, the developers of Unity 2D are also looking into implementing Compiz with Unity 2D, which would be sweet.

Unity introduces the ‘dash’ which is pretty much the following screen. Transparencies are enabled (though metacity composite) and the notification bubble belongs to NotifyOSD (already present in openSUSE 11.4 as optional). This is one of the three issues I have to fix, the icons displayed on the dash should have text underneath, it’s not showing. The top icons are quick links to Program Categories and the ones bellow are the default applications which are setup in GNOME.

The launcher panel on the side auto-hides, and seems to be working. The three icons displayed in last are respectively: Workspace selector, applications menu and files. Everything seems to be working with them, and the 2 last are components shared with Unity, and they both rely on Zeitgeist. Here’s a few captures of what they do…

There’s also a feature from Unity which is cute… The title artifact of the decorator window (metacity, which required a few patches) is removed and implemented on the top bar when the window is maximized. Sadly for me the AppMenu (menu proxy) isn’t working properly, this is another thing that needs fixing…

This should cover pretty much the functionality that is available currently. There’s a few issues still remaining before I can push this to GNOME:Ayatana:

– I tried not to have the need to patch gnome-session, but since Unity relies on the Session Indicator to have this functionality, gnome-session will need to be patched (should be ok, because it also requires the backport patch for  defining –sessions for openSUSE 11.4).

– Unity 2D itself relies on a few gconf hacks that should be on a schema file. I’ve talked to upstream and this is planned already, so once it’s release, that’s when it will be published.

– There’s one issue also with backgrounds and workspace switcher… unfortunatly the workspace switcher only renders wallpapers if they are in image format (no .xml stuff), so this can turn some wallpapers not to render, which eventually ends up in the background of the switcher being the one defined in GNOME as solid color.

So the order of TODO’s for GNOME:Ayatana is pretty much this one:

1. Implement dependencies and then Unity 2D;
2. Make sure Compiz is well implemented, because Unity will require Compiz at it’s best shape;
3. Make sure nux and other twisted dependencies are properly implemented;
4. Implement Unity itself;

This are the latest news for GNOME:Ayatana…

Unknown Horizons, a nice strategy game, now on openSUSE

May 9th, 2011 by

A few days ago I was wandering on the openSUSE Forums, once more in the games section when I saw one more post from one of our users asking for Unknown Horizons… I’ve search a bit and found 2 entries on OBS (openSUSE Build Service), one for Fedora packages and another for openSUSE packages.

I’ve joined #unknown-horizons on FreeNode and found out that Unknown Horizons is very active and people are very nice. I’ve made a few questions around and offered myself to package this nice game for openSUSE (home:ketheriel:UnknownHorizons). Some of the dependencies are provided by the games repository, to which I want to submit the major releases, and if possible enable builds for Fedora (and friends).

A few packages need some tweaks to enable builds for Fedora (allegro, libenet, guichan), and I’m working already on that. Meanwhile for everyone who wants to check out the latest development snapshot of Unknown Horizons, feel free to do so… Currently packaged for:

* openSUSE 11.3
* openSUSE 11.4
* openSUSE Factory
* openSUSE Tumbleweed

The 1-Click installer can be found on Unknown Horizons download page.  There’s also a nice article (bumping ego) about the new openSUSE packages on Unknown Horizons webpage!

This is a title that all openSUSE users who like RTS games should try (supports openGL and sdl) and is powered by the FIFE Engine.

Unknown Horizons - Settings Menu - openSUSE 11.4 GNOME3

Where our bugzilla needs improvement

April 15th, 2011 by

update 2012-02-07: Success: after bnc#732504 you can now open Advanced Search and find RESOLVED/DUPLICATE bugs by default. When bugs are finally solved and fixes released, those can then be moved to CLOSED state to no more appear in search results.

 

bugzilla.novell.com aka bnc is the central tool to track bugs of openSUSE.

It has a guided bug submission form that helps & encourages reporters to search for existing reports on an issue.

However, the integrated search function only shows open bugs. In principle that is nice, but bugs marked as duplicates of open bugs do not count as open. Also it is common that developers mark a bug as RESOLVED/FIXED as soon as they uploaded a patch into the OBS devel-project. Such a patch then needs some days until it gets into Factory or the Update repos where normal users would benefit from the fix. During that time, there will still be people with all regular updates installed hitting the bug and not finding it on bugzilla because it is no more marked open. Of course, one could also search for RESOLVED bugs, but this brings up a huge list of issues that are long solved, but never were marked CLOSED (e.g. openSUSE-11.3 has 453 CLOSED vs 2727 RESOLVED).

This wastes time of reporters writing a duplicate bug-report and wastes time of developers having to figure out that it really is a dup. This is probably why other projects recommend setting bugs to ASSIGNED/FIXED until the patch is released. Unfortunately bnc lacks this state.

Also bugzilla has an UNCONFIRMED state for new bugs that need triaging to get into the NEW state (named “Reproducible but not assigned” in other projects). Such a state is unavailable on bnc, so that people can not tell apart bugs that have been forgotten from bugs that are known to exist, but just wait for a developer to fix.

There was also little integration between OBS and bnc. I have therefore written scripts to update bugzilla entries with links to submit requests on OBS mentioning e.g. bnc#685133 (<=see link for how it looks like). But it still could be made a lot more useful.

Overall, there is some room for improvement to make people’s lives easier, and allow us having a lot of fun…

Calibre Repository Moved

April 15th, 2011 by

Maybe not everybody knows it or it may be a bit too late, but nevertheless… the Calibre repository on home:thomas-schraitle:calibre has been moved to Documentation:Tools. It was necessary due to some internal reorganisation. The new location is now the official devel project.

Have fun! 🙂

osc plugin – changes

March 23rd, 2011 by

OSC is a powerful tool for packaging experts, exposing all the latest and greats features of the Build Service. It’s written on python and easy in studying and using. However there are situations when its functionality is not enough; sometimes we need something special. In this case to us will help plug-in mechanism, which in osc is realised very simply.
Plugin can use all of the features, which already implemented osc, as well as provide an output in a convenient format for you. For example, if I want to check changes in kdelibs4 between openSUSE:11.3 and openSUSE:11.4, I can do something like this:

> osc rdiff openSUSE:11.3 kdelibs4 openSUSE:Factory kdelibs4

After that I will receive a detailed output about all changes. Yes, that’s great… but not always it’s convenient. For example, in this case output will contain more than 2000 strings, and I need time to find, say, a *.changes file if I want quickly to understand that has been changed. In case if I want to transfer output to processing to another program (as often happens in practice), I have to shape this data. Unfortunately osc is not as intelligent and can’t show changes from one file (from *.changes, for example) only…

Hello world

Let’s me show how we can create a very simple osc-plugin. In the derectory /var/lib/osc-plugins/ we create a new file tell_me_something.py with such content:

@cmdln.alias('say')
def do_say_something(self, subcmd, opts, *args):
    if sys.argv[2] == "something":
        print "openSUSE rulezzz"
    else:
        print sys.argv[2]

At start, osc will check this directory and will register all found there plugins. In that case, if in the plugin’s content there are errors, osc will report about it immediately. If now we run

> osc help

we will see in the list our function say_something and the key to start it – say. Let’s test:

> osc say "hello"
hello
> osc say GNU/Linux
GNU/Linux
> osc say something
openSUSE rulezzz
>

As you can see, it’s very easy – just python and nothing else. Let’s go back to the output of the function rdiff(), which we mentioned at the beginning.

show me changes

In output of rdiff() nothing wrong, but I would like to immediately get information about what exactly has been done and, for example, which bugzilla-reports (related to this package) have been closed, etc. All what I need, are in rdiff’s output. It means that all what I have to do is just to shape this output.

In 40 minutes of hacking I got such output:

> osc changes kdelibs4 openSUSE:11.3 openSUSE:11.4
PACKAGE: kdelibs4
BUGZILLA_NOVELL: 668185, 670426, 644236, 596021
BUGZILLA_OTHER: 246652, 170806, 149991, 221989, 252280, 253387, 253294, 193364, 253414
CHANGES:

- work around random error on first startup, bnc#668185,
  kubuntu has a similiar patch applied
- call update-mime-database in pre/post install scripts
- don't show synthetic volume label when none is really available,
  allow kio_sysinfo to fall back to device path (bnc#670426)
- update to KDE Platform 4.6.0
  * Plasma applets can be written in QML
  * Plasma data engines can be written in Javascript
  * Plasma data engines can use generic cache for offline mode
  * udev, udisks, upower replace HAL in Solid
  * For more details, see http://kde.org/announcements/4.6
- add patch from 4.6 branch to fix plasma crash on exit
- Add dependencies on udisks and upower for 11.3 and up for Solid
- update to 4.5.95
  * KDE 4.6 RC2
  * no upstream changelog available.
- update to 4.5.90
  * KDE 4.6 RC1
  * no upstream changelog available.
- For 11.2 and 11.3 only : Will build now with polkit-qt-1
  v 0.99.1, which is an official requirement of KDE 4.6
- update to 4.5.85
  * KDE 4.6 Beta2
  * Final Beta before RC, various fixes from Beta1
  * no upstream changelog available.
- For 11.2 and 11.3 only : Added patch to revert changes that
  requires a higher version of polkit-qt-1
- update to 4.5.80
  * KDE 4.6 Beta1
  * no upstream changelog available.
-  Closing the shell via CTRL+D crashes [bko#246652]
- fix build with gcc 4.6
- tighten qt4 dependencies
- update to 4.5.3
  * see http://kde.org/announcements/changelogs/changelog4_5_2to4_5_3.php for details
- update branch diff for various bugs in 4.5:
  * Crash on configure toolbars (bko#170806)
  * KCookieJar can't read cookies from another port (bko#149991)
  * Fix oversized number input widgets (bko#221989)
  * CSS conformance issue (bko#252280)
  * Fix helper protocols such as mailto: and telnet:
  * Plasma crash on comic applet switch (bko#253387)
  * HTTPS urls in KMail do not open properly in browser (bko#253294)
  * Mailto: links in FireFox started by kmailservice fail (bnc#644236)
  * Crash in directory listings when toggling
    show hidden files flag (bko#193364)
- Upstream patch added for kmail issue (bko#253414)
- update to 4.5.2
  * see http://kde.org/announcements/changelogs/changelog4_5_1to4_5_2.php for details
- build apidocs separately to reduce build time
- BuildRequire utempter-devel
- update to 4.5.1
  * see http://kde.org/announcements/changelogs/changelog4_5_0to4_5_1.php for details
- new package: kdelibs4-apidocs (bnc#596021)
- update to 4.5.0
  * KDE 4.5.0 final (version bump over RC3)
- update to 4.4.95
  * KDE 4.5 RC3 (not announced)
  * critical fixes for 4.5.0 release
- Add libsoprano-devel Require to libkde4-devel
- update to 4.4.93svn1149349
- update to 4.4.5
  * bugfixes over 4.4.4
  * see http://kde.org/announcements/changelogs/changelog4_4_4to4_4_5.php for details

and between 11.4 and factory:

> osc changes kdelibs4 openSUSE:11.4 openSUSE:Factory
PACKAGE: kdelibs4
CHANGES:

- update to 4.6.1
  * Bugfixes over KDE 4.6.0
  *  see http://kde.org/announcements/changelogs/changelog4_6_0to4_6_1.php for details
- remove upstreamed patches

aha… and what’s about vim between 11.2 and 11.3?

> osc changes vim openSUSE:11.2 openSUSE:11.3
PACKAGE: vim
BUGZILLA_NOVELL: 598903
CHANGES:

- Add screen control sequences to inputrc (bnc#598903)
- Use the icon from the tarball instead of our custom icon. It
  looks much better.
- Drop gvim.png from the source package.
- build data subpackage as noarch
- updated patches to apply with fuzz=0

Now we can see exactly what was has been done and which bugzilla-reports was fixed/closed. Yes, we have bnc# and bko# reports: reports from bugzilla.novell.com and bugs.kde.org (it cut be also bugs.kernel.org). Second group will be always different (KDE/Gnome/Mozilla/Kernel…).

Source code of plugin is here, and I hope this post will be useful for you if you’ve never written a plugin before.