Failed to load application: cannot import name IFinishableConsumer #1926

Closed
opened 2013-03-01 02:01:39 +00:00 by bsd · 2 comments
Owner

The following error occurs when running tahoe using the latest Twisted (12.3.0), with SFTP frontend enabled

Unhandled Error
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/site-packages/twisted/application/app.py", line 652, in run
    runApp(config)
  File "/usr/local/lib/python2.7/site-packages/twisted/scripts/twistd.py", line 23, in runApp
    _SomeApplicationRunner(config).run()
  File "/usr/local/lib/python2.7/site-packages/twisted/application/app.py", line 386, in run
    self.application = self.createOrGetApplication()
  File "/usr/local/lib/python2.7/site-packages/twisted/application/app.py", line 451, in createOrGetApplication
    application = getApplication(self.config, passphrase)
--- <exception caught here> ---
  File "/usr/local/lib/python2.7/site-packages/twisted/application/app.py", line 462, in getApplication
    application = service.loadApplication(filename, style, passphrase)
  File "/usr/local/lib/python2.7/site-packages/twisted/application/service.py", line 405, in loadApplication
    application = sob.loadValueFromFile(filename, 'application', passphrase)
  File "/usr/local/lib/python2.7/site-packages/twisted/persisted/sob.py", line 210, in loadValueFromFile
    exec fileObj in d, d
  File "tahoe-client.tac", line 10, in <module>
    c = client.Client()
  File "/usr/local/lib/python2.7/site-packages/allmydata/client.py", line 155, in __init__
    self.init_sftp_server()
  File "/usr/local/lib/python2.7/site-packages/allmydata/client.py", line 436, in init_sftp_server
    from allmydata.frontends import sftpd
  File "/usr/local/lib/python2.7/site-packages/allmydata/frontends/sftpd.py", line 25, in <module>
    from twisted.internet.interfaces import IFinishableConsumer
exceptions.ImportError: cannot import name IFinishableConsumer

Failed to load application: cannot import name IFinishableConsumer

Replacing all references to IFinishableConsumer with IConsumer in allmydata/frontends/sftpd.py resolves the issue (at least cosmetically, no errors on startup). Probably would be a good idea to review the changes between the two modules for the long run.

The following error occurs when running `tahoe` using the latest Twisted (12.3.0), with SFTP frontend enabled ``` Unhandled Error Traceback (most recent call last): File "/usr/local/lib/python2.7/site-packages/twisted/application/app.py", line 652, in run runApp(config) File "/usr/local/lib/python2.7/site-packages/twisted/scripts/twistd.py", line 23, in runApp _SomeApplicationRunner(config).run() File "/usr/local/lib/python2.7/site-packages/twisted/application/app.py", line 386, in run self.application = self.createOrGetApplication() File "/usr/local/lib/python2.7/site-packages/twisted/application/app.py", line 451, in createOrGetApplication application = getApplication(self.config, passphrase) --- <exception caught here> --- File "/usr/local/lib/python2.7/site-packages/twisted/application/app.py", line 462, in getApplication application = service.loadApplication(filename, style, passphrase) File "/usr/local/lib/python2.7/site-packages/twisted/application/service.py", line 405, in loadApplication application = sob.loadValueFromFile(filename, 'application', passphrase) File "/usr/local/lib/python2.7/site-packages/twisted/persisted/sob.py", line 210, in loadValueFromFile exec fileObj in d, d File "tahoe-client.tac", line 10, in <module> c = client.Client() File "/usr/local/lib/python2.7/site-packages/allmydata/client.py", line 155, in __init__ self.init_sftp_server() File "/usr/local/lib/python2.7/site-packages/allmydata/client.py", line 436, in init_sftp_server from allmydata.frontends import sftpd File "/usr/local/lib/python2.7/site-packages/allmydata/frontends/sftpd.py", line 25, in <module> from twisted.internet.interfaces import IFinishableConsumer exceptions.ImportError: cannot import name IFinishableConsumer Failed to load application: cannot import name IFinishableConsumer ``` Replacing all references to IFinishableConsumer with IConsumer in allmydata/frontends/sftpd.py resolves the issue (at least cosmetically, no errors on startup). Probably would be a good idea to review the changes between the two modules for the long run.
tahoe-lafs added the
code-frontend
normal
defect
1.9.2
labels 2013-03-01 02:01:39 +00:00
tahoe-lafs added this to the undecided milestone 2013-03-01 02:01:39 +00:00
davidsarah commented 2013-03-01 02:49:38 +00:00
Author
Owner

Duplicate of #1525.

Duplicate of #1525.
tahoe-lafs added the
duplicate
label 2013-03-01 02:49:38 +00:00
tahoe-lafs modified the milestone from undecided to 1.10.0 2013-03-01 02:49:38 +00:00
davidsarah commented 2013-03-01 02:52:33 +00:00
Author
Owner

To work around this for now, edit the dependency for Twisted in src/allmydata/_auto_deps.py to "Twisted >= 11.0.0, <= 12.2.0".

To work around this for now, edit the dependency for Twisted in `src/allmydata/_auto_deps.py` to "Twisted >= 11.0.0, <= 12.2.0".
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Reference: tahoe-lafs/trac-2024-07-25#1926
No description provided.