[
https://issues.apache.org/jira/browse/HBASE-22853?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17268043#comment-17268043
]
Viraj Jasani commented on HBASE-22853:
--------------------------------------
{quote}you need {{--populate-from-git=true-}} if you want the tool to read the
git repo at all.
{quote}
I realized that but tried it after sqlite was built initially, and it failed
with UNIQUE (perhaps expected)
{code:java}
$ ./venv/bin/python3 ./git_jira_release_audit.py \
> --populate-from-git=true \
> --populate-from-jira=false \
> --branch-1-fix-version=1.7.0 \
> --branch-2-fix-version=2.5.0 \
> --report-new-for-release-branch=origin/branch-2.4
INFO:git_jira_release_audit.py:origin/branch-1 has 4267 commits since its
origin at 0167558eb31ff48308d592ef70b6d005ba6d21fb.
Traceback (most recent call last):
File "./git_jira_release_audit.py", line 704, in <module>
main()
File "./git_jira_release_audit.py", line 692, in main
auditor.populate_db_from_git()
File "./git_jira_release_audit.py", line 502, in populate_db_from_git
self._repo_reader.populate_db_release_branch(branch_origin,
release_line.name)
File "./git_jira_release_audit.py", line 382, in populate_db_release_branch
self._db.apply_commit(*row)
File "./git_jira_release_audit.py", line 113, in apply_commit
(jira_id, branch, git_sha))
sqlite3.IntegrityError: UNIQUE constraint failed: git_commits.jira_id,
git_commits.branch, git_commits.git_sha
{code}
It seems after we build sqlite initially, it might not be possible to use
populate-from-git true with report-new-for-release-branch option?
{quote}If its anything other than {{origin}}, you'll need to tweak the git refs
accordingly.
{quote}
You are right, I need to handle this. Anyways, I realize this should help. Will
ping you if I face any issues. Thanks [~ndimiduk]
> Git/Jira Release Audit Tool
> ---------------------------
>
> Key: HBASE-22853
> URL: https://issues.apache.org/jira/browse/HBASE-22853
> Project: HBase
> Issue Type: Task
> Components: build
> Reporter: Michael Stack
> Assignee: Nick Dimiduk
> Priority: Minor
> Fix For: 3.0.0-alpha-1
>
>
> Before cutting RC, need to make reconciliation between what's in JIRA and
> then what has been actually committed to ensure JIRA is accurate before
> starting the RC build (in order to ensure CHANGES/RELEASENOTES are accurate,
> etc.).
> Would be good to have a tool that compared git log for the release to
> fixVersion in JIRA (and then fixVersion in JIRA to what is in git) to ensure
> matching mentions in both places. It can get complicated when there has been
> reverts in git or when an issue is an umbrella issue w/ no direct patch
> associated in JIRA but tool could start out simple dumping out a list of
> hashes/JIRAs for the RM to 'check' where anomalies; i.e. mention in one
> system but not in the other. This would save on a bunch of work aligning the
> two systems. Could also do stuff like check git log to ensure all commits
> have associated JIRA, and so on.
> (Should there be a PR component?).
--
This message was sent by Atlassian Jira
(v8.3.4#803005)