Skip to content

Trouble with editing a new project repository #198

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

Closed
smn-automation opened this issue May 21, 2014 · 5 comments
Closed

Trouble with editing a new project repository #198

smn-automation opened this issue May 21, 2014 · 5 comments
Assignees
Labels

Comments

@smn-automation
Copy link

Steps to reproduce the problem:

-- Create a new repository within a project at https://<RedmineHost>/redmine/projects/XXXXXXXX/settings/repositories
-- Click on "Edit"
-- Enjoy the "Internal Error" at
https://<RedmineHost>redmine/repositories/6/edit which renders in the browser as

Internal error

An error occurred on the page you were trying to access.
If you continue to experience problems please contact your Redmine administrator for assistance.

If you are the Redmine administrator, check your log files for details about the error.

Back

and in the log as

Started GET "/redmine/repositories/6/edit" for <RedmineHost> at 2014-05-20 20:03:45 -0700
Processing by RepositoriesController#edit as HTML
  Parameters: {"id"=>"6"}
  Current user: $USER (id=3)
  Rendered plugins/redmine_git_hosting/app/views/common/_git_urls.html.erb (14.3ms)
  Rendered plugins/redmine_git_hosting/app/views/repositories/_form.html.erb (387.1ms)
  Rendered plugins/redmine_git_hosting/app/views/repositories/edit.html.erb within layouts/base (406.3ms)
Completed 500 Internal Server Error in 848.9ms

ActionView::Template::Error (undefined method `[]' for nil:NilClass):
    139: 
    140:       <p>
    141:         <%= label_tag  "", l(:label_repository_default_branch) %>
    142:         <% if [email protected]_record? && [email protected]? %>
    143:           <%= select_tag "extra[default_branch]", options_for_select(@repository.branches.collect{ |b| [b.to_s, b.to_s] }, :selected => @repository.branches.find{ |b| b.is_default}.to_s) %>
    144:         <% else %>
    145:           <span class="label label-info"><%= @repository.extra[:default_branch] %></span>
  lib/redmine/scm/adapters/git_adapter.rb:88:in `block (2 levels) in branches'
  lib/redmine/scm/adapters/git_adapter.rb:86:in `each_line'
  lib/redmine/scm/adapters/git_adapter.rb:86:in `block in branches'
  lib/redmine/scm/adapters/git_adapter.rb:85:in `branches'
  app/models/repository/git.rb:75:in `branches'
  app/helpers/application_helper.rb:1042:in `labelled_form_for'

This is true for any new repository I've tried to create (having just got the plugin working at all yesterday...)

Is there any place that shows screen shots of what the flow is supposed to look like for successful runs of the plugin? I looked and looked and looked for docs that show the workflow in its working, perfect state... I don't want to create a separate issue, but my next question is regarding what one should see when clicking the "Users" link right next to the "Edit" link (it doesn't error but it also doesn't show any users, and I've added several public keys for different users).

Thank you

@smn-automation
Copy link
Author

In good news, the repositories created by the Redmine_git_hosting plugin work great for cloning/pushing from my client computers using the command line--I successfully cloned, edited, pushed, and cloned elsewhere to see my changes using gitolite and a particular user's public key (nothing Redmine specific, just using the gitolite I'm familiar with pre-Redmine integration).

However, I still don't know why I'm getting an error in Redmine itself on the "Edit" page as explained previously, and why I don't see any users when clicking the "Users" link, and why the repository is shown as empty with the message Repository is empty. Get started by following the instructions below. when I go to https://<RedmineHost>/redmine/projects/XXXXXXXXXXX/repository (even though I know it is NOT empty).

Any place I should look next to troubleshoot? Any debug modes I can enable?

Thank you

@n-rodriguez n-rodriguez self-assigned this May 23, 2014
@n-rodriguez n-rodriguez added bug and removed bug labels May 23, 2014
@n-rodriguez
Copy link
Contributor

Hi there!

Any debug modes I can enable?

Yes. Enable hook debug to see what's happening when do git push (in Administration -> Redmine Git Hosting -> Hooks)

@n-rodriguez
Copy link
Contributor

Hi! Any news?

@n-rodriguez
Copy link
Contributor

No news, I close this issue.

@smn-automation
Copy link
Author

Haven't touched this for awhile, but seems to be working fine now--thank you sir!

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

No branches or pull requests

2 participants