1 |
On 3/10/2022 14:58, Alec Warner wrote: |
2 |
> On Thu, Mar 10, 2022 at 10:27 AM Joshua Kinard <kumba@g.o> wrote: |
3 |
>> |
4 |
>> On 3/9/2022 16:00, Matt Turner wrote: |
5 |
>>> I'd like to deprecate and ultimately remove repoman. I believe that |
6 |
>>> dev-util/pkgcheck and pkgcommit (from app-portage/mgorny-dev-scripts) |
7 |
>>> are far superior replacements, and it makes sense to have people using |
8 |
>>> the same tool and seeing the same warnings as in the CI. |
9 |
>>> |
10 |
>>> Are there any useful checks or behaviors of repoman that are missing |
11 |
>>> from pkgcheck and pkgcommit? |
12 |
>>> |
13 |
>>> Thanks, |
14 |
>>> Matt |
15 |
>> |
16 |
>> repoman has been //the// goto tool for checking in a change since before I |
17 |
>> was a developer in 2003. It does everything we need, in one simple tool. |
18 |
>> Your proposal looks to replace repoman's functionality (and snark) with two |
19 |
>> or more packages, including tools from a package named after a fellow developer. |
20 |
>> |
21 |
>> Additionally, "I believe that <foo> are far superior replacements" is an |
22 |
>> entirely subjective opinion and, frankly, completely invalid as |
23 |
>> justification to replace a tool that has worked fine for the last 20+ years. |
24 |
>> What is so fundamentally broken about repoman that cannot be fixed such |
25 |
>> that it needs total replacement by multiple independent tools? Please |
26 |
>> document. the pros and cons here so that we can all make an informed decision. |
27 |
> |
28 |
> So here is the more basic argument, you can agree or disagree. |
29 |
> |
30 |
> *The goal I want is for people to commit to the tree and not break things.* |
31 |
|
32 |
This goal I agree with, and I am rather pedantic about. If not mildly |
33 |
fearful of. We've all been there at least once in our dev-lives. It's |
34 |
almost a rite of passage, if you will, to break the tree with a dumb commit |
35 |
at least once. Goal is to never repeat that mistake again. |
36 |
|
37 |
|
38 |
> If we could accomplish this with no tooling at all, that would be |
39 |
> great. Sadly humans are fallible and so we have tools to check their |
40 |
> work. Currently this tooling has two parts: |
41 |
> - pre-push tooling that you run prior to pushing. |
42 |
> - post-push CI tooling that informs you when you break the tree. |
43 |
> |
44 |
> So holding to our goal of not breaking the tree, it's better for |
45 |
> developers to run the same QA tool in pre-push that CI is using, |
46 |
> because our metric for 'breaking the tree' is the CI tool and if the |
47 |
> CI tool passes locally, there is a strong likelihood it will not break |
48 |
> in CI either. Note this argument is generic, I'm not even saying which |
49 |
> tools are in use, or which tools are better, or anything like that. |
50 |
> |
51 |
> Here we see Matt discussing a workflow he finds frustrating. |
52 |
> - A developer does a push. |
53 |
> - Their push breaks CI. |
54 |
> - He inquires about their workflow. |
55 |
> - He learns they did not run the CI tool in their pre-push workflow. |
56 |
> - He tells them they should run the CI tool in their pre-push workflow. |
57 |
> - This happens many times, causing this thread. |
58 |
> |
59 |
> The point of the thread then is to convince people to run the CI tool |
60 |
> in pre-push, as a matter of policy, to reduce tree breakage and reduce |
61 |
> the occurrence of the above conversation. |
62 |
|
63 |
I stick to the officially-published method of checking and committing changes: |
64 |
https://devmanual.gentoo.org/ebuild-maintenance/git/index.html |
65 |
|
66 |
The two tools highlighted there for the bulk of the work is repoman and |
67 |
pkgdev. repoman is cited twelve times, pkgdev is cited six times. pkgcheck |
68 |
is mentioned once. pkgcommit has no mentions. |
69 |
|
70 |
From that, one should not be faulted for assuming that repoman is the more |
71 |
important tool, if not preferred tool, with pkgdev coming in second place. |
72 |
pkgcheck comes across as entirely optional and even seems equivalent to |
73 |
'repoman full', and how would one know that pkgcommit even exists? |
74 |
|
75 |
Not all of us devs are involved in the automated CI stuff that goes on |
76 |
behind the scenes. Matt and MichaĆ are, so they know how bad it can be and |
77 |
the likely countless hours spent fixing things or yelling at others when |
78 |
these mistakes are made. But if this isn't documented somewhere, how are |
79 |
those of us not involved in the CI-side able to keep up? When I am in doubt |
80 |
over something, I go to the documentation to address things. Right now, |
81 |
that documentation is going to more or less tell me to stick with repoman. |
82 |
|
83 |
That all said, most of my checks are done pre-commit, not pre-push. It's |
84 |
annoying trying to unwind a commit with a mistake in git, so I aim to not |
85 |
have any in the commit itself. By the time I get to the push stage, |
86 |
everything MUST be perfect before I hit 'git push'. Cause once something is |
87 |
public, there's no going back. In a handful of cases, I've gone as far as |
88 |
nuking my local copy of the tree, re-cloning it, and re-doing everything |
89 |
again just to fix a mistake that I should have caught pre-commit. |
90 |
|
91 |
|
92 |
> So the generic argument above, we now get into the specifics. |
93 |
> |
94 |
>> |
95 |
>> I'm not opposed to making our tools better, but I think before anything can |
96 |
>> replace the RepoMan, several more boxes need to be ticked: |
97 |
>> |
98 |
>> - functionality from multiple tools should be packaged into a single tool. |
99 |
>> * caveat: at least provide a wrapper that, using args, can invoke the |
100 |
>> individual tools if needed. |
101 |
> |
102 |
> I do not believe it's reasonable to provide a 'drop-in' backwards |
103 |
> compatibility tool guarantee. |
104 |
> I believe we should provide a table of common repoman actions, with a |
105 |
> mapping to their replacements; so that users can understand how to do |
106 |
> similar actions. |
107 |
|
108 |
Not opposed to this. It's a reasonable alternative to crafting a wrapper |
109 |
script or kludging in deprecated argument parsing to achieve likely limited |
110 |
backwards compatibility. |
111 |
|
112 |
|
113 |
>> - app-portage/mgorny-dev-scripts needs a new name. It's fine if it's |
114 |
>> intended to only be a collection of useful scripts for individual developers |
115 |
>> on an as-needed basis, but if it's to be the Official Tool(TM), then it |
116 |
>> needs to have a proper name. If not all of the scripts contained within it |
117 |
>> are applicable to the sole function of checking a change into the tree, then |
118 |
>> only the scripts that deal with change validation and committing should be |
119 |
>> broken out into a separate package, and ostensibly combined with any other |
120 |
>> tools/scripts into a single package, and preferably a single tool, to get |
121 |
>> the job done. |
122 |
> |
123 |
> I don't consider this a blocker, but I think it's mostly a discussion |
124 |
> between mattst88 and mgorny. |
125 |
|
126 |
My fault that I should have stated that I don't think it should block, but I |
127 |
do think this it looks....hacky? I mean, say a developer from another |
128 |
distro gets curious about how Gentoo developers do their magic, and while |
129 |
reading the devmanual, sees that the officially-sanctioned way to do |
130 |
something developer-related is to install |
131 |
app-portage/kumbas-super-awesome-devscripts. It looks wildly out of place |
132 |
in official documentation. We used to have a package called |
133 |
app-portage/gentoolkit-dev that contained a collection of utilities intended |
134 |
for Gentoo developers. I'd argue that maybe something like that would be a |
135 |
good starting point for a new name. |
136 |
|
137 |
|
138 |
>> |
139 |
>> - all of our developer documentation needs to be updated to reference the |
140 |
>> new tool and the new way of doing things, as well as a warning not to use |
141 |
>> repoman any further after a set date. Additionally, a news item is probably |
142 |
>> advisable so that developers and proxy maintainers alike can get the message. |
143 |
> |
144 |
> We should hold Matt accountable for updating any relevant development |
145 |
> documentation, including the table I mentioned above. |
146 |
> I'm not sure a news item is strictly necessary, we might just p.mask |
147 |
> repoman with a link to the guide that Matt will need to write about |
148 |
> how repoman is being replaced. |
149 |
|
150 |
How about making an edit to repoman to have it throw a deprecation warning |
151 |
for itself and to install whatever we all agree should replace it? |
152 |
|
153 |
|
154 |
>> - we need the snark. Gentoo is all about personality, and RepoMan has been |
155 |
>> scouring our neighborhoods for two decades and change, and while some may |
156 |
>> think this is utterly frivolous, I will actually miss seeing those messages |
157 |
>> on the console every time I commit a change. They give the RepoMan |
158 |
>> personality and a soul, and thus, contribute to the uniqueness that is Gentoo. |
159 |
> |
160 |
> Cool. |
161 |
|
162 |
Back in mid-2002, it was exactly Gentoo's snarkness that tipped the scales |
163 |
for me. I'd just given up on FreeBSD-4.x on a sparc64 machine (old Sun |
164 |
Blade 100) and LFS turned out to not be a lot of fun, but Gentoo worked fine |
165 |
on it. All of the colors on the terminal gave it zing and pop, and made it |
166 |
rather fun to work with. rpm and apt-get were dull; emerge was cheeky and |
167 |
playful! Still is to this day. |
168 |
|
169 |
That sparc64 machine eventually became my very first dev machine when |
170 |
Seemant was looking for someone to help out with the MIPS port. I got a |
171 |
laugh when I ran repoman for the first time and it tells me it is stalking |
172 |
my neighborhood, looking for issues. The developer tools were just as |
173 |
cheeky and playful as the user-facing tools! |
174 |
|
175 |
And we're still the only distro with some rad mascots, like Larry the Cow |
176 |
and Znurt the alien (at least I think it's an alien -- bottom of the main |
177 |
page, right of the Questions/Comments). And whatever the thing at the very |
178 |
bottom-right looking up is. |
179 |
|
180 |
-- |
181 |
Joshua Kinard |
182 |
Gentoo/MIPS |
183 |
kumba@g.o |
184 |
rsa6144/5C63F4E3F5C6C943 2015-04-27 |
185 |
177C 1972 1FB8 F254 BAD0 3E72 5C63 F4E3 F5C6 C943 |
186 |
|
187 |
"The past tempts us, the present confuses us, the future frightens us. And |
188 |
our lives slip away, moment by moment, lost in that vast, terrible in-between." |
189 |
|
190 |
--Emperor Turhan, Centauri Republic |