This file is indexed.

/usr/lib/python2.7/dist-packages/tidy/__init__.py is in python-utidylib 0.2-9build1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
"""The Tidy wrapper.
I am the main interface to TidyLib. This package supports processing HTML with
Tidy, with all the options that the tidy command line supports.

For more information on the tidy options, see the reference. These options can
be given as keyword arguments to parse and parseString, by changing dashes (-)
to underscores(_).

For example:

>>> import tidy
>>> options = dict(output_xhtml=1, add_xml_decl=1, indent=1, tidy_mark=0)
>>> print tidy.parseString('<Html>Hello Tidy!', **options)
<?xml version="1.0" encoding="us-ascii"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <title></title>
  </head>
  <body>
    Hello Tidy!
  </body>
</html>

For options like newline and output_encoding, which must be set to one of a
fixed number of choices, you can provide either the numeric or string version
of the choice; so both tidy.parseString('<HTML>foo</html>', newline=2) and
tidy.parseString('<HTML>foo</html>', newline='CR') do the same thing.  

There are no plans to support other features of TidyLib, such as document-tree
traversal, since Python has several quality DOM implementations. (The author
uses Twisted's implementation, twisted.web.microdom).
"""

try:
    dict(x=1)
except TypeError:
    raise ImportError("Python 2.3 or later is required to import this library.")

__all__ = ['error', 'lib']

from tidy.lib import parse, parseString
from tidy.error import *