#2369 closed defect (fixed)
Changeset detail displays propset on repo root as deletion
| Reported by: | Owned by: | Christian Boos | |
|---|---|---|---|
| Priority: | normal | Milestone: | 0.9.1 |
| Component: | version control | Version: | 0.9 |
| Severity: | minor | Keywords: | |
| Cc: | trac@… | Branch: | |
| Release Notes: | |||
| API Changes: | |||
| Internal Changes: | |||
Description
I noticed this while trying to set svn:ignore on the root of an svn repository, but the behavior is the same for any property.
To reproduce:
$ cd /path/to/wc/root $ svn propset "blah" "asd" . $ svn ci -m "Updated"
View the changeset detail, and it will display incorrectly as a deletion with no path, where it should display as a modification to a property on /. Other paths work fine, it's just the display on root that's broken. This exists in the latest version of Trac straight out of svn. trac-admin resync once the propset was several revs back did not have any effect.
Attachments (1)
Change History (8)
comment:1 by , 20 years ago
| Component: | general → version control |
|---|---|
| Milestone: | → 0.9.1 |
| Owner: | changed from to |
| Severity: | normal → minor |
| Status: | new → assigned |
comment:2 by , 20 years ago
Fixed by r2536.
(I'll close the ticket once the fix is ported to 0.9-stable, after a few days)
comment:3 by , 20 years ago
Forgot to say that you'll need to do a trac-admin resync
in order to fix the cached changeset information,
and probably you'll also need to force a reload in your browser
for viewing the updated changeset.
comment:4 by , 20 years ago
Yay! r2536 fixes the problem on the back end.
However, there is still a small related formatting glitch — propedits on root don't have hrefs or text. I'm attaching a patch which will make it assume root if no path is specified which fixes this in my (admittedly limited) testing. I'm not sure if this is the "right" way to solve it since it does introduce another glitch (detailed below). I can't think of an instance off the top of my head where assuming an empty path as / is bad.
- The behavior in trunk is to use
<a href=""></a>, which is not clickable and makes the<h2>collapse in the lower changeset portion (#file0) so you can't hop to its respective /browser link at all. - The behavior of the patch is to force the path to
/if it's empty, which does cause an inconsistency in display, but at least makes it clickable and render something. Example of inconsistency after applying the patch:- / (1 prop)
- path2 (1 prop)
- path2/path3 (1 prop)
The third option is to remove the links if there's no path, preventing goofy empty elements from being rendered.
What are your thoughts on the issue?
by , 20 years ago
| Attachment: | changeset-involving-root-r2536.patch added |
|---|
Diff from r2536 to enable links to root in changeset
comment:5 by , 20 years ago
Well, while doing the fix, what disturbed me was the
inconsistent naming of the "root": sometimes it's "/",
sometimes it's "" (empty) and sometimes it's None.
We should probably standardize on "/", as in source:/.
In that perspective, we need a second round of fixing,
which should enforce that in the versioncontrol layer,
leaving the web_ui/changeset.py unmodified.
I'll first merge some minor refactorings I did on the
vc-refactoring branch (log:@2460:2462) before going on.
comment:6 by , 20 years ago
| Resolution: | → fixed |
|---|---|
| Status: | assigned → closed |
Now in 0.9-stable (r2543).



Nice catch. Bug fix follows…