Edgewall Software

Opened 11 years ago

Last modified 9 years ago

#11351 closed enhancement

Repository admin panel should indicate when repository path is not valid — at Version 10

Reported by: Ryan J Ollos Owned by: Ryan J Ollos
Priority: normal Milestone: 1.0.3
Component: admin/web Version:
Severity: normal Keywords:
Cc: Branch:
Release Notes:

Repository admin page indicates when a repository path is invalid by displaying the path in grey with the error in the title.

API Changes:
Internal Changes:

Description

The repository admin page should indicate when repository paths are invalid by graying out the entry. A warning can also be added when a repository path is saved that is not valid.

Change History (11)

by Ryan J Ollos, 10 years ago

Attachment: 20131119T193453.png added

comment:1 by Ryan J Ollos, 10 years ago

At first I had in mind something simple like this (log:rjollos.git:t11351):

However, we might be able to provide more detailed information. In this example the first 3 grayed-out links are due to (1), whereas the fourth grayed-out link is due to (2) (the error messages are shown as tooltips). If we added unique exceptions for the two cases, then we could gray-out the Type when the version control system is not properly enabled, and gray-out the Directory when it doesn't appear to be a version control repository. The exceptions could be something like: UnsupportedConnectorError and InvalidPathError.

  1. Unsupported version control system "svn": Can't find an appropriate component, maybe the corresponding plugin was not enabled?
  2. home/user/Workspace/11351 does not appear to be a Git repository

comment:2 by anonymous, 10 years ago

This would be great enhancement! two remarks, why this would be great:

  1. To me, corresponding to finally found documentation, git repositories don't look like listed above, but have to have the '/.git' subdir given, which is not quite clear from the UI and unusual for git users, isn't it?
  1. Repositories (Repositorys) UI has some strange effects in displaying resp. copy/paste behavior with hidden/ special characters. Explanation about 2.:

I started with some bad file permissions on git repositories leading to "Trac[PyGIT] ERROR: GIT control files missing" erros resp. "TracError: /home/auser/gitrepos/someproject/.git does not appear to be a Git repository" error message on trac-admin repository resync command.

After fixing this I then used the already given repo listings from UI, copied them, deleted the entries and readded them. Thus including some unvisible blanks, where in one case trailing blank was visible, when path was marked for copy and in one case I finally found it just in trac log file. One other effect, immediately visible after pasting path as copy from old entry has been, slahes got converted to <slash><dot> "/." or "/?" when copy it to some editor. This should have alerted me, but I failed with the blanks.

This leads to the misty situation, that only one of 3 repos worked, although all of them had correct permissions and have been created same way.

Finally let me say, I like trac and hope this comment is usefull to somebody!

My setup: Debian jessie(!), german localization, access via FF 26 using incorporated postrges and git packages

Systeminformationen

Paket Version
Trac 1.0.1
Babel 0.9.6
Docutils 0.11
Genshi 0.6 (with speedups)
GIT 1.8.4.3
mod_python 3.3.1
psycopg2 2.4.5
Pygments 1.6
Python 2.7.5+ (default, Sep 17 2013, 15:33:59) [GCC 4.8.1]
pytz 2012c
setuptools 0.6
jQuery 1.7.2

Installierte Plugins

TracAccountManager 0.4.3
Last edited 10 years ago by Jun Omae (previous) (diff)

in reply to:  2 comment:3 by Ryan J Ollos, 10 years ago

Milestone: next-stable-1.0.x1.0.3

Replying to anonymous:

  1. To me, corresponding to finally found documentation, git repositories don't look like listed above, but have to have the '/.git' subdir given, which is not quite clear from the UI and unusual for git users, isn't it?

This issue was addressed recently in #11297.

  1. Repositories (Repositorys) UI has some strange effects in displaying resp. copy/paste behavior with hidden/ special characters.

This will be handled in #11371.

Last edited 10 years ago by Ryan J Ollos (previous) (diff)

in reply to:  2 comment:4 by Ryan J Ollos, 10 years ago

Replying to anonymous:

  1. Repositories (Repositorys) UI has some strange effects in displaying resp. copy/paste behavior with hidden/ special characters.

I experienced today, when copying a path from the table on the /admin/versioncontrol/repository page into trac.ini, the result is: /home/<200b>user/<200b>Workspace/<200b>th10834/<200b>teo-rjollos.git.

comment:5 by Remy Blank, 10 years ago

FTR, these are zero-width spaces that I put there intentionally so that long paths are broken properly. I don't remember the exact details, but removing them either made the table larger than the page, or possibly the breaks were in unfortunate locations.

We already work around the copy-paste problem by removing zero-width spaces from certain input fields on the server side, maybe we should just remove them from all inputs. Or maybe there's a better way to solve the path-breaking problem that doesn't need adding special characters to the text.

comment:6 by Ryan J Ollos, 10 years ago

Stripping the zero-width spaces from input fields could be done as part of #11371, and then possibly extended to other realms.

comment:7 by Ryan J Ollos, 9 years ago

Status: newassigned

comment:8 by Ryan J Ollos, 9 years ago

Proposed changes in log:rjollos.git:t11351.2.

in reply to:  1 comment:9 by Ryan J Ollos, 9 years ago

Replying to rjollos:

However, we might be able to provide more detailed information. In this example the first 3 grayed-out links are due to (1), whereas the fourth grayed-out link is due to (2) (the error messages are shown as tooltips). If we added unique exceptions for the two cases, then we could gray-out the Type when the version control system is not properly enabled, and gray-out the Directory when it doesn't appear to be a version control repository. The exceptions could be something like: UnsupportedConnectorError and InvalidPathError.

  1. Unsupported version control system "svn": Can't find an appropriate component, maybe the corresponding plugin was not enabled?
  2. home/user/Workspace/11351 does not appear to be a Git repository

Providing detailed information on the repository admin page for the error described in (1) will probably be addressed in #11713.

Last edited 9 years ago by Ryan J Ollos (previous) (diff)

comment:10 by Ryan J Ollos, 9 years ago

Release Notes: modified (diff)

Committed to 1.0-stable in [13605] and merged to trunk in [13606]. Documentation updated in TracDev/Exceptions@12.

Next I'll prepare a patch for the MercurialPlugin.

Note: See TracTickets for help on using tickets.