Friday, 2025-02-14

stephenfinfungi: clarkb: If I wanted to do a wholesale import of OSC into SDK, how could I do that while preserving history *through Gerrit*?11:08
stephenfinI'm aware I want to use subtree merge (I've done this before, but not in a long time) but presumably that's going to generate a change for every commit ever made to OSC11:09
*** tkajinam is now known as Guest912913:39
fungistephenfin: i think we would use administrative permissions to force push the updated state of the repository, which would then preserve the old change references as-is, they'd just point to the (subsequently retired) old repo14:36
jamespageo/14:37
fungiwhat's up jamespage?14:37
jamespagehey fungi14:37
jamespagejust prepping downstream in Ubuntu for upcoming milestones - there are some new oslo module versions that don't seem to have published to tarballs.openstack.org (at least the tarball has not been published)14:38
jamespageseem to be present on pypi - https://pypi.org/project/oslo.cache/#files14:39
jamespagebut not here - https://tarballs.opendev.org/openstack/oslo.cache14:39
fungijamespage: probably you're getting caught by latest setuptools enforcing sdist filename normalization14:45
fungithe tarballs do exist, but any . or - in the project name now becomes a _ in the filename14:46
jamespageurgh14:46
jamespagethat would explain it14:46
fungipypi also started complaining about sdist tarballs with non-normalized project name strings in their filenames around november14:47
fungisetuptools actually started applying the normalization in the release from july 1 of last year, but we weren't building sdists with recent setuptools until we switched from invoking setup.py directly to using pyproject-build a few weeks ago14:48
fungithis was part of migrating jobs to pyton 3.12, since venvs created by it no longer preinstall a copy of setuptools14:49
fungiit's all very simple, you see? ;)14:50
jamespagelol14:51
fungiyeah, that's a january i won't be getting back15:02
clarkbfungi: stephenfin: I believe Gerrit changes are project specific now. So I'm not sure you can preserve the change history without recreating all of the changes15:07
clarkbfungi: stephenfin: this change occurred with the transition to notedb as each change is stored as special refs in the repo itself. Previously that info was in the sql db and not namespaced this way15:07
clarkbif you only want to preserve git history that can be done with different shas then you force push as fungi mentions to avoid creating new changes15:08
fungiin this case, by "preserve" i meant they'll still exist in the retired repo15:08
clarkbgood point. I just want to call out there are two "histories" in play here and one is more easily preserved by copying a repo into another than the other history is15:09
fungithe commits in the other repo will just be copies, not attached to the original changes except loosely through their change-id commit message footers15:09
clarkbright and maybe that is sufficient15:09
clarkbI do wonder what the value in merging these repos is.15:10
fungihopefully it's not "monorepo madness" filtering into openstack ;)15:10
clarkbis it jus so that people don't have to install two different tools with pip? or to avoid cloning two repos? Maybe it simplifies needing to make releases for sdk to consume changes within the client (but I would argue that is a good way to ensure the sdk is operating for other consumers in a sane way)15:11
fungiwe have a ci system that can speculatively integrate changes between tightly-coupled projects15:11
stephenfinclarkb: fungi: What I'm trying to do is preserve the ability to do a git blame15:11
stephenfinThis is what I have at the moment, and we'd lose all history https://review.opendev.org/c/openstack/openstacksdk/+/94163715:11
stephenfinand no, not monorepo madness. It's to avoid this dance15:11
fungigit blame will still work in the proposed case, yes15:11
clarkbstephenfin: if git blame is the historical context that is important then ya doign a git merge of the repos using filter branch or subtree merge then force pushing the result to gerrit would do the trick15:12
clarkbthough everyone (incudling all the CI systems) may have to do a hard reset15:12
stephenfinhttps://review.opendev.org/c/openstack/python-openstackclient/+/940111 -> https://review.opendev.org/c/openstack/openstacksdk/+/939703 -> https://review.opendev.org/c/openstack/python-openstackclient/+/93970615:12
clarkbthough maybe you can avoid a hard reset here if you have a merge commit that adds in the new tree15:13
stephenfinSDK and OSC are *super* tightly coupled now. If you want to add a new field to a resource, you need to add it to SDK, cut a release of SDK, add it to OSC, and cut a release of that15:13
clarkbbasically have a disjoint history until the merge commit. That might avoid the downstream consumption pain15:13
fungiokay, so the sdk repo itself isn't entirely going away, just part of it is moving into osc?15:13
clarkbstephenfin: right but isn't that a signal you need a release anyway for everyone else using sdk?15:13
stephenfinOther way around: I'd like OSC to (mostly) go away and be folded into SDK15:13
fungior other way around i guess15:13
clarkbmy point was that if the cli needs sdk releases to consume things then other people do too. Ya thats annoying but if you merge them now other consumers of the sdk can be left behind more easily15:14
stephenfinclarkb: It probably is, but that's 2x the work for basically no gain15:14
fungiokay, so guts of osc move into sdk, osc itself becomes more of a heavyweight entrypoint wrapper project?15:14
stephenfinexactly15:14
clarkbdogfooding the sdk in this way is a really good way to ensure we're not leaving sdk users in a bind15:14
clarkbbut I understand the pain involved15:15
clarkbanother thing to keep in mind is that our python package tooling really expects a 1:1 mapping between repo and package15:15
clarkbfixing ^ is likely to be a bigger headache than any git magic15:15
clarkbunelss you move to a package that includes everything and then have some meta packge magic for the package name that no longer gets updated to alias the thing that does15:16
clarkbI think that would work within the existing package publication framework15:16
stephenfingtema and I discussed this in #openstack-sdks this morning15:16
stephenfinI think the way we'll go for now is to move all the entrypoints and command implementations into SDK, but keep the actual shell code and console_scripts entry point into OSC15:17
stephenfins/into OSC/in OSC15:17
stephenfinpretty much like how e.g. python-manilaclient contains commands and entrypoints for OSC and OSC simply calls it15:18
stephenfinor them, rather15:18
clarkbI don't like that design for one major reason: It means you're even more dependeny on entrypoints for osc than before. And entrypoints are one of the primary things that makes osc terribly slow15:19
clarkbmy personal opinion is that the osc codebase should move towards an entrypointless setup whcih can more than halve its runtime depending on your disk io15:20
clarkbeveryone loves to hate on how osc is slow and go off and rewrite a new tool in $otherlanguage saying "look we fixed it" but then we double down on the things that make the python implementation bad. They are inherent to python they are artifacts of our design choices15:21
clarkb*they are not inherent to python; they are artifacts of our design choices15:21
clarkbif osc did two things the runtime would become dominated by network io: don't use entrypoints and cache tokens. Then you're in the same boat as every other client tool and performance should be comparable15:22
stephenfinclarkb: sorry, meetings16:18
stephenfincan't argue with that16:18
stephenfinWhat I've described above is the (b) option from my discussion with gtema this (EU) morning https://meetings.opendev.org/irclogs/%23openstack-sdks/%23openstack-sdks.2025-02-14.log.html#t2025-02-14T11:13:4116:19
stephenfinThere's no reason we couldn't follow that up with the (a) option, where python-openstackclient becomes a meta package that simply installs e.g. 'openstacksdk[cli]'16:20
stephenfinand eventually get rid of python-openstackclient entirely 16:21
opendevreviewElod Illes proposed openstack/openstack-zuul-jobs master: Prepare job templates for stable/2025.1 testing runtime  https://review.opendev.org/c/openstack/openstack-zuul-jobs/+/94124516:21
opendevreviewElod Illes proposed openstack/openstack-zuul-jobs master: Prepare job templates for 2025.2 testing runtimes  https://review.opendev.org/c/openstack/openstack-zuul-jobs/+/94124616:21
opendevreviewElod Illes proposed openstack/openstack-zuul-jobs master: Prepare job templates for stable/2025.1 testing runtime  https://review.opendev.org/c/openstack/openstack-zuul-jobs/+/94124518:45
opendevreviewElod Illes proposed openstack/openstack-zuul-jobs master: Prepare job templates for 2025.2 testing runtimes  https://review.opendev.org/c/openstack/openstack-zuul-jobs/+/94124618:45

Generated by irclog2html.py 2.17.3 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!