darcs

Issue 2065 need friendly error when invalid regex in boring file

Title need friendly error when invalid regex in boring file
Priority feature Status resolved
Milestone Resolved in 2.10.0
Superseder Nosy List owst
Assigned To
Topics UI

Created on 2011-04-18.00:40:14 by owst, last changed 2012-04-20.19:46:27 by noreply.

Messages
msg13937 (view) Author: owst Date: 2011-04-18.00:40:13
Say you momentarily forget that boring needs to contain regexes, not
globs, and your boring file contains just:
*.whatever

Then executing `darcs wh -l` gives:
darcs failed:  Text.Regex.Posix.String died: (ReturnCode 13,"Invalid
preceding regular expression")

Can we make this slightly more user-friendly? The error is fairly
descriptive, but doesn't necessarily explain why and where it's come from.
msg13950 (view) Author: owst Date: 2011-04-20.01:06:54
N.B, you must be in a non-empty repo for the error to occur (touching a
single file, in a clean repo is enough), as a guess, I'd say this is due
to the regex only being used (and thus created) if there is a non-empty
tree to be searched.
msg13951 (view) Author: kowey Date: 2011-04-20.09:32:49
Yuck.  Funny it hasn't been reported before.  You're not the first one to 
find it.
msg15580 (view) Author: noreply Date: 2012-04-20.19:45:41
The following patch sent by Owen Stephens <darcs@owenstephens.co.uk> updated issue issue2065 with
status=has-patch

* resolve issue2065: filter and give warning for any malformed boring regexs. 
Ignore-this: cdfa5b72c74f87bc362463b4207adc63
msg15581 (view) Author: noreply Date: 2012-04-20.19:46:26
The following patch sent by Owen Stephens <darcs@owenstephens.co.uk> updated issue issue2065 with
status=resolved;resolvedin=2.10.0 HEAD

* resolve issue2065: filter and give warning for any malformed boring regexs. 
Ignore-this: cdfa5b72c74f87bc362463b4207adc63
History
Date User Action Args
2011-04-18 00:40:14owstcreate
2011-04-20 01:06:54owstsetmessages: + msg13950
2011-04-20 09:32:51koweysetstatus: unknown -> needs-implementation
topic: + UI
messages: + msg13951
title: Non-friendly error when invalid regex in boring file -> need friendly error when invalid regex in boring file
2012-04-20 19:45:42noreplysetstatus: needs-implementation -> has-patch
messages: + msg15580
2012-04-20 19:46:27noreplysetstatus: has-patch -> resolved
messages: + msg15581
resolvedin: 2.10.0