Closed (fixed)
Project:
Drush
Version:
5.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
11 Apr 2008 at 12:17 UTC
Updated:
9 Jun 2009 at 02:40 UTC
Jump to comment: Most recent file
On my laptop I have several sites named to the module(s) i'm building or testing.
This happens to site 'ubercart' when running drush pm update ubercart.
The untarring takes place in DRUPAL_ROOT==ubercart ~/www/ubercart instead of ~/www/ubercart/sites/ubercart/module
Patch included.
This patch contains more verbose logging in order to better pinpoint this.
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | 245416.patch | 862 bytes | clemens.tolboom |
| #1 | drush_pm_unwind_dir_245416.patch | 4.96 KB | clemens.tolboom |
Comments
Comment #1
clemens.tolboomPatch adds:
drush_pm_install_package()
- some verbose logging
- a drush_error when unsuccessful installing ... ie a full stop when installing multiple projects
drush_pm_update()
- verbose logging
- mkdir if check ... this was the start point for this bug
drush_pm_get_project_path()
- verbose logging
- fix for directory backtrace ... it was forward scanned instead of backwards.
Comment #2
moshe weitzman commentedDoes not apply anymore - sorry. Could you resubmit with just the bug fixes? The point of verbose in my mind is not to debug drush itself. It is to help a user when his command isn't working.
Comment #3
moshe weitzman commentedComment #4
clemens.tolboom(my setup is a little ruined ... so no patch)
The (offending) lines are in drush_pm_get_project_path
The bug is in calculating the $stop which finds the first occurance of $project where it should use (in my case) the last. Unless there are modules out there with their info files in directories like $project/$project/test.info
So I'm not sure whether this fix would not introduce a bug the other way around.
Comment #5
clemens.tolboomWhen having a site(s) setup like
- /var/www/annotate/sites/annotate/modules/annotate
the old algorithm would delete
- /var/www/annotate directory
and not the annotate module
- /var/www/annotate/sites/annotate/modules/annotate
which would be the usage scenario.
Comment #6
clemens.tolboomCould anybody be so kind to review this patch.
I know it's a weird problem having a website name the same as a module name but the code is 'so wrong' :p
And today I 'deleted' a local site again :-(
drush pm update ubercartdeleted my /var/www/ubercart/ site. It is fortunately a symlink.Comment #7
moshe weitzman commentedToo old. Please reopen if needed. Code has changed.