-
Notifications
You must be signed in to change notification settings - Fork 4
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
Write git commands which are run to the log #31
Comments
Hey @eudoxos, I will give you a new test version of the plugin printing the Git command that is being executed. Perhaps tomorrow morning. Sorry for the delay. Cheers |
Hey @eudoxos, I had a look at the problem and the code that raises the error is part of OpenProject, not directly in the plugin. It is the method
I suggest you to edit the file and add a few extra lines of code to print the command being executed. Then you can test it manually to check what error message the command returns. This:
should look like this:
Once you edit the file, restart OpenProject with:
Then have a look at the logs. With Cheers |
Hi Luis, very nice, thank you; I see this in the log:
Not sure how to reproduce this; what is the directory git is run in (--git-dir only includes relative path)? The repo exists in |
I tried with repository in a different project which works (one of the few, never knew why actually) and here, the full repo path is passed as argument (!!) thus the availability check succeeds:
|
I understand what the problem is. This issue is related to the upgrade of the plugin from OpenProject 4 where the paths to the repositories were relative. I need to rework this part to solve the problem, but it may take some time. Connect to MySQL as root:
Select your DB (assuming the name is
List of all your managed Gitolite repositories:
List of repositories without a full path (with wrong configuration):
Adding full path to repositories with wrong configuration (separated into two queries):
Checking repositories without a full path (with wrong configuration) again:
Cheers |
Hello Luis, thank you. I am mostly off internet for 2 weeks, so cannot test. May I suggest, though, that this modification of paths in the database be done as a part of the configuration recovery in plugin settings? That would seem quite a natural place for that. Not sure if just the old repos don't work, IIRC I was not able to open on I just created with OP5, but not sure now. Cheers, Vaclav
Sent from my Android device with K-9 Mail. Please excuse my brevity. |
That is a good idea; I will add the functionality to correct this issue (when upgrading the plugin from OP4 to OP5) in the recovery section as soon as I have the time. Let me know if you have solved the problem in your installation with the SQL scripts I provided. If that is the case, then I do not have to try to find more possible errors in the code. Cheers |
Hi @mabentwickeltsich, it worked, now I can all repos again. If you add this database modification to the recovery function, I am sure it will be useful for other people. Thanks for the precise instruction and help which I appreciate a lot! I still think logging git command being run could be enabled, but if it is an upstream issue, feel free to close this ticket. |
Hi, I am still experiencing issues with the plugin, but I am very limited in finding out what's wrong (and submitting better reports) as all I see in the log is:
but the log does not show what git command was being run and failed. Could that be added to the log, please? Then I can try running the command from command-line and check the error output (which could be also part of the log, perhaps). Thanks!
The text was updated successfully, but these errors were encountered: