Opened 8 years ago

Last modified 7 years ago

#5805 defect new

twisted.test.test_strcred fails on Python without pycrypto

Reported by: Thijs Triemstra Owned by:
Priority: normal Milestone:
Component: core Keywords:
Cc: Thijs Triemstra, James Broadhead Branch:
Author:

Description

When you run the tests without having pycrypto installed the following tests fail:

[ERROR]
Traceback (most recent call last):
  File "/home/thijs/workspaces/opensource/software/twisted/svn/Twisted/trunk/twisted/plugin.py", line 213, in getPlugins
    adapted = interface(plugin, None)
  File "/usr/local/lib/python2.6/dist-packages/zope.interface-4.0.1-py2.6-linux-x86_64.egg/zope/interface/interface.py", line 131, in __call__
    adapter = self._call_conform(conform)
  File "/usr/local/lib/python2.6/dist-packages/zope.interface-4.0.1-py2.6-linux-x86_64.egg/zope/interface/interface.py", line 494, in _call_conform
    return conform(self)
  File "/home/thijs/workspaces/opensource/software/twisted/svn/Twisted/trunk/twisted/plugin.py", line 68, in __conform__
    return self.load()
  File "/home/thijs/workspaces/opensource/software/twisted/svn/Twisted/trunk/twisted/plugin.py", line 63, in load
    return namedAny(self.dropin.moduleName + '.' + self.name)
  File "/home/thijs/workspaces/opensource/software/twisted/svn/Twisted/trunk/twisted/python/reflect.py", line 517, in namedAny
    obj = getattr(obj, n)
exceptions.AttributeError: 'module' object has no attribute 'theSSHKeyCheckerFactory'

twisted.test.test_strcred.TestAnonymousChecker.testAnonymousAccessSucceeds
twisted.test.test_strcred.TestAnonymousChecker.test_isChecker
twisted.test.test_strcred.TestCheckerOptions.test_createsDictionary
twisted.test.test_strcred.TestCheckerOptions.test_credInterfacesProvidesLists
twisted.test.test_strcred.TestCheckerOptions.test_displaysListCorrectly
twisted.test.test_strcred.TestCheckerOptions.test_displaysListCorrectly
twisted.test.test_strcred.TestCheckerOptions.test_displaysListCorrectly
twisted.test.test_strcred.TestCheckerOptions.test_invalidAuthError
twisted.test.test_strcred.TestCheckerOptions.test_invalidAuthError
twisted.test.test_strcred.TestCheckerOptions.test_invalidAuthError
twisted.test.test_strcred.TestCheckerOptions.test_listDoesNotDisplayDuplicates
twisted.test.test_strcred.TestLimitingInterfaces.test_helpAuthLimitsOutput
twisted.test.test_strcred.TestLimitingInterfaces.test_helpAuthTypeLimitsOutput
twisted.test.test_strcred.TestLimitingInterfaces.test_helpAuthTypeLimitsOutput
twisted.test.test_strcred.TestLimitingInterfaces.test_unsupportedInterfaceError
twisted.test.test_strcred.TestPublicAPI.test_emptyDescription
twisted.test.test_strcred.TestPublicAPI.test_emptyDescription
twisted.test.test_strcred.TestPublicAPI.test_emptyDescription
twisted.test.test_strcred.TestPublicAPI.test_invalidAuthType
twisted.test.test_strcred.TestPublicAPI.test_invalidAuthType
twisted.test.test_strcred.TestPublicAPI.test_invalidAuthType
twisted.test.test_strcred.TestStrcredFunctions.test_findCheckerFactories
twisted.test.test_strcred.TestStrcredFunctions.test_findCheckerFactories
twisted.test.test_strcred.TestUnixChecker.test_isChecker
twisted.test.test_strcred.TestUnixChecker.test_unixCheckerFailsPassword
twisted.test.test_strcred.TestUnixChecker.test_unixCheckerFailsUsername
twisted.test.test_strcred.TestUnixChecker.test_unixCheckerSucceeds
-------------------------------------------------------------------------------
Ran 7980 tests in 55.199s

FAILED (skips=1566, expectedFailures=11, errors=27, successes=6386)

Change History (8)

comment:1 Changed 8 years ago by Thijs Triemstra

Summary: Tests fail for Python without pycryptotwisted.test.test_strcred fails on Python without pycrypto

comment:2 Changed 8 years ago by Jean-Paul Calderone

Owner: set to Thijs Triemstra

This is at odds with buildbot's results. What's different about your environment?

comment:3 Changed 8 years ago by Thijs Triemstra

Python 2.6.7 (r267:88850, Aug 11 2011, 12:18:09) 
[GCC 4.6.1] on linux2

That's the system installed version on ubuntu 12.4 without pycrypto, pyasn1. The buildbot has pycrypto installed and is using python 2.6.1.

comment:4 Changed 8 years ago by Jean-Paul Calderone

Notice that the build I linked to runs trial with --without-module Crypto. That means that it effectively does not have pycrypto installed, for the purposes of the build.

comment:5 Changed 8 years ago by therve

This is because of the plugin cache. The following sequence of events reproduce it, on a system with pycrypto:

$ rm twisted/plugins/dropin.cache
$ trial twisted.test.test_strcred
$ trial --without-module Crypto twisted.test.test_strcred

comment:6 in reply to:  5 Changed 8 years ago by Thijs Triemstra

Cc: Thijs Triemstra added
Owner: Thijs Triemstra deleted

Replying to therve:

This is because of the plugin cache. The following sequence of events reproduce it, on a system with pycrypto:

$ rm twisted/plugins/dropin.cache
$ trial twisted.test.test_strcred
$ trial --without-module Crypto twisted.test.test_strcred

In that case I think something that needs to be added to the buildslave. Unassigning myself.

comment:7 Changed 7 years ago by Jean-Paul Calderone

#6376 was a duplicate of this. Note that it describes the same problem when a different Conch dependency is missing, pyasn1.

comment:8 Changed 7 years ago by James Broadhead

Cc: James Broadhead added
Note: See TracTickets for help on using tickets.