<div dir="ltr"><div dir="ltr">On Tue, Dec 7, 2021 at 7:33 AM Anton Korobeynikov via cfe-dev <<a href="mailto:cfe-dev@lists.llvm.org">cfe-dev@lists.llvm.org</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br><div>> 6) We can edit the comments by hand (can you only edit your own comments or can we edit someone else's comments, I'm thinking its only our own based on testing I've done with other repos)</div><div>> - isn't this a requirement in order to fix up the "code-blocks"?</div></blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"> </blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Yes, only admins can edit everything.<br></blockquote><div><br></div><div>I noticed this yesterday with the existing test migration: compare</div><div><a href="https://bugs.llvm.org/show_bug.cgi?id=52598">https://bugs.llvm.org/show_bug.cgi?id=52598</a><br></div><div>versus<br></div><div><div><a href="https://github.com/llvm/llvm-bugzilla-archive/issues/52598">https://github.com/llvm/llvm-bugzilla-archive/issues/52598</a><br></div><br class="gmail-Apple-interchange-newline"></div><div>The current script seems to be forgetting that GitHub issues use Markdown, and so every existing Bugzilla comment needs to be wrapped in triple-backticks to preserve its semantics.<br></div><div>(You could do <i>cleverer</i> things, like "don't wrap comments that are only one line long," but doing anything <i>less-clever</i> will be a non-starter.)</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">> Assuming there is no obvious/immediate fix, Do we have any choice but to move ahead with the existing import and fix the comments by hand retrospectively (assuming 6)<br>
This is what I asked GitHub engineers. They essentially asked for yet<br>
another day to figure out the possible options. My rough estimate that<br>
at least 5k issues will have broken links.</blockquote><div><br></div><div>Anton: I see about 35,000 issues in</div><div><a href="https://github.com/llvm/llvm-bugzilla-archive/issues">https://github.com/llvm/llvm-bugzilla-archive/issues</a><br></div><div>but only 228 (i.e. essentially none, presumably just historical noise from newbie GitHub users) in</div><div><a href="https://github.com/llvm/llvm-project/issues">https://github.com/llvm/llvm-project/issues</a><br></div><div>Where are the 13,000 issues you are saying have already been migrated?</div><div><br></div><div>IIUC, it's <i>very fortunate</i> that there aren't yet 13,000 issues in <a href="https://github.com/llvm/llvm-project/issues">https://github.com/llvm/llvm-project/issues</a> .  That means that it is still an option to do a "practice" migration into a test repo — e.g., <a href="https://github.com/llvm/llvm-bugzilla-archive2">https://github.com/llvm/llvm-bugzilla-archive2</a> (and then if it works as intended, you can either "blow away <a href="https://github.com/llvm/llvm-bugzilla-archive">https://github.com/llvm/llvm-bugzilla-archive</a> and rename <a href="https://github.com/llvm/llvm-bugzilla-archive2">https://github.com/llvm/llvm-bugzilla-archive2</a> to <a href="https://github.com/llvm/llvm-bugzilla-archive">https://github.com/llvm/llvm-bugzilla-archive</a>", or "blow away <a href="https://github.com/llvm/llvm-bugzilla-archive">https://github.com/llvm/llvm-bugzilla-archive</a> and repeat the migration just to prove it works <i>reproducibly</i>".</div><div>Only once the whole migration has been tested end-to-end on a test repo, would I recommend starting the migration into the production repo <a href="https://github.com/llvm/llvm-project">https://github.com/llvm/llvm-project</a>.</div><div><br></div><div>Thanks for the links to <a href="https://github.com/llvm/bugzilla2gitlab/tree/llvm" rel="noreferrer" target="_blank">https://github.com/llvm/bugzilla2gitlab/tree/llvm</a> and <a href="https://docs.google.com/document/d/1G6DZ6AxzSaOlrtTxoxtqYKnD4Myv40QfKK4wj54y8ms/edit">https://docs.google.com/document/d/1G6DZ6AxzSaOlrtTxoxtqYKnD4Myv40QfKK4wj54y8ms/edit</a> .</div><div>Those make it clear that someone's done a little bit of work to script this stuff; but the Google Doc also makes it clear that there is a long way to go to accomplish a "deploy plan": someone needs to take that English description and turn it into code (Python or even Bash or whatever) that can be</div><div>(A) reviewed for correctness, without running it</div><div>(B) run multiple times with guaranteed same behavior, with no risk that some human will accidentally forget a step in the middle</div><div><br></div><div>Step 1, getting the XML files from Bugzilla, turns out to be super easy because there's a public API for that:</div><div><a href="https://github.com/Quuxplusone/BugzillaToGithub">https://github.com/Quuxplusone/BugzillaToGithub</a><br></div><div>Step 3, transforming XML to GitHub's JSON schema, requires knowing what GitHub's schema looks like. I've found</div><div><a href="https://gist.github.com/jonmagic/5282384165e0f86ef105#start-an-issue-import">https://gist.github.com/jonmagic/5282384165e0f86ef105#start-an-issue-import</a><br></div><div>although it's not real clear what the schema is or if that even still works (I haven't tried yet). Also, there seems to be no way for one GitHub user to create a comment or issue putatively authored by some other GitHub user. (Which certainly makes sense.) So this would result in issues and comments filed by "LLVM Import Bot" or whatever... but I think that's fine, and might even avoid some issues that you'd have otherwise, with scenarios like "Joe User created his GitHub account in 2015, but was making comments on LLVM issues back in 2012."</div><div><br></div><div>Vice versa, btw, you've currently got some issues being incorrectly imported with the reporter listed<i> in the issue summary itself</i> as "LLVM Bugzilla Contributor"; e.g. this one from Chris Burel.</div><div><a href="https://github.com/llvm/llvm-bugzilla-archive/issues/52567">https://github.com/llvm/llvm-bugzilla-archive/issues/52567</a><br></div><div>It certainly makes sense that you won't have a GitHub <i>username</i> for some people, but you still shouldn't throw away the information about their human name just because we're migrating from one platform to another.</div><div><br></div><div>–Arthur</div></div></div>