<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"><channel><title>danigm.net - rpmlint</title><link>https://danigm.net/</link><description></description><lastBuildDate>Thu, 30 May 2024 00:00:00 +0200</lastBuildDate><item><title>rpmlint: Google Summer of Code 2024</title><link>https://danigm.net/gsoc-2024.html</link><description>&lt;p&gt;I'm glad to say that I'll participate again in the &lt;a href="https://summerofcode.withgoogle.com/"&gt;GSoC&lt;/a&gt;, as
mentor. This year we will continue the work done during the past year,
as part of the &lt;a href="https://www.opensuse.org/"&gt;openSUSE&lt;/a&gt; project.&lt;/p&gt;
&lt;p&gt;So this summer I'll be mentoring an intern and we'll continue working
on improving the testing framework of the &lt;a href="https://github.com/openSUSE/mentoring/issues/204"&gt;rpmlint project&lt;/a&gt;.&lt;/p&gt;
&lt;p class="img"&gt;
  &lt;img src="/pictures/gsoc.png" /&gt;
&lt;/p&gt;

&lt;p&gt;This year we've a better testing framework, thanks to the work done
during the past Summer of Code, by Afrid. So the goal for this year is
to try to modernize existing tests and remove as much files as
possible from &lt;code&gt;test/binary&lt;/code&gt; directory, replacing those with mock
packages defined with python code.&lt;/p&gt;
&lt;p&gt;The selected intern is &lt;a href="https://blog-gsoc-2024.blogspot.com/2024/05/gsoc-improve-test-coverage-in-rpmlint.html"&gt;Luz Marina Montilla Marín&lt;/a&gt;. She has done
some initial work in the rpmlint project, creating the mock packages
for some tests and we've just started with the work to do during the
GSoC program, evaluating the tests that we've right now and planning
were to start.&lt;/p&gt;
&lt;p&gt;She studies at Córdoba, Spain, my hometown. Every year I try to reach
young people at different local universities, here in Andalucía, and
sometimes I'm able to convince some students to participate, like the
&lt;a href="https://danigm.net/gsoc-2020.html"&gt;GSoC 2020&lt;/a&gt;, when Alejandro Dominguez, from Seville, were working
on Fractal. So I'm happy that I'm increasing the number of free
software developers in my local community :D&lt;/p&gt;
&lt;p&gt;I'm sure that she will be able to achieve great things during these
three months, so I'm looking forward to start to code and see how far
can we go.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">danigm</dc:creator><pubDate>Thu, 30 May 2024 00:00:00 +0200</pubDate><guid isPermaLink="false">tag:danigm.net,2024-05-30:/gsoc-2024.html</guid><category>blog</category><category>gnome</category><category>software</category><category>rpmlint</category><category>suse</category><category>gsoc</category></item><item><title>rpmlint updates (August 2023)</title><link>https://danigm.net/rpmlint-updates-2023-08-30.html</link><description>&lt;p&gt;We are at the end of the summer and this means that this year Google Summer of
code is ending.&lt;/p&gt;
&lt;p class="img"&gt;
  &lt;img src="/pictures/rpmlint-gitg-gsoc-2023.png" /&gt;
&lt;/p&gt;

&lt;p&gt;The recent changes applied now in the main branch include:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Remove usage of &lt;code&gt;pkg_resource&lt;/code&gt; because it's deprecated.&lt;/li&gt;
&lt;li&gt;Fix elf binary check with ELF files with a prefix.&lt;/li&gt;
&lt;li&gt;New check for python packages with multiple .pyc files for different python
   versions.&lt;/li&gt;
&lt;li&gt;Improve the testing framework (merged the work done during the GSoC 2023)&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Summer of Code 2023 updates&lt;/h2&gt;
&lt;p&gt;The summer of code is ending and the work done by &lt;a href="https://github.com/rpm-software-management/rpmlint/pull/1101"&gt;Afrid was good enough to be merged&lt;/a&gt;,
so I merged it the past week.&lt;/p&gt;
&lt;p&gt;I'm really happy with the work done during the GSoC program, now we've a more
simple way to define tests for rpmlint checks mocking the rpm, so it's not
always needed to build a fake rpm binary for each new test. This will make a
lot easier to create simple tests, so I hope that we can increase the code
coverage using this &lt;a href="https://github.com/rpm-software-management/rpmlint/blob/main/test/README.md"&gt;new framework&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;During this time Afrid has extended the &lt;code&gt;FakePkg&lt;/code&gt; class, so it's possible now
to define fake metadata and files with fake tags and attributes. It's not
complete and it's not a simple task to replace all the &lt;code&gt;rpm&lt;/code&gt; binaries used for
tests, because the &lt;code&gt;Pkg&lt;/code&gt; class and &lt;code&gt;RPM&lt;/code&gt; tags is a complex thing, but the
current state allow us to replace a lot of them. Afrid has replaced some of the
tests that uses binaries, but in the following months we can continue working
on this and &lt;a href="https://github.com/rpm-software-management/rpmlint/issues/1105"&gt;replace more&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;After this work, we can now start to use more the &lt;code&gt;FakePkg&lt;/code&gt; class in tests,
so another task that we can do is to provide some &lt;a href="https://github.com/rpm-software-management/rpmlint/issues/1104"&gt;common fake pkgs&lt;/a&gt; to use
in different tests and new checks, so now it's possible to create fake packages
with dynamic random data, so we can extend tests with fuzz testing and maybe
this will help to improve the tool reliability.&lt;/p&gt;
&lt;p class="img"&gt;
  &lt;img src="/pictures/gsoc.png" /&gt;
&lt;/p&gt;

&lt;h2&gt;Conclusion&lt;/h2&gt;
&lt;p&gt;I've participated as mentor several times now in the &lt;a href="https://summerofcode.withgoogle.com/"&gt;summer of code&lt;/a&gt;, and
&lt;a href="https://www.outreachy.org/"&gt;outreachy&lt;/a&gt;, and almost always was a good experience. With the &lt;a href="https://www.gnome.org/"&gt;gnome foundation&lt;/a&gt;
in previous programs and this year with &lt;a href="https://www.opensuse.org/"&gt;opensuse&lt;/a&gt;. These two communities
are very open to collaboration and makes the whole process really simple, for
me as mentor, and also for the intern.&lt;/p&gt;
&lt;p&gt;I want to congratulate Afrid, because it was nice to work with him during this
summer, he has done a great work, not just technically, but communicating,
asking and finding his own solutions without requiring a continuous guidance.&lt;/p&gt;
&lt;p&gt;He is very passionate and looks like a nice person, so I hope that he will
continue around the open source, it could be opensuse, rpmlint or any other
community, but this kind of people is what you want to find in any community.&lt;/p&gt;
&lt;p&gt;After many years collaborating with different free software communities, it's
amazing that there are so many great people in every project, of course you can
find toxic communities and people, but in my experience, that's usually just
noise, there are a lot of nice people out there, doing a great work, and I'm
happy that young people like Afrid can be part of the free software movement,
because this is what makes the free software great, the people that is
working on it.&lt;/p&gt;
&lt;p&gt;So Thanks a lot to Google for another summer of code, thanks to SUSE for
letting me, and encourage me, to mentor, and thanks to all the free software
developers that are out there.&lt;/p&gt;
&lt;p&gt;I encourage everyone to participate in this kind of programs, for interns, it's
a good opportunity to learn and to make some money working on free software,
for mentors it's an opportunity to get some help in your project and help
newcomers to be part of the community.&lt;/p&gt;
&lt;p&gt;Have a lot of fun!&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">danigm</dc:creator><pubDate>Wed, 30 Aug 2023 00:00:00 +0200</pubDate><guid isPermaLink="false">tag:danigm.net,2023-08-30:/rpmlint-updates-2023-08-30.html</guid><category>blog</category><category>gnome</category><category>software</category><category>rpmlint</category><category>suse</category><category>gsoc</category></item><item><title>rpmlint updates (July 2023)</title><link>https://danigm.net/rpmlint-updates.html</link><description>&lt;p&gt;I'm spending some time every week working in the &lt;a href="https://github.com/rpm-software-management/rpmlint"&gt;rpmlint&lt;/a&gt; project.
The tool is very stable and the functionality is well defined,
implemented and tested, so there's no crazy development or a lot of
new functionalities, but as in all the software, there are always bugs
to solve and things to improve.&lt;/p&gt;
&lt;p class="img"&gt;
  &lt;img src="/pictures/rpmlint-gitg-20230706.png" /&gt;
&lt;/p&gt;

&lt;p&gt;The recent changes applied now in the main branch include:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Update the usage of &lt;code&gt;rpm&lt;/code&gt; to not use old API.&lt;/li&gt;
&lt;li&gt;Fixes for &lt;code&gt;rpmdiff -v&lt;/code&gt;, check for NULL char, special macros in
   comments and spell checking of description in different languages.&lt;/li&gt;
&lt;li&gt;Move all the metadata from &lt;code&gt;setup.py&lt;/code&gt; to &lt;code&gt;pyproject.toml&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Releasing rpmlint as pre-commit hook&lt;/li&gt;
&lt;li&gt;Improvements to the PythonCheck in the dependency checking.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Summer of Code 2023 updates&lt;/h2&gt;
&lt;p&gt;The first month of the Summer of Code has passed and &lt;a href="https://afridhussain.tech"&gt;Afrid&lt;/a&gt; is
doing a great job there. We've now a &lt;a href="https://github.com/rpm-software-management/rpmlint/pull/1079"&gt;draft Pull Request&lt;/a&gt; with some
initial changes that allow us to mock &lt;code&gt;rpm&lt;/code&gt; packages in tests so it's
easier to create new tests without the need of creating a binary
package.&lt;/p&gt;
&lt;p&gt;The first step done was to extend the existing &lt;code&gt;FakePkg&lt;/code&gt; class to
allow us to define package files and some package metadata.&lt;/p&gt;
&lt;p&gt;Now he's working in replacing all of the &lt;code&gt;test_python.py&lt;/code&gt; tests that
uses binaries &lt;code&gt;rpm&lt;/code&gt; to something that doesn't needed.&lt;/p&gt;
&lt;p&gt;The idea is to replace as much tests as possible to reduce the number
of rpm binaries and after that, provide helper functions, decorators
and classes to make it easy to write tests, writing less code.&lt;/p&gt;
&lt;h2&gt;Roadmap&lt;/h2&gt;
&lt;p&gt;In any software project there's always room for improvements, fixes
and enhancements. If the project is there for enough time, it's even
more critical to modernize the code to reduce the technical debt.&lt;/p&gt;
&lt;p&gt;My plan for 2023 is to improve the tests around rpmlint as much as
possible. First with the GSoC project, making it easier to write more
tests, improving the testing tools that we've. And after the summer,
improving the test coverage.&lt;/p&gt;
&lt;p&gt;There's also a tool that shares some of the ideas with rpmlint,
&lt;a href="https://github.com/rpm-software-management/spec-cleaner"&gt;spec-cleaner&lt;/a&gt;, it's also written in Python, so the next step,
after the tests improvements will be to take a deep look into the code
of these two tools and try to integrate in some way. Maybe it's
possible to refactor the common code into an external module, maybe we
can bring some ideas from spec-cleaner to rpmlint. Not sure yet, but
that'll be my next step.&lt;/p&gt;
&lt;p&gt;Don't forget that this is free software, so you can participate too!
If you find any issue in rpmlint or have an idea to improve it, don't
hesitate and &lt;a href="https://github.com/rpm-software-management/rpmlint/issues"&gt;create a new issue&lt;/a&gt;.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">danigm</dc:creator><pubDate>Thu, 06 Jul 2023 00:00:00 +0200</pubDate><guid isPermaLink="false">tag:danigm.net,2023-07-06:/rpmlint-updates.html</guid><category>blog</category><category>gnome</category><category>software</category><category>rpmlint</category><category>suse</category><category>gsoc</category></item><item><title>rpmlint: Google Summer of Code 2023</title><link>https://danigm.net/gsoc-2023.html</link><description>&lt;p&gt;I'm glad to say that I'll participate again in the &lt;a href="https://summerofcode.withgoogle.com/"&gt;GSoC&lt;/a&gt;, as
mentor. This year will be a bit different from the previous ones,
because I'm not mentoring a GNOME project but a &lt;a href="https://www.opensuse.org/"&gt;openSUSE&lt;/a&gt; project.&lt;/p&gt;
&lt;p&gt;I started to work at SUSE the past year and with this new job I get
involved in the openSUSE community and I started to contribute to
&lt;a href="https://github.com/rpm-software-management/rpmlint"&gt;rpmlint&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;So this summer I'll be mentoring an intern and we'll work on improving
the testing framework of the &lt;a href="https://github.com/openSUSE/mentoring/issues/189"&gt;rpmlint project&lt;/a&gt;.&lt;/p&gt;
&lt;p class="img"&gt;
  &lt;img src="/pictures/rpmlint.png" /&gt;
&lt;/p&gt;

&lt;p&gt;The rpmlint project is a command line tool to check rpm packages, the
correctness of these kind of packages and warn the packagers about
usual problems or good practices. It's widely used in all Linux
distributions based on rpm, mainly SUSE and RedHat.&lt;/p&gt;
&lt;p&gt;It is written in Python and uses pytest for testing the code. Right
now there are a lot of .rpm binary packages, to check different
functionality, but that way of testing makes a bit hard to write new
tests and to maintain with changes. The idea of this GSoC project is
to extend the testing framework of rpmlint to support an easy way
of writting tests that doesn't require a real rpm, something that can
mock what it's in the .rpm binary and try to replace some of the
current binary tests with this new mock.&lt;/p&gt;
&lt;p&gt;The selected intern is &lt;a href="https://afridhussain.tech/post/accepted-into-gsoc/"&gt;Afrid Hussain&lt;/a&gt;. He has done some initial
work in the rpmlint project, solving some minor issues and we're now
preparing the work to be done during the GSoC program. I'm sure that
he will be able to achieve great things during these three months, so
I'm looking forward to start to code and see how far can we go.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">danigm</dc:creator><pubDate>Tue, 16 May 2023 00:00:00 +0200</pubDate><guid isPermaLink="false">tag:danigm.net,2023-05-16:/gsoc-2023.html</guid><category>blog</category><category>gnome</category><category>software</category><category>rpmlint</category><category>suse</category><category>gsoc</category></item></channel></rss>