[darcs-users] darcs failed: Unapplicable patch!

Jean Jordaan jean at upfrontsystems.co.za
Fri Nov 26 13:30:51 UTC 2004


Looks like it's this patch (which looks totally innocent to me .. )

jean at klippie fabrinox $ darcs annotate -p Comments
[Comments, schema, prices.
jean at upfrontsystems.co.za**20041107140602] {
hunk ./Fabrinox/QuoteItem.py 6
+# Zope
hunk ./Fabrinox/QuoteItem.py 8
+
+# CMF
hunk ./Fabrinox/QuoteItem.py 11
+
+# Archetypes
hunk ./Fabrinox/QuoteItem.py 15
+# Creme
+from Products.Creme.CustomFields import MoneyField
+
hunk ./Fabrinox/QuoteItem.py 19
+    # Parameters defining the job
+    # Other possibilities: Wastage, SetupTime, Machine, CuttingTime
hunk ./Fabrinox/QuoteItem.py 24
-            label_msgid='Pierces',
hunk ./Fabrinox/QuoteItem.py 26
-    StringField('Material',
+    FloatField('CutLength'),
+    StringField('Material', # Implies which thickness
hunk ./Fabrinox/QuoteItem.py 32
-            label_msgid='Material',
hunk ./Fabrinox/QuoteItem.py 33
-        )
+        ),
+    # How many
+    IntegerField('Quantity',
+        widget=IntegerWidget(),
+        ),
+    # Derivative / Summary fields
+    ComputedField('ComputedPrice',
+        widget=ComputedWidget(
+            visible={'edit': 'invisible'})
+        ),
+    MoneyField('FinalPrice',
+        default='getComputedPrice',
+        ),
hunk ./Fabrinox/QuoteItem.py 61
+    def getComputedPrice(self):
+        qt = getToolByName(self, 'quote_tool')
+        return qt.getPrice(self)
+
+    def validate_Quantity(self, new_value):
+        if not new_value > 0:
+            return "Quantity must be positive integer"
+        return None
+
}

How can a dead simple patch like that be unapplicable?

-- 
Jean Jordaan
http://www.upfrontsystems.co.za




More information about the darcs-users mailing list