Skip to content
This repository was archived by the owner on Oct 24, 2025. It is now read-only.

Commit 22c0709

Browse files
committed
Docs for errors
1 parent 37fe32c commit 22c0709

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

README.rst

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,9 @@ Use
3535
It takes a source ``string`` or a ``filename`` and returns the compiled
3636
CSS string.
3737

38+
If it fails for any reason (for example the given SASS has broken syntax)
39+
it will raise ``sass.CompileError``.
40+
3841
``string`` (required)
3942
The string of SASS source code to compile. It's exclusive to ``filename``
4043
parameter.
@@ -43,6 +46,9 @@ CSS string.
4346
The filename of SASS source code to compile. It's exclusive to ``string``
4447
parameter.
4548

49+
If the file does not exist or cannot be read it will raises
50+
``exceptions.IOError`` exception.
51+
4652
``output_style`` (optional)
4753
The coding style of the compiled result. Choose one in:
4854

@@ -58,6 +64,13 @@ CSS string.
5864
The path to find images.
5965

6066

67+
``sass.CompileError``
68+
---------------------
69+
70+
The exception type that is raised by ``sass.compile()``. It is a subtype
71+
of ``exceptions.ValueError``.
72+
73+
6174
Credit
6275
------
6376

0 commit comments

Comments
 (0)