Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[GSOC][PATCH] Modernize a test script #1675

Closed

Conversation

aryangupta701
Copy link

@aryangupta701 aryangupta701 commented Feb 26, 2024

cc: Eric Sunshine sunshine@sunshineco.com
cc: Christian Couder christian.couder@gmail.com

Copy link

gitgitgadget bot commented Feb 26, 2024

Welcome to GitGitGadget

Hi @aryangupta701, and welcome to GitGitGadget, the GitHub App to send patch series to the Git mailing list from GitHub Pull Requests.

Please make sure that either:

  • Your Pull Request has a good description, if it consists of multiple commits, as it will be used as cover letter.
  • Your Pull Request description is empty, if it consists of a single commit, as the commit message should be descriptive enough by itself.

You can CC potential reviewers by adding a footer to the PR description with the following syntax:

CC: Revi Ewer <revi.ewer@example.com>, Ill Takalook <ill.takalook@example.net>

Also, it is a good idea to review the commit messages one last time, as the Git project expects them in a quite specific form:

  • the lines should not exceed 76 columns,
  • the first line should be like a header and typically start with a prefix like "tests:" or "revisions:" to state which subsystem the change is about, and
  • the commit messages' body should be describing the "why?" of the change.
  • Finally, the commit messages should end in a Signed-off-by: line matching the commits' author.

It is in general a good idea to await the automated test ("Checks") in this Pull Request before contributing the patches, e.g. to avoid trivial issues such as unportable code.

Contributing the patches

Before you can contribute the patches, your GitHub username needs to be added to the list of permitted users. Any already-permitted user can do that, by adding a comment to your PR of the form /allow. A good way to find other contributors is to locate recent pull requests where someone has been /allowed:

Both the person who commented /allow and the PR author are able to /allow you.

An alternative is the channel #git-devel on the Libera Chat IRC network:

<newcontributor> I've just created my first PR, could someone please /allow me? https://github.com/gitgitgadget/git/pull/12345
<veteran> newcontributor: it is done
<newcontributor> thanks!

Once on the list of permitted usernames, you can contribute the patches to the Git mailing list by adding a PR comment /submit.

If you want to see what email(s) would be sent for a /submit request, add a PR comment /preview to have the email(s) sent to you. You must have a public GitHub email address for this. Note that any reviewers CC'd via the list in the PR description will not actually be sent emails.

After you submit, GitGitGadget will respond with another comment that contains the link to the cover letter mail in the Git mailing list archive. Please make sure to monitor the discussion in that thread and to address comments and suggestions (while the comments and suggestions will be mirrored into the PR by GitGitGadget, you will still want to reply via mail).

If you do not want to subscribe to the Git mailing list just to be able to respond to a mail, you can download the mbox from the Git mailing list archive (click the (raw) link), then import it into your mail program. If you use GMail, you can do this via:

curl -g --user "<EMailAddress>:<Password>" \
    --url "imaps://imap.gmail.com/INBOX" -T /path/to/raw.txt

To iterate on your change, i.e. send a revised patch or patch series, you will first want to (force-)push to the same branch. You probably also want to modify your Pull Request description (or title). It is a good idea to summarize the revision by adding something like this to the cover letter (read: by editing the first comment on the PR, i.e. the PR description):

Changes since v1:
- Fixed a typo in the commit message (found by ...)
- Added a code comment to ... as suggested by ...
...

To send a new iteration, just add another PR comment with the contents: /submit.

Need help?

New contributors who want advice are encouraged to join git-mentoring@googlegroups.com, where volunteers who regularly contribute to Git are willing to answer newbie questions, give advice, or otherwise provide mentoring to interested contributors. You must join in order to post or view messages, but anyone can join.

You may also be able to find help in real time in the developer IRC channel, #git-devel on Libera Chat. Remember that IRC does not support offline messaging, so if you send someone a private message and log out, they cannot respond to you. The scrollback of #git-devel is archived, though.

@aryangupta701
Copy link
Author

could someone tell why is it failing?

@aryangupta701
Copy link
Author

/preview

Copy link

gitgitgadget bot commented Feb 28, 2024

Error: User aryangupta701 is not yet permitted to use GitGitGadget

@aryangupta701
Copy link
Author

@dscho can you please allow me

Copy link

gitgitgadget bot commented Feb 28, 2024

Invalid author email in d629374: "87857234+aryangupta701@users.noreply.github.com"

@dscho
Copy link
Member

dscho commented Feb 28, 2024

Sure, and can you please fix the commit message? Follow the advice in Documentation/SubmittingPatches.

@dscho
Copy link
Member

dscho commented Feb 28, 2024

/allow

Copy link

gitgitgadget bot commented Feb 28, 2024

User aryangupta701 is now allowed to use GitGitGadget.

WARNING: aryangupta701 has no public email address set on GitHub;
GitGitGadget needs an email address to Cc: you on your contribution, so that you receive any feedback on the Git mailing list. Go to https://github.com/settings/profile to make your preferred email public to let GitGitGadget know which email address to use.

@dscho
Copy link
Member

dscho commented Feb 28, 2024

@aryangupta701 let's have a closer look at the commit messages:

tests: modernize the test script

Signed-off-by: aryangupta701 <garyan447@gmail.com>

It is always good to have a look around to see how other people did things. So let's look at the commit message of the commit that touched the same file before you: c150064. The commit message looks like this:

leak tests: run various built-in tests in t00*.sh SANITIZE=leak

Mark various existing tests in t00*.sh that invoke git built-ins with
TEST_PASSES_SANITIZE_LEAK=true as passing when git is compiled with
SANITIZE=leak.

They'll now be listed as running under the
"GIT_TEST_PASSING_SANITIZE_LEAK=true" test mode (the "linux-leaks" CI
target).

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

You can probably spot quite a few differences between those two commit messages, right? Since the latter has been accepted, it would be good to align your commit messages with the style of that commit message.

In particular, you might find https://github.blog/2022-06-30-write-better-commits-build-better-projects/ illuminating.

@aryangupta701
Copy link
Author

thanks a lot @dscho

@aryangupta701
Copy link
Author

@dscho is it better now? Your suggestions will be appreciated.

@aryangupta701
Copy link
Author

/preview

Copy link

gitgitgadget bot commented Feb 28, 2024

Preview email sent as pull.1675.git.1709144415499.gitgitgadget@gmail.com

@aryangupta701
Copy link
Author

why does a random test keeps on failing? Is this a known issue?

test_expect_success \
"Racy GIT trial #$trial part A" \
'test "" != "$files"'
test_expect_success 'Racy GIT trial #$trial part A' '
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The current standard is not to spell GIT in all-upper-case letters ;-)

Also, while the commit message is better, I still would suggest reading https://github.blog/2022-06-30-write-better-commits-build-better-projects/ and following its advice. In particular the part about Intent, Context, Implementation and Justification. Remember, this here patch contribution is just a practice run, so you might as well practice writing good commit messages. Because when it comes to more complex contributions, you will have to write better commit messages. Finally:

Signed-off-by: aryangupta701 garyan447@gmail.com

I thought your name was "Aryan Gupta", not "aryangupta701"? If so, please replace the part before the email address.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am very grateful for your guidance. I will read through the blog carefully. Also is the current standard for git is "git" or "Git"?

Copy link

gitgitgadget bot commented Feb 28, 2024

There are issues in commit c543e75:
tests: modernize the test script t0010-racy-git.sh
Lines in the body of the commit messages should be wrapped between 60 and 76 characters.
Indented lines, and lines without whitespace, are exempt

Copy link

gitgitgadget bot commented Feb 28, 2024

There are issues in commit 593d639:
tests: modernize the test script t0010-racy-git.sh
Lines in the body of the commit messages should be wrapped between 60 and 76 characters.
Indented lines, and lines without whitespace, are exempt

@aryangupta701
Copy link
Author

/preview

Copy link

gitgitgadget bot commented Feb 28, 2024

Preview email sent as pull.1675.git.1709163526788.gitgitgadget@gmail.com

@aryangupta701
Copy link
Author

can I submit this patch now? @dscho

@dscho
Copy link
Member

dscho commented Feb 29, 2024

Looks much better now! Go ahead and submit:-)

@aryangupta701
Copy link
Author

/submit

Copy link

gitgitgadget bot commented Feb 29, 2024

Submitted as pull.1675.git.1709209435242.gitgitgadget@gmail.com

To fetch this version into FETCH_HEAD:

git fetch https://github.com/gitgitgadget/git/ pr-1675/aryangupta701/test-modernize-v1

To fetch this version to local tag pr-1675/aryangupta701/test-modernize-v1:

git fetch --no-tags https://github.com/gitgitgadget/git/ tag pr-1675/aryangupta701/test-modernize-v1

Copy link

gitgitgadget bot commented Mar 6, 2024

Preview email sent as pull.1675.v4.git.1709716350994.gitgitgadget@gmail.com

@aryangupta701
Copy link
Author

/submit

Copy link

gitgitgadget bot commented Mar 6, 2024

Submitted as pull.1675.v4.git.1709716446874.gitgitgadget@gmail.com

To fetch this version into FETCH_HEAD:

git fetch https://github.com/gitgitgadget/git/ pr-1675/aryangupta701/test-modernize-v4

To fetch this version to local tag pr-1675/aryangupta701/test-modernize-v4:

git fetch --no-tags https://github.com/gitgitgadget/git/ tag pr-1675/aryangupta701/test-modernize-v4

Copy link

gitgitgadget bot commented Mar 6, 2024

This branch is now known as ag/t0010-modernize.

Copy link

gitgitgadget bot commented Mar 6, 2024

This patch series was integrated into seen via git@3208b89.

@gitgitgadget gitgitgadget bot added the seen label Mar 6, 2024
Copy link

gitgitgadget bot commented Mar 7, 2024

This patch series was integrated into seen via git@a89c33c.

Copy link

gitgitgadget bot commented Mar 7, 2024

This patch series was integrated into seen via git@34c1d1e.

Copy link

gitgitgadget bot commented Mar 7, 2024

On the Git mailing list, Christian Couder wrote (reply to this):

On Wed, Mar 6, 2024 at 10:46 AM Aryan Gupta via GitGitGadget
<gitgitgadget@gmail.com> wrote:
>
> From: Aryan Gupta <garyan447@gmail.com>
>
> Modernize the formatting of the test script to align with current
> standards and improve its overall readability.
>
> Signed-off-by: Aryan Gupta <garyan447@gmail.com>
> ---
>     [GSOC][PATCH] Modernize a test script
>
> Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-1675%2Faryangupta701%2Ftest-modernize-v4
> Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-1675/aryangupta701/test-modernize-v4
> Pull-Request: https://github.com/gitgitgadget/git/pull/1675
>
> Range-diff vs v3:
>
>  1:  05ee9e8a458 = 1:  14c7137baea tests: modernize the test script t0010-racy-git.sh

This tells us that nothing changed in the patch since v3, so we can
only wonder why you sent this v4.

Did you fix some headers? Please explain.

>  t/t0010-racy-git.sh | 31 +++++++++++++++----------------
>  1 file changed, 15 insertions(+), 16 deletions(-)

Otherwise, the patch looks good to me. Thanks.

Copy link

gitgitgadget bot commented Mar 7, 2024

User Christian Couder <christian.couder@gmail.com> has been added to the cc: list.

Copy link

gitgitgadget bot commented Mar 7, 2024

On the Git mailing list, Aryan Gupta wrote (reply to this):

On Thu, Mar 7, 2024 at 2:28 PM Christian Couder
<christian.couder@gmail.com> wrote:
>
> On Wed, Mar 6, 2024 at 10:46 AM Aryan Gupta via GitGitGadget
> <gitgitgadget@gmail.com> wrote:
> >
> > From: Aryan Gupta <garyan447@gmail.com>
> >
> > Modernize the formatting of the test script to align with current
> > standards and improve its overall readability.
> >
> > Signed-off-by: Aryan Gupta <garyan447@gmail.com>
> > ---
> >     [GSOC][PATCH] Modernize a test script
> >
> > Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-1675%2Faryangupta701%2Ftest-modernize-v4
> > Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-1675/aryangupta701/test-modernize-v4
> > Pull-Request: https://github.com/gitgitgadget/git/pull/1675
> >
> > Range-diff vs v3:
> >
> >  1:  05ee9e8a458 = 1:  14c7137baea tests: modernize the test script t0010-racy-git.sh
>
> This tells us that nothing changed in the patch since v3, so we can
> only wonder why you sent this v4.
>
> Did you fix some headers? Please explain.
>
Hey. Sorry for making a lot of mistakes in my emails.

I thought that there were some bugs in GGG due to which it sent some
headers which were not syntactically correct. So I tried sending it again.
And that was the whole purpose of this.

> >  t/t0010-racy-git.sh | 31 +++++++++++++++----------------
> >  1 file changed, 15 insertions(+), 16 deletions(-)
>
> Otherwise, the patch looks good to me. Thanks.

Copy link

gitgitgadget bot commented Mar 7, 2024

On the Git mailing list, Junio C Hamano wrote (reply to this):

Aryan Gupta <garyan447@gmail.com> writes:

> I thought that there were some bugs in GGG due to which it sent some
> headers which were not syntactically correct. So I tried sending it again.
> And that was the whole purpose of this.

I was wondering about the same thing.  I still see an unwanted "[ ]"
around Kristoffer's e-mail address that will break responding to the
message in your [PATCH v4] e-mail that can be seen at

  https://lore.kernel.org/git/pull.1675.v4.git.1709716446874.gitgitgadget@gmail.com/raw

so, the experiment revealed that it did send some headers were
broken.

Thanks for a clarification.

Copy link

gitgitgadget bot commented Mar 7, 2024

On the Git mailing list, Junio C Hamano wrote (reply to this):

Junio C Hamano <gitster@pobox.com> writes:

> I was wondering about the same thing.  I still see an unwanted "[ ]"
> around Kristoffer's e-mail address that will break responding to the
> message in your [PATCH v4] e-mail that can be seen at
>
>   https://lore.kernel.org/git/pull.1675.v4.git.1709716446874.gitgitgadget@gmail.com/raw
>
> so, the experiment revealed that it did send some headers were
> broken.

This does not necessarily mean GGG is broken.  The majority of the
patches I see here from GGG are without these funny [square-bracket]
around addresses at all, and this was the only patch (or it is
possible that your other patches may have had the same issue; I do
not remember) with that problem.  It might be caused by what you
feed GGG (e.g., the messages you give it in your pull request) that
caused GGG to hiccup, perhaps?

Copy link

gitgitgadget bot commented Mar 7, 2024

On the Git mailing list, Aryan Gupta wrote (reply to this):

On Thu, Mar 7, 2024 at 7:30 PM Junio C Hamano <gitster@pobox.com> wrote:
>
> Junio C Hamano <gitster@pobox.com> writes:
>
> > I was wondering about the same thing.  I still see an unwanted "[ ]"
> > around Kristoffer's e-mail address that will break responding to the
> > message in your [PATCH v4] e-mail that can be seen at
> >
> >   https://lore.kernel.org/git/pull.1675.v4.git.1709716446874.gitgitgadget@gmail.com/raw
> >
> > so, the experiment revealed that it did send some headers were
> > broken.
>
> This does not necessarily mean GGG is broken.  The majority of the
> patches I see here from GGG are without these funny [square-bracket]
> around addresses at all, and this was the only patch (or it is
> possible that your other patches may have had the same issue; I do
> not remember) with that problem.  It might be caused by what you
> feed GGG (e.g., the messages you give it in your pull request) that
> caused GGG to hiccup, perhaps?
>
Ohh yes. I think I got the problem. I have fixed it. Can I try sending
the patch again now?

Copy link

gitgitgadget bot commented Mar 8, 2024

This patch series was integrated into seen via git@fc6f60e.

Copy link

gitgitgadget bot commented Mar 8, 2024

This patch series was integrated into next via git@38339ab.

@gitgitgadget gitgitgadget bot added the next label Mar 8, 2024
Copy link

gitgitgadget bot commented Mar 8, 2024

There was a status update in the "New Topics" section about the branch ag/t0010-modernize on the Git mailing list:

GSoC practice to modernize a test script.

Will merge to 'master'.
source: <pull.1675.v3.git.1709676557639.gitgitgadget@gmail.com>

Copy link

gitgitgadget bot commented Mar 9, 2024

This patch series was integrated into seen via git@63e4af7.

Copy link

gitgitgadget bot commented Mar 10, 2024

This patch series was integrated into seen via git@152b3d5.

Copy link

gitgitgadget bot commented Mar 12, 2024

This patch series was integrated into seen via git@e9ca690.

Copy link

gitgitgadget bot commented Mar 12, 2024

There was a status update in the "Cooking" section about the branch ag/t0010-modernize on the Git mailing list:

GSoC practice to modernize a test script.

Will merge to 'master'.
source: <pull.1675.v3.git.1709676557639.gitgitgadget@gmail.com>

Copy link

gitgitgadget bot commented Mar 14, 2024

This patch series was integrated into seen via git@8658a7e.

Copy link

gitgitgadget bot commented Mar 14, 2024

This patch series was integrated into seen via git@ba970ea.

Copy link

gitgitgadget bot commented Mar 15, 2024

This patch series was integrated into seen via git@06ac518.

Copy link

gitgitgadget bot commented Mar 15, 2024

This patch series was integrated into master via git@06ac518.

Copy link

gitgitgadget bot commented Mar 15, 2024

This patch series was integrated into next via git@06ac518.

@gitgitgadget gitgitgadget bot added the master label Mar 15, 2024
@gitgitgadget gitgitgadget bot closed this Mar 15, 2024
Copy link

gitgitgadget bot commented Mar 15, 2024

Closed via 06ac518.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants