fnp
/
redakcja.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
FIX: Nie działało zapisywanie z powodu błędu w formularzu.
[redakcja.git]
/
lib
/
wlrepo
/
__init__.py
diff --git
a/lib/wlrepo/__init__.py
b/lib/wlrepo/__init__.py
index
430e59f
..
0f373d4
100644
(file)
--- a/
lib/wlrepo/__init__.py
+++ b/
lib/wlrepo/__init__.py
@@
-18,7
+18,7
@@
class Library(object):
"""Retrieve a document in the specified revision."""
pass
"""Retrieve a document in the specified revision."""
pass
- def document(self, docid, user=None):
+ def document(self, docid, user=None
, rev='latest'
):
"""Retrieve a document from a library."""
pass
"""Retrieve a document from a library."""
pass
@@
-105,9
+105,16
@@
class LibraryException(Exception):
Exception.__init__(self, msg)
self.cause = cause
Exception.__init__(self, msg)
self.cause = cause
+class UpdateException(LibraryException):
+ pass
+
class RevisionNotFound(LibraryException):
def __init__(self, rev):
LibraryException.__init__(self, "Revision %r not found." % rev)
class RevisionNotFound(LibraryException):
def __init__(self, rev):
LibraryException.__init__(self, "Revision %r not found." % rev)
+
+class RevisionMismatch(LibraryException):
+ def __init__(self, fdi, rev):
+ LibraryException.__init__(self, "No revision %r for document %r." % (rev, fdi))
class EntryNotFound(LibraryException):
def __init__(self, rev, entry, guesses=[]):
class EntryNotFound(LibraryException):
def __init__(self, rev, entry, guesses=[]):