bzrlib.tests.blackbox.test_init.TestSFTPInit fails when run alone

John Arbash Meinel john at arbash-meinel.com
Wed Jul 18 19:27:16 BST 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Andrew Bennetts wrote:
> When running just the blackbox tests I see the following failure:
> 
> ----
> $ ./bzr --no-plugins selftest bzrlib.tests.blackbox.test_init.TestSFTPInit
> [...]
> 
> FAIL: blackbox.test_init.TestSFTPInit.test_init
>     not equal:
> a = ''
> b = "/var/lib/python-support/python2.5/paramiko/message.py:226: DeprecationWarning: integer argument expected, got float\n  self.packet.write(struct.pack('>I', n))\n"
> ----
> 
> This doesn't happen in the full run, because the deprecation warning is only
> shown once and gets triggered earlier when it is harmless.
> 
> Using a newer version of paramiko solves this particular problem, but the
> general issue is that deprecation warnings should not affect the result of
> blackbox tests.  If people agree, I'll file a bug about this (probably with
> importance "low").

Well, it sounds like something we will run into in some sort of an sftp
test if it doesn't happen here. Since PQM runs with -Werror. Is it just
that dapper paramiko with python2.4 doesn't cause this warning?

> 
> Also, it occurs to me that arguably deprecation warnings should not be shown to
> users at all.  Users can't really do anything sensible about API warnings except
> guess that upgrading their libraries *might* fix the problem.  It's developers
> (and packagers) that ought to be informed, not end users.  Perhaps distributions
> like Ubuntu should be suppressing DeprecationWarnings by default in released
> versions, and only display them by default for development versions?
> 
> -Andrew.
> 

That seems reasonable. We could even do in in 'bzr' itself with a custom
filter added. Or set the #! line to be:

/bin/env python -Wignore

Though I'm not sure if /bin/env passes parameters correctly on all
platforms.

John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGnluEJdeBCYSNAAMRAoBlAJ9yj7JGzu0V4+u4BAxajtDoXItC8wCgqd30
G38uD4KyoFyRhCLXhUfuoQI=
=fixP
-----END PGP SIGNATURE-----



More information about the bazaar mailing list