Opened 14 years ago

Closed 14 years ago

#2842 closed enhancement (fixed)

[with patch, positive review] PyLint unused variable cleanup for sage.rings.polynomial

Reported by: malb Owned by: cwitty
Priority: minor Milestone: sage-3.0
Component: misc Keywords: pylint
Cc: Merged in:
Authors: Reviewers:
Report Upstream: Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges

Description

The attached patch

  • removes unused variables,
  • removes unused imports,
  • defines undefined variables,

from several files in sage.rings.polynomial. It doesn't fix all issues in that module but this patch is still open for reviews.

Attachments (2)

pylint_polynomial_unused.patch (22.9 KB) - added by malb 14 years ago.
2842.patch (22.9 KB) - added by mhansen 14 years ago.

Download all attachments as: .zip

Change History (7)

Changed 14 years ago by malb

Changed 14 years ago by mhansen

comment:1 Changed 14 years ago by mhansen

  • Summary changed from [with patch, needs review] PyLint unused variable cleanup for sage.rings.polynomial to [with patch, positive review] PyLint unused variable cleanup for sage.rings.polynomial

Looks good to me. Apply just 2842.patch after #2844 .

comment:2 Changed 14 years ago by mabshoff

  • Summary changed from [with patch, positive review] PyLint unused variable cleanup for sage.rings.polynomial to [with patch, positive review, pending fixes] PyLint unused variable cleanup for sage.rings.polynomial

I am seeing one doctest failure on sage.math:

sage -t -long devel/sage/sage/rings/polynomial/multi_polynomial_libsingular.pyx
**********************************************************************
File "/scratch/mabshoff/release-cycle/sage-3.0.alpha3/tmp/multi_polynomial_libsingular.py", line 496:
    sage: R.<x,y> = QQ[]; S.<xx,yy> = GF(5)[]; S(5*x*y + x + 17*y)
Expected:
    xx + 2*yy
Got:
    xx + 0*yy
**********************************************************************

Martin will start poking around tomorrow.

Cheers,

Michael

comment:3 Changed 14 years ago by mabshoff

Note that post the #2844 merge you ought to apply 2842.patch.

Cheers,

Michael

comment:4 Changed 14 years ago by mabshoff

  • Summary changed from [with patch, positive review, pending fixes] PyLint unused variable cleanup for sage.rings.polynomial to [with patch, positive review] PyLint unused variable cleanup for sage.rings.polynomial

Oh well, just applying #2844 causes the above libSingular failures. So I am merging this patch since it works. I would recommend opening another ticket once somebody else can verify the same issue I see. A compile from scratch on sage.math ought to lead to the same result.

Cheers,

Michael

comment:5 Changed 14 years ago by mabshoff

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

Merged 2842.patch in Sage 3.0.alpha3

Note: See TracTickets for help on using tickets.