Opened 8 years ago

Closed 8 years ago

#12085 closed defect (fixed)

Fix docstring in sage/crypto/boolean_function.pyx

Reported by: jdemeyer Owned by: mvngu
Priority: major Milestone: sage-4.8
Component: doctest coverage Keywords:
Cc: Merged in: sage-4.8.alpha3
Authors: Jeroen Demeyer, André Apitzsch Reviewers: Volker Braun
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Description (last modified by jdemeyer)

Needed for upgrade to Python 2.7.2 (#9958). There is a problem with the math block in

    def annihilator(self,d, dim = False):
        """
        Return (if it exists) an annihilator of the boolean function of
        degree at most `d`, that is a Boolean polynomial `g` such that

        .. math::

            f(x)g(x) = 0 \forall x.

This results in

docstring of sage.crypto.boolean_function:4: WARNING: Block quote ends without a blank line; unexpected unindent.

Note that the warning does not at all refer to the function "annihilator". I had to do a binary search in the .pyx file to find where the problem lies.

Attachments (1)

12085.patch (3.2 KB) - added by jdemeyer 8 years ago.

Download all attachments as: .zip

Change History (9)

comment:1 Changed 8 years ago by jdemeyer

  • Description modified (diff)

Attached patch improves the documentation, but unfortunately it does not fix the docbuild warning.

comment:2 Changed 8 years ago by jdemeyer

  • Description modified (diff)

comment:3 follow-up: Changed 8 years ago by aapitzsch

Have you tried the raw mode? That fixed a similar problem mentioned in #9608.

Changed 8 years ago by jdemeyer

comment:4 in reply to: ↑ 3 Changed 8 years ago by jdemeyer

  • Authors changed from Jeroen Demeyer to Jeroen Demeyer, André Apitzsch
  • Status changed from new to needs_review

Replying to aapitzsch:

Have you tried the raw mode? That fixed a similar problem mentioned in #9608.

Fantastic!

comment:5 follow-up: Changed 8 years ago by vbraun

  • Reviewers set to Volker Braun
  • Status changed from needs_review to positive_review

Yep, without raw mode the backslash will wreak havoc...

comment:6 in reply to: ↑ 5 ; follow-up: Changed 8 years ago by jdemeyer

Replying to vbraun:

Yep, without raw mode the backslash will wreak havoc...

True, but I'm still wondering why it works with Python 2.6 but not with Python 2.7.

comment:7 in reply to: ↑ 6 Changed 8 years ago by kcrisman

Yep, without raw mode the backslash will wreak havoc...

True, but I'm still wondering why it works with Python 2.6 but not with Python 2.7.

Yeah, that is weird... this is where it shows up, but \f has been one of these for quite a while... because I always have to do \\frac when using labels in plots :)

comment:8 Changed 8 years ago by jdemeyer

  • Merged in set to sage-4.8.alpha3
  • Resolution set to fixed
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.