Edgewall Software
Modify

Opened 15 years ago

Closed 15 years ago

#408 closed defect (fixed)

Failing tests with Trac 0.11.5rc1, Darwin, Python 2.4

Reported by: osimons Owned by: osimons
Priority: major Milestone: 0.6
Component: General Version: dev
Keywords: Cc:
Operating System: Mac OS X

Description

Latest (r648) gives two errors on my development setup. Tests also fails for r641, so failures are not caused by my committs. Still, need to look at why (suspecting some change in recent Trac):

======================================================================
ERROR: test_process_config_changes (bitten.tests.admin.BuildMasterAdminPageProviderTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/simon/dev/projects/bitten/repos/svn-bitten-trunk/bitten/tests/admin.py", line 106, in test_process_config_changes
    provider.render_admin_panel(req, 'bitten', 'master', '')
  File "/Users/simon/dev/projects/bitten/repos/svn-bitten-trunk/bitten/admin.py", line 40, in render_admin_panel
    self._save_config_changes(req, master)
  File "/Users/simon/dev/projects/bitten/repos/svn-bitten-trunk/bitten/admin.py", line 81, in _save_config_changes
    if logs_dir != master.logs_dir:
  File "/Users/simon/dev/projects/bitten/env-bitten/lib/python2.4/site-packages/Trac-0.11.5rc1-py2.4.egg/trac/config.py", line 441, in __get__
    value = self.accessor(section, self.name, self.default)
  File "/Users/simon/dev/projects/bitten/env-bitten/lib/python2.4/site-packages/Trac-0.11.5rc1-py2.4.egg/trac/config.py", line 391, in getpath
    path = os.path.join(os.path.dirname(base), path)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/posixpath.py", line 119, in dirname
    return split(p)[0]
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/posixpath.py", line 77, in split
    i = p.rfind('/') + 1
AttributeError: 'NoneType' object has no attribute 'rfind'

======================================================================
ERROR: test_process_get_request (bitten.tests.admin.BuildMasterAdminPageProviderTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/simon/dev/projects/bitten/repos/svn-bitten-trunk/bitten/tests/admin.py", line 93, in test_process_get_request
    self.assertEqual('log/bitten', master.logs_dir)
  File "/Users/simon/dev/projects/bitten/env-bitten/lib/python2.4/site-packages/Trac-0.11.5rc1-py2.4.egg/trac/config.py", line 441, in __get__
    value = self.accessor(section, self.name, self.default)
  File "/Users/simon/dev/projects/bitten/env-bitten/lib/python2.4/site-packages/Trac-0.11.5rc1-py2.4.egg/trac/config.py", line 391, in getpath
    path = os.path.join(os.path.dirname(base), path)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/posixpath.py", line 119, in dirname
    return split(p)[0]
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/posixpath.py", line 77, in split
    i = p.rfind('/') + 1
AttributeError: 'NoneType' object has no attribute 'rfind'

These errors do not show up in the builds for Bitten itself on Linux (build:1470) or Windows (build:1471), so not quite sure what the magic difference is (platform and/or versions).

I'll look into adding a new step to our own build config that just prints out relevant environment information (such as Trac, Python and Subversion versions). That would help when researching such differences.

Attachments (0)

Change History (3)

comment:1 Changed 15 years ago by osimons

Would anyone mind if I updated the Bitten build script to record environment information? Here is what works in my local testing at least - adding a new environment recorder as first step:

  <step id="environment" title="Record environment information">
    <sh:exec executable="python"
      args="-c 'import platform; print &quot;Python:&quot;, platform.python_version()'" />
    <sh:exec executable="python"
      args="-c 'import trac; print &quot;Trac:&quot;, trac.__version__'" />
  </step>

On my (failing) setup this step just prints:

Python: 2.4.6
Trac: 0.11.5rc1

comment:2 Changed 15 years ago by osimons

  • Version changed from 0.5.3 to dev

comment:3 Changed 15 years ago by osimons

  • Resolution set to fixed
  • Status changed from new to closed

Got it. Fixed in [651].

As for recording environment information, that would still be useful as this example shows. I'll keep a note of that and add it to our own builds at some stage.

Add Comment

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain osimons.
The resolution will be deleted. Next status will be 'reopened'.
Author


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

 
Note: See TracTickets for help on using tickets.