fritzo / livecoding

Automatically exported from code.google.com/p/livecoding
Other
0 stars 0 forks source link

Failures in test_reloading.py on py 2.5/2.6 os x leopard #7

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
on python 2.5.4, livecoding 0.2, on mac os x leopard:

$ python test_reloading.py 
WARNING:root:TODO, implement leakage compatibility case
............E.E
======================================================================
ERROR: testUpdateSameFileReload_ClassFunctionUpdate
(__main__.CodeReloadingObstacleTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "test_reloading.py", line 451, in
testUpdateSameFileReload_ClassFunctionUpdate
    self.failUnless(ret.defaults == (True,), "Function argument default
value not updated")
AttributeError: 'tuple' object has no attribute 'defaults'

======================================================================
ERROR: testUpdateSameFileReload_FunctionUpdate
(__main__.CodeReloadingObstacleTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "test_reloading.py", line 551, in
testUpdateSameFileReload_FunctionUpdate
    newScriptFile = self.ReloadScriptFile(scriptDirectory, scriptDirPath,
"functions.py", mangleCallback=cb)
  File "test_reloading.py", line 100, in ReloadScriptFile
    result = self.codeReloader.ReloadScript(oldScriptFile)
  File "/Library/Python/2.5/site-packages/livecoding/reloader.py", line
126, in ReloadScript
    newScriptFile = self.CreateNewScript(oldScriptFile)
  File "/Library/Python/2.5/site-packages/livecoding/reloader.py", line
142, in CreateNewScript
    newScriptFile = scriptDirectory.LoadScript(filePath, namespacePath)
  File "/Library/Python/2.5/site-packages/livecoding/namespace.py", line
316, in LoadScript
    return self.scriptFileClass(filePath, namespacePath)
  File "/Library/Python/2.5/site-packages/livecoding/namespace.py", line
29, in __init__
    self.Load(filePath)
  File "/Library/Python/2.5/site-packages/livecoding/namespace.py", line
38, in Load
    self.codeObject = compile(script, self.filePath, "exec")
  File "/Users/sa/Code/src/livecoding/scripts/functions.py", line 2

   ^
SyntaxError: invalid syntax

----------------------------------------------------------------------
Ran 15 tests in 0.379s

on python 2.6.2, livecoding 0.2, on mac os x leopard:

$ python2.6 test_reloading.py 
WARNING:root:TODO, implement leakage compatibility case
..F...........E
======================================================================
ERROR: testUpdateSameFileReload_FunctionUpdate
(__main__.CodeReloadingObstacleTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "test_reloading.py", line 551, in
testUpdateSameFileReload_FunctionUpdate
    newScriptFile = self.ReloadScriptFile(scriptDirectory, scriptDirPath,
"functions.py", mangleCallback=cb)
  File "test_reloading.py", line 100, in ReloadScriptFile
    result = self.codeReloader.ReloadScript(oldScriptFile)
  File "/Users/sa/Code/src/livecoding/reloader.py", line 126, in ReloadScript
    newScriptFile = self.CreateNewScript(oldScriptFile)
  File "/Users/sa/Code/src/livecoding/reloader.py", line 142, in
CreateNewScript
    newScriptFile = scriptDirectory.LoadScript(filePath, namespacePath)
  File "/Users/sa/Code/src/livecoding/namespace.py", line 316, in LoadScript
    return self.scriptFileClass(filePath, namespacePath)
  File "/Users/sa/Code/src/livecoding/namespace.py", line 29, in __init__
    self.Load(filePath)
  File "/Users/sa/Code/src/livecoding/namespace.py", line 38, in Load
    self.codeObject = compile(script, self.filePath, "exec")
  File "/Users/sa/Code/src/livecoding/scripts/functions.py", line 2

   ^
SyntaxError: invalid syntax

======================================================================
FAIL: testFileChangeDetection (__main__.CodeReloaderSupportTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "test_reloading.py", line 788, in testFileChangeDetection
    self.failUnless(game.FileChangeFunction.__doc__ == " new version ",
"Updated function doc string value still the original one")
AssertionError: Updated function doc string value still the original one

----------------------------------------------------------------------
Ran 15 tests in 0.416s

FAILED (failures=1, errors=1)

Original issue reported on code.google.com by alia_kho...@yahoo.com on 20 Apr 2009 at 8:46

GoogleCodeExporter commented 9 years ago
The tuple error is 2.6 functionality reliance.  This was addressed in the other 
bug.  

The syntax error is not reproducible.

Original comment by richard.m.tew@gmail.com on 20 Apr 2009 at 10:44