{"action":"closed","issue":{"url":"https://api.github.com/repos/kbower/tickettest1/issues/1869","repository_url":"https://api.github.com/repos/kbower/tickettest1","labels_url":"https://api.github.com/repos/kbower/tickettest1/issues/1869/labels{/name}","comments_url":"https://api.github.com/repos/kbower/tickettest1/issues/1869/comments","events_url":"https://api.github.com/repos/kbower/tickettest1/issues/1869/events","html_url":"https://github.com/kbower/tickettest1/issues/1869","id":196657065,"number":1869,"title":"NotSupported thrown when getting customer history =","user":{"login":"i-rabot","id":24670438,"avatar_url":"https://avatars.githubusercontent.com/u/24670438?v=3","gravatar_id":"","url":"https://api.github.com/users/i-rabot","html_url":"https://github.com/i-rabot","followers_url":"https://api.github.com/users/i-rabot/followers","following_url":"https://api.github.com/users/i-rabot/following{/other_user}","gists_url":"https://api.github.com/users/i-rabot/gists{/gist_id}","starred_url":"https://api.github.com/users/i-rabot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/i-rabot/subscriptions","organizations_url":"https://api.github.com/users/i-rabot/orgs","repos_url":"https://api.github.com/users/i-rabot/repos","events_url":"https://api.github.com/users/i-rabot/events{/privacy}","received_events_url":"https://api.github.com/users/i-rabot/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-12-20T12:08:35Z","updated_at":"2016-12-20T12:08:37Z","closed_at":"2016-12-20T12:08:37Z","body":"_Imported from trac ticket 1869.\nCreated by **rneville**\nOpened in trac: Aug 14, 2012, 8:58:22 AM\nLast modified in trac: Aug 16, 2012, 3:47:38 PM_\n***\n_by rneville:_\ndef adjusts_sale(self):\n       if self.adjustedorder:\n           if self.adjustedorder.type != Order.SALE:\n               raise NotSupported(\"Adjusting a non Sale is not supported!\")\n           return True\n       else:\n           # \"Normal\" order like Sale or a stand alone adjustment\n           if self.adjustedorderid:\n               raise CorruptData(\"%r references an adjustedorder that doesn't exist: %s\" %\n                   (self, self.adjustedorderid))\n           return False\n\nIt's puking when we have an adjustment against an EEX. Apparently that's a legal thing to do.\n\n----\n\nThe error doesn't say it's corrupt data or not legal, it says \"not supported\".  This is one of the philosophical discussions we had about adjusting an adjustment and we decided we aren't going recursive like that... at least not for now.. it would be a complete nightmare to display in flex for starters.\n\nEven if we eventually can support that, it surely won't be until we understand how it works and support Exchanges, for example.  So for now (and maybe indefinitely), we aren't supporting adjusting an adjustment; call us crazy for trying to keep things simple, and don't accuse us of abandoning the gap girl concept, eh?  There may be tax reasons that we should support it, but even as a workaround, they can use GERS for now (or write a detached adjustment in future Loft).  This is the discussion we had where we decided \"it ain't worth the effort when 99% of the time they won't need this and if they do there is a workaround\".\n\n----\n\nI agree but be aware that when these guys do testing they typically use their local TRAIN version of 'Veronica Smith' that has 9,873 orders with all manner of stupid adjustments and adjustments to adjustments, etc etc. The upshot being that when they go to test, they immediately run into a \"problem\".\n\nThe larger issue with this isn't that they were trying to open an order that had an adjustment against an exchange, it was that one existed in the customer's history such that whenever you tried to take a payment (thus bringing up customer history) or go into the customer edit screen (ditto), you would get this error. I'm not entirely clear why it's hitting this function on a query...my assumption is that it's a eagerload of some time causing the trouble?\n\n----\n\nWell, it isn't a query, those are all really gets, which is loading all this crap.  It's probably hitting it because I kept having to stick these checks in until I got smarter and factored out the lowest place I could put it.\n"}}
{"actor":{"display_login":"i-rabot"}}