Login | Register
My pages Projects Community openCollabNet

Discussions > users > Hook runs, error is not reported

Project highlights: :. Download .: :. Support .: :. FAQ .: :. Translations .: :. Donate .: :. Report Bug .:

tortoisesvn
Discussion topic

Hide all messages in topic

All messages in topic

Re: FYI: "svn import" works as expected

Author luebbe
Full name Lübbe Onken
Date 2012-05-06 23:58:54 PDT
Message 2012/5/7 Lübbe TortoiseSVN <luebbe.tortoises​vn at googlemail dot com​>

> Hi John D.
>
> 2012/5/4 John Doe <csj1411 at gmail dot com>
>
>> Mark Phippard suggested I try "snv import" to rule out bug in SVN server,
>> so I did.
>>
>> "svn import" works as expected. Post-commit hook is executed - I received
>> "Warning: post-commit hook failed (exit code 1) with no output." message.
>> So I guess this points to the problem in TortoiseSVN.
>>
>
> No, this doesn't point to a problem in TortoiseSVN. TortoiseSVN just
> prints out the message from the svn libraries.
>
> Your problem is either in the post-commit hook, which fails (exit code 1)
> without a message or your problem is in the data you are trying to commit,
> which make the post commit hook fail.
>
>
Ah ok, it was a problem in the repository browser. Blame me for not reading
all threads before replying, blame you for starting three threads for one
issue ...

Cheers
- Lübbe

--
Please help me get more space on Dropbox :)
https://www.dropbox.​com/referrals/NTIwMz​cxNjI5
       ___
  oo // \\ "De Chelonian Mobile"
 (_,\/ \_/ \ TortoiseSVN
   \ \_/_\_/> The coolest Interface to (Sub)Version Control
   /_/ \_\ http://tortoisesvn.net PGP Key ID 0x23F511AB
Attachments

Re: FYI: "svn import" works as expected

Author luebbe
Full name Lübbe Onken
Date 2012-05-06 23:55:55 PDT
Message Hi John D.

2012/5/4 John Doe <csj1411 at gmail dot com>

> Mark Phippard suggested I try "snv import" to rule out bug in SVN server,
> so I did.
>
> "svn import" works as expected. Post-commit hook is executed - I received
> "Warning: post-commit hook failed (exit code 1) with no output." message.
> So I guess this points to the problem in TortoiseSVN.
>

No, this doesn't point to a problem in TortoiseSVN. TortoiseSVN just prints
out the message from the svn libraries.

Your problem is either in the post-commit hook, which fails (exit code 1)
without a message or your problem is in the data you are trying to commit,
which make the post commit hook fail.

Cheers
- Lübbe

--
Please help me get more space on Dropbox :)
https://www.dropbox.​com/referrals/NTIwMz​cxNjI5
       ___
  oo // \\ "De Chelonian Mobile"
 (_,\/ \_/ \ TortoiseSVN
   \ \_/_\_/> The coolest Interface to (Sub)Version Control
   /_/ \_\ http://tortoisesvn.net PGP Key ID 0x23F511AB
Attachments

Re: Re: Pre-commit hook works, post-commit - doesn

Author levyam
Full name Andy Levy
Date 2012-05-04 13:47:52 PDT
Message PLEASE quote context in your replies so people know what's going on.

On Fri, May 4, 2012 at 4:38 PM, John Doe <csj1411 at gmail dot com> wrote:
> Server hooks. Are there client hooks? Where can I find more information on that?
>

Server hooks are independent of what client you're using. They execute
solely on the server, and as such questions about them are best
directed to the SVN Users mailing list.

A post-commit hook always "succeeds" - the error code returned by the
pre-commit hook is used just to determine whether or not to allow the
commit to proceed.

RE: Re: Hook runs, error is not reported

Author johndoe1411
Full name John Doe
Date 2012-05-04 13:46:35 PDT
Message So it was a bug!

And it's already fixed within a couple hours since reporting!!!

Makes me proud (even though I wasn't the one who fixed it) :D !

RE: Re: Pre-commit hook works, post-commit - doesn

Author johndoe1411
Full name John Doe
Date 2012-05-04 13:38:09 PDT
Message Server hooks. Are there client hooks? Where can I find more information on that?

Re: Pre-commit hook works, post-commit - doesn

Author simonlarge
Full name Simon Large
Date 2012-05-04 13:08:21 PDT
Message On 4 May 2012 17:19, John Doe <csj1411 at gmail dot com> wrote:
> I am using the latest version of TortoiseSVN on Windows Server 2008 R2 x64
>
> When I use Tortoise SVN in repo browser mode and add files to repository via repo browser UI pre-commit hook is executed (verified by putting "exit 1" in pre-commit.bat, commit will then fail with dialog box showing up with error code) but post-commit hook is not executed (verified by putting "exit 1" in post-commit.bat, no dialog with error code pops up after commit).
>
> If I check out folder to local drive, change some files and then do commit using Tortoise SVN Explorer shell extension post-commit hook is executed.
>
> I tried connecting to CollabNet Edge, Visual SVN, UberSVN and plain SVNSERVE servers and all exhibit the same  behavior. If pre-commit hook fires then post-commit hook should fire as well. It could be a problem on server end but I am not sure how to verify that.

Are you talking about client hooks or server hooks?

Simon

--
:       ___
:  oo  // \\      "De Chelonian Mobile"
: (_,\/ \_/ \     TortoiseSVN
:   \ \_/_\_/>    The coolest Interface to (Sub)Version Control
:   /_/   \_\     http://tortoisesvn.net

Re: Hook runs, error is not reported

Author steveking
Full name Stefan Küng
Date 2012-05-04 12:44:53 PDT
Message On 04.05.2012 20:22, John Doe wrote:
> Per suggestion of Mark Phippard I ran another test: I put "time /T>>c:\fff.txt" in post-commit hook.
>
> File is created both when "svn import" is used or when TSVN "Add file" is used. So I guess this means TSVN doesn't report error to the user (as I mentioned earlier error is reported when using "svn import")

Opened issue #289 for this:
http://code.google.c​om/p/tortoisesvn/iss​ues/detail?id=289

Stefan

--
        ___
   oo // \\ "De Chelonian Mobile"
  (_,\/ \_/ \ TortoiseSVN
    \ \_/_\_/> The coolest Interface to (Sub)Version Control
    /_/ \_\ http://tortoisesvn.net

Hook runs, error is not reported

Author johndoe1411
Full name John Doe
Date 2012-05-04 11:22:02 PDT
Message Per suggestion of Mark Phippard I ran another test: I put "time /T >>c:\fff.txt" in post-commit hook.

File is created both when "svn import" is used or when TSVN "Add file" is used. So I guess this means TSVN doesn't report error to the user (as I mentioned earlier error is reported when using "svn import")

FYI: "svn import" works as expected

Author johndoe1411
Full name John Doe
Date 2012-05-04 10:53:22 PDT
Message Mark Phippard suggested I try "snv import" to rule out bug in SVN server, so I did.

"svn import" works as expected. Post-commit hook is executed - I received "Warning: post-commit hook failed (exit code 1) with no output." message. So I guess this points to the problem in TortoiseSVN.

Pre-commit hook works, post-commit - doesn

Author johndoe1411
Full name John Doe
Date 2012-05-04 09:19:10 PDT
Message I am using the latest version of TortoiseSVN on Windows Server 2008 R2 x64

When I use Tortoise SVN in repo browser mode and add files to repository via repo browser UI pre-commit hook is executed (verified by putting "exit 1" in pre-commit.bat, commit will then fail with dialog box showing up with error code) but post-commit hook is not executed (verified by putting "exit 1" in post-commit.bat, no dialog with error code pops up after commit).

If I check out folder to local drive, change some files and then do commit using Tortoise SVN Explorer shell extension post-commit hook is executed.

I tried connecting to CollabNet Edge, Visual SVN, UberSVN and plain SVNSERVE servers and all exhibit the same behavior. If pre-commit hook fires then post-commit hook should fire as well. It could be a problem on server end but I am not sure how to verify that.
Messages per page: