Ticket #403 (new defect)

Opened 17 months ago

Last modified 15 months ago

moap changelog diff fail with git.

Reported by: julien.lavergne@… Owned by: julien.lavergne@…
Priority: major Milestone: 0.2.7
Component: moap Version: 0.2.6
Keywords: Cc:

Description

moap 0.2.6 Ubuntu 8.10

When using moap changelog diff , moap crash with this traceback :

Traceback (most recent call last):
  File "/usr/bin/moap", line 28, in <module>
    sys.exit(main(sys.argv[1:]))
  File "/var/lib/python-support/python2.5/moap/main.py", line 13, in main
    ret = c.parse(argv)
  File "/var/lib/python-support/python2.5/moap/extern/command/command.py", line 265, in parse
    return self.subCommands[command].parse(args[1:])
  File "/var/lib/python-support/python2.5/moap/extern/command/command.py", line 265, in parse
    return self.subCommands[command].parse(args[1:])
  File "/var/lib/python-support/python2.5/moap/extern/command/command.py", line 247, in parse
    ret = self.do(args)
  File "/var/lib/python-support/python2.5/moap/command/cl.py", line 416, in do
    cl.parse(False)
  File "/var/lib/python-support/python2.5/moap/command/cl.py", line 223, in parse
    parseBlock(b)
  File "/var/lib/python-support/python2.5/moap/command/cl.py", line 207, in parseBlock
    if _nameRegex.match(block[0]):
IndexError: list index out of range

There is also a report on Debian with similar problem :  http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=520997

Traceback (most recent call last):
  File "/usr/bin/moap", line 28, in <module>
    sys.exit(main(sys.argv[1:]))
  File "/usr/lib/python2.5/site-packages/moap/main.py", line 13, in main
    ret = c.parse(argv)
  File "/usr/lib/python2.5/site-packages/moap/extern/command/command.py", line 265, in parse
    return self.subCommands[command].parse(args[1:])
  File "/usr/lib/python2.5/site-packages/moap/extern/command/command.py", line 265, in parse
    return self.subCommands[command].parse(args[1:])
  File "/usr/lib/python2.5/site-packages/moap/extern/command/command.py", line 247, in parse
    ret = self.do(args)
  File "/usr/lib/python2.5/site-packages/moap/command/cl.py", line 416, in do
    cl.parse(False)
  File "/usr/lib/python2.5/site-packages/moap/command/cl.py", line 223, in parse
    parseBlock(b)
  File "/usr/lib/python2.5/site-packages/moap/command/cl.py", line 213, in parseBlock
    entry.lines = block
UnboundLocalError: local variable 'entry' referenced before assignment

Attachments

Change History

Changed 17 months ago by anonymous

  • version changed from TRUNK to 0.2.6

Update the version

Changed 17 months ago by thomas

  • owner changed from thomas to julien.lavergne@…

Hi Julien,

these are separate bugs, they should be treated as such.

For the debian upstream bug, I would need to see the ChangeLog? (preferably the actual entry) that failed. I added a raise in [390] for that case.

Same for your original bug - I need a ChangeLog? entry.

I prefer you open a separate ticket for one of these, and attach the ChangeLog?'s to both bugs.

Changed 17 months ago by julien.lavergne@…

Ok let track the debian one here ( http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=520997). This is the information the user posted :

1 eddy@heidi ~/usr/src/osm/osm-helpers $ git st
# On branch master
# Changes to be committed:
#   (use "git reset HEAD <file>..." to unstage)
#
#       modified:   osm-upload-changes.cs
#
0 eddy@heidi ~/usr/src/osm/osm-helpers $ git di --cached
diff --git a/osm-upload-changes.cs b/osm-upload-changes.cs
index f878af1..83d8285 100644
--- a/osm-upload-changes.cs
+++ b/osm-upload-changes.cs
@@ -269,7 +269,7 @@ The current check resulted in these changes:
                                        else
                                                throw new Exception ("Invalid attribute: " + reader.Name);
                                }
-                               if (last_obj != null && last_obj.ID == id && last_obj.ObjectType == name) {
+                               if (last_obj != null && last_obj.ID == id) {
                                        obj = last_obj;
                                } else {
                                        // we didn't upload yet: do it now



Changed 17 months ago by julien.lavergne@…

I'll ask for the complete ChangeLog?

Changed 17 months ago by julien.lavergne@…

The Changelog can be found here :  http://repo.or.cz/w/osm-helpers.git?a=blob_plain;f=ChangeLog;h=b9ed4e67ee24dc5866d466c7ce14f9500caebed5;hb=HEAD%27

Step to reproduce:

0 eddy@heidi /tmp/buggy $ git clone git://repo.or.cz/osm-helpers.git
Initialized empty Git repository in /tmp/buggy/osm-helpers/.git/
remote: Counting objects: 363, done.
remote: Compressing objects: 100% (139/139), done.
remote: Total 363 (delta 217), reused 363 (delta 217)
Receiving objects: 100% (363/363), 166.47 KiB | 240 KiB/s, done.
Resolving deltas: 100% (217/217), done.
0 eddy@heidi /tmp/buggy $ cd osm-helpers/
/tmp/buggy/osm-helpers
0 eddy@heidi /tmp/buggy/osm-helpers $ echo >> DataBase.cs
0 eddy@heidi /tmp/buggy/osm-helpers $ moap changelog diff
Traceback (most recent call last):
  File "/usr/bin/moap", line 28, in <module>
    sys.exit(main(sys.argv[1:]))
  File "/usr/lib/python2.5/site-packages/moap/main.py", line 13, in main
    ret = c.parse(argv)
  File "/usr/lib/python2.5/site-packages/moap/extern/command/command.py", line 265, in parse
    return self.subCommands[command].parse(args[1:])
  File "/usr/lib/python2.5/site-packages/moap/extern/command/command.py", line 265, in parse
    return self.subCommands[command].parse(args[1:])
  File "/usr/lib/python2.5/site-packages/moap/extern/command/command.py", line 247, in parse
    ret = self.do(args)
  File "/usr/lib/python2.5/site-packages/moap/command/cl.py", line 416, in do
    cl.parse(False)
  File "/usr/lib/python2.5/site-packages/moap/command/cl.py", line 223, in parse
    parseBlock(b)
  File "/usr/lib/python2.5/site-packages/moap/command/cl.py", line 213, in parseBlock
    entry.lines = block
UnboundLocalError: local variable 'entry' referenced before assignment

Add/Change #403 (moap changelog diff fail with git.)

Author


E-mail address and user name can be saved in the Preferences.


Change Properties
<Author field>
Action
as new
as The resolution will be set. Next status will be 'closed'
to The owner will change from julien.lavergne@gmail.com. Next status will be 'new'
The owner will change from julien.lavergne@gmail.com to anonymous. Next status will be 'assigned'
 
Note: See TracTickets for help on using tickets.