project
stringlengths 1
98
| commit_sha
stringlengths 40
40
| parent_sha
stringlengths 40
40
| file_path
stringlengths 4
209
| project_url
stringlengths 23
132
| likely_bug
bool 1
class | comodified
bool 1
class | in_function
bool 2
classes | diff
stringlengths 27
9.71k
| before
stringlengths 1
8.91k
| after
stringlengths 1
6k
| sstub_pattern
stringclasses 23
values | edit_script
stringlengths 33
158k
| key
stringlengths 45
154
| commit_message
stringlengths 3
65.5k
⌀ | files
list |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
records | 1217c9eea26ef0cb4a33bbfa4022b60ac721a690 | 617f02c62165e170a798939d1a3e94beaff6384a | tests/test_records.py | https://github.com/fictorial/records | true | false | true | @@ -64,7 +64,7 @@ class TestRecordCollection:
rows = records.RecordCollection(IdRecord(i) for i in range(1))
assert rows.first() == IdRecord(0)
- def test_first_defaults_to_Nfirst(self):
+ def test_first_defaults_to_None(self):
rows = records.RecordCollection(iter([]))
assert rows.first() is None
| def test_first_defaults_to_Nfirst ( self ) : rows = records . RecordCollection ( iter ( [ ] ) ) assert rows . first ( ) is None | def test_first_defaults_to_None ( self ) : rows = records . RecordCollection ( iter ( [ ] ) ) assert rows . first ( ) is None | SINGLE_TOKEN | [["Update", ["identifier:test_first_defaults_to_Nfirst", 3, 9, 3, 38], "test_first_defaults_to_None"]] | fictorial/records@1217c9eea26ef0cb4a33bbfa4022b60ac721a690 | Fix regression in test name :o) | [
{
"sha": "722591fe1606b0386d0e6c2faddac3bcb0410fbf",
"filename": "tests/test_records.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/fictorial/records/blob/1217c9eea26ef0cb4a33bbfa4022b60ac721a690/tests%2Ftest_records.py",
"raw_url": "https://github.com/fictorial/records/raw/1217c9eea26ef0cb4a33bbfa4022b60ac721a690/tests%2Ftest_records.py",
"contents_url": "https://api.github.com/repos/fictorial/records/contents/tests%2Ftest_records.py?ref=1217c9eea26ef0cb4a33bbfa4022b60ac721a690",
"patch": "@@ -64,7 +64,7 @@ def test_first_returns_a_single_record(self):\n rows = records.RecordCollection(IdRecord(i) for i in range(1))\n assert rows.first() == IdRecord(0)\n \n- def test_first_defaults_to_Nfirst(self):\n+ def test_first_defaults_to_None(self):\n rows = records.RecordCollection(iter([]))\n assert rows.first() is None\n "
}
] |
records | 42a7e78dc01f7a5df7829ffc6106dad0efa95775 | 292bd56fa38c625296da5be3d58525935a2486f7 | records.py | https://github.com/fictorial/records | true | false | true | @@ -63,7 +63,7 @@ class Record(object):
raise AttributeError(e)
def __dir__(self):
- standard = super(Record, self).__dir__()
+ standard = dir(super(Record, self))
# Merge standard attrs with generated ones (from column names).
return sorted(standard + [str(k) for k in self.keys()])
| standard = super ( Record , self ) . __dir__ ( ) | standard = dir ( super ( Record , self ) ) | SINGLE_STMT | [["Insert", ["call", 3, 20, 3, 49], ["identifier:dir", "T"], 0], ["Insert", ["call", 3, 20, 3, 49], ["argument_list", "N0"], 1], ["Insert", "N0", ["(:(", "T"], 0], ["Move", "N0", ["call", 3, 20, 3, 39], 1], ["Insert", "N0", ["):)", "T"], 2], ["Delete", [".:.", 3, 39, 3, 40]], ["Delete", ["identifier:__dir__", 3, 40, 3, 47]], ["Delete", ["attribute", 3, 20, 3, 47]], ["Delete", ["(:(", 3, 47, 3, 48]], ["Delete", ["):)", 3, 48, 3, 49]], ["Delete", ["argument_list", 3, 47, 3, 49]]] | fictorial/records@42a7e78dc01f7a5df7829ffc6106dad0efa95775 | fix dir for super | [
{
"sha": "b0e0c705acfab14ae1f7eb4f6b0b72e53576c9dc",
"filename": "records.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/fictorial/records/blob/42a7e78dc01f7a5df7829ffc6106dad0efa95775/records.py",
"raw_url": "https://github.com/fictorial/records/raw/42a7e78dc01f7a5df7829ffc6106dad0efa95775/records.py",
"contents_url": "https://api.github.com/repos/fictorial/records/contents/records.py?ref=42a7e78dc01f7a5df7829ffc6106dad0efa95775",
"patch": "@@ -63,7 +63,7 @@ def __getattr__(self, key):\n raise AttributeError(e)\n \n def __dir__(self):\n- standard = super(Record, self).__dir__()\n+ standard = dir(super(Record, self))\n # Merge standard attrs with generated ones (from column names).\n return sorted(standard + [str(k) for k in self.keys()])\n "
}
] |
flask-admin | ee9305db24acba54512f5284229482c14b30c6f2 | 54d7dda71241d2cdf243232c4b3ee3c289a25fff | flask_admin/contrib/sqla/view.py | https://github.com/zhijuebin/flask-admin | true | false | true | @@ -648,7 +648,7 @@ class ModelView(BaseModelView):
# must be named with relation name (to prevent following same
# target column to replace previous)
if joined_column_name:
- key_name = "{}.{}".format(joined_column_name, column)
+ key_name = "{0}.{1}".format(joined_column_name, column)
for f in flt:
f.key_name = key_name
| key_name = "{}.{}" . format ( joined_column_name , column ) | key_name = "{0}.{1}" . format ( joined_column_name , column ) | CHANGE_STRING_LITERAL | [["Update", ["string:\"{}.{}\"", 3, 28, 3, 35], "\"{0}.{1}\""]] | zhijuebin/flask-admin@ee9305db24acba54512f5284229482c14b30c6f2 | Fix tests according to f214557 | [
{
"sha": "7ae0866e46e55d294e51fb0d20261fd004614cbd",
"filename": "flask_admin/contrib/sqla/view.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/zhijuebin/flask-admin/blob/ee9305db24acba54512f5284229482c14b30c6f2/flask_admin%2Fcontrib%2Fsqla%2Fview.py",
"raw_url": "https://github.com/zhijuebin/flask-admin/raw/ee9305db24acba54512f5284229482c14b30c6f2/flask_admin%2Fcontrib%2Fsqla%2Fview.py",
"contents_url": "https://api.github.com/repos/zhijuebin/flask-admin/contents/flask_admin%2Fcontrib%2Fsqla%2Fview.py?ref=ee9305db24acba54512f5284229482c14b30c6f2",
"patch": "@@ -648,7 +648,7 @@ def scaffold_filters(self, name):\n # must be named with relation name (to prevent following same\n # target column to replace previous)\n if joined_column_name:\n- key_name = \"{}.{}\".format(joined_column_name, column)\n+ key_name = \"{0}.{1}\".format(joined_column_name, column)\n for f in flt:\n f.key_name = key_name\n "
}
] |
flask-admin | 56f33444a7d8425ea6cd756fd292a7d50c3eccb9 | edb542e9cef11d5d2c0e7ac5f0c3ea7f226c7778 | flask_admin/contrib/fileadmin/__init__.py | https://github.com/zhijuebin/flask-admin | true | false | false | @@ -263,7 +263,7 @@ class BaseFileAdmin(BaseView, ActionsMixin):
default_desc = 0
"""The default desc value."""
- column_labels = {column: column.capitalize() for column in column_list}
+ column_labels = dict((column, column.capitalize()) for column in column_list)
"""A dict from column names to their labels."""
date_format = '%Y-%m-%d %H:%M:%S'
| column_labels = { column : column . capitalize ( ) for column in column_list } | column_labels = dict ( ( column , column . capitalize ( ) ) for column in column_list ) | SINGLE_STMT | [["Insert", ["assignment", 3, 5, 3, 76], ["call", "N0"], 2], ["Insert", "N0", ["identifier:dict", "T"], 0], ["Insert", "N0", ["generator_expression", "N1"], 1], ["Insert", "N1", ["(:(", "T"], 0], ["Insert", "N1", ["tuple", "N2"], 1], ["Move", "N1", ["for_in_clause", 3, 50, 3, 75], 2], ["Insert", "N1", ["):)", "T"], 3], ["Insert", "N2", ["(:(", "T"], 0], ["Move", "N2", ["identifier:column", 3, 22, 3, 28], 1], ["Insert", "N2", [",:,", "T"], 2], ["Move", "N2", ["call", 3, 30, 3, 49], 3], ["Insert", "N2", ["):)", "T"], 4], ["Delete", ["{:{", 3, 21, 3, 22]], ["Delete", [":::", 3, 28, 3, 29]], ["Delete", ["pair", 3, 22, 3, 49]], ["Delete", ["}:}", 3, 75, 3, 76]], ["Delete", ["dictionary_comprehension", 3, 21, 3, 76]]] | zhijuebin/flask-admin@56f33444a7d8425ea6cd756fd292a7d50c3eccb9 | fixed python 2.6 compatibility. | [
{
"sha": "17387f6d822ff12022402b9057b76f11c74b372a",
"filename": "flask_admin/contrib/fileadmin/__init__.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/zhijuebin/flask-admin/blob/56f33444a7d8425ea6cd756fd292a7d50c3eccb9/flask_admin%2Fcontrib%2Ffileadmin%2F__init__.py",
"raw_url": "https://github.com/zhijuebin/flask-admin/raw/56f33444a7d8425ea6cd756fd292a7d50c3eccb9/flask_admin%2Fcontrib%2Ffileadmin%2F__init__.py",
"contents_url": "https://api.github.com/repos/zhijuebin/flask-admin/contents/flask_admin%2Fcontrib%2Ffileadmin%2F__init__.py?ref=56f33444a7d8425ea6cd756fd292a7d50c3eccb9",
"patch": "@@ -263,7 +263,7 @@ class MyAdmin(FileAdmin):\n default_desc = 0\n \"\"\"The default desc value.\"\"\"\n \n- column_labels = {column: column.capitalize() for column in column_list}\n+ column_labels = dict((column, column.capitalize()) for column in column_list)\n \"\"\"A dict from column names to their labels.\"\"\"\n \n date_format = '%Y-%m-%d %H:%M:%S'"
}
] |
flask-admin | 68469536173cda8f5692be52a8e9f15339d7b19c | 2f14840c6b44543f12ef35d01c8e0e4df3cef3ff | flask_admin/contrib/sqla/filters.py | https://github.com/zhijuebin/flask-admin | true | false | true | @@ -29,7 +29,7 @@ class BaseSQLAFilter(filters.BaseFilter):
return self.column if alias is None else getattr(alias, self.column.key)
def apply(self, query, value, alias=None):
- return super(self, BaseSQLAFilter).apply(query, value)
+ return super(BaseSQLAFilter, self).apply(query, value)
# Common filters
| return super ( self , BaseSQLAFilter ) . apply ( query , value ) | return super ( BaseSQLAFilter , self ) . apply ( query , value ) | SAME_FUNCTION_SWAP_ARGS | [["Move", ["identifier:self", 3, 22, 3, 26], ["argument_list", 3, 21, 3, 43], 3], ["Move", [",:,", 3, 26, 3, 27], ["argument_list", 3, 21, 3, 43], 4]] | zhijuebin/flask-admin@68469536173cda8f5692be52a8e9f15339d7b19c | fix: bad call `super` in BaseSQLAFilter | [
{
"sha": "4f9cd9ff101c3e5d327e05ae5d31db98ab4f895a",
"filename": "flask_admin/contrib/sqla/filters.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/zhijuebin/flask-admin/blob/68469536173cda8f5692be52a8e9f15339d7b19c/flask_admin%2Fcontrib%2Fsqla%2Ffilters.py",
"raw_url": "https://github.com/zhijuebin/flask-admin/raw/68469536173cda8f5692be52a8e9f15339d7b19c/flask_admin%2Fcontrib%2Fsqla%2Ffilters.py",
"contents_url": "https://api.github.com/repos/zhijuebin/flask-admin/contents/flask_admin%2Fcontrib%2Fsqla%2Ffilters.py?ref=68469536173cda8f5692be52a8e9f15339d7b19c",
"patch": "@@ -29,7 +29,7 @@ def get_column(self, alias):\n return self.column if alias is None else getattr(alias, self.column.key)\n \n def apply(self, query, value, alias=None):\n- return super(self, BaseSQLAFilter).apply(query, value)\n+ return super(BaseSQLAFilter, self).apply(query, value)\n \n \n # Common filters"
}
] |
flask-admin | 8e6daeb6a425f0ef976b352c3376f87bbdbd443e | 2313bb05a6a242dc0efe4c9bef96d0487b890875 | flask_admin/model/widgets.py | https://github.com/zhijuebin/flask-admin | true | false | true | @@ -58,7 +58,7 @@ class AjaxSelect2Widget(object):
kwargs['value'] = data[0]
kwargs['data-json'] = json.dumps(data)
- placeholder = gettext(field.loader.options.get('placeholder', 'Please select model'))
+ placeholder = field.loader.options.get('placeholder', gettext('Please select model'))
kwargs.setdefault('data-placeholder', placeholder)
return HTMLString('<input %s>' % html_params(name=field.name, **kwargs))
| placeholder = gettext ( field . loader . options . get ( 'placeholder' , 'Please select model' ) ) | placeholder = field . loader . options . get ( 'placeholder' , gettext ( 'Please select model' ) ) | SINGLE_STMT | [["Insert", ["argument_list", 3, 55, 3, 93], ["call", "N0"], 3], ["Insert", ["argument_list", 3, 55, 3, 93], ["):)", "T"], 4], ["Insert", "N0", ["identifier:gettext", "T"], 0], ["Insert", "N0", ["argument_list", "N1"], 1], ["Insert", "N1", ["(:(", "T"], 0], ["Move", "N1", ["string:'Please select model'", 3, 71, 3, 92], 1], ["Move", "N1", ["):)", 3, 92, 3, 93], 2], ["Delete", ["identifier:gettext", 3, 23, 3, 30]], ["Delete", ["(:(", 3, 30, 3, 31]], ["Delete", ["):)", 3, 93, 3, 94]], ["Delete", ["argument_list", 3, 30, 3, 94]]] | zhijuebin/flask-admin@8e6daeb6a425f0ef976b352c3376f87bbdbd443e | fix gettext for 'Please select model' | [
{
"sha": "1ccb858bbba01b0930346d6b9a488ca922e59f17",
"filename": "flask_admin/model/widgets.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/zhijuebin/flask-admin/blob/8e6daeb6a425f0ef976b352c3376f87bbdbd443e/flask_admin%2Fmodel%2Fwidgets.py",
"raw_url": "https://github.com/zhijuebin/flask-admin/raw/8e6daeb6a425f0ef976b352c3376f87bbdbd443e/flask_admin%2Fmodel%2Fwidgets.py",
"contents_url": "https://api.github.com/repos/zhijuebin/flask-admin/contents/flask_admin%2Fmodel%2Fwidgets.py?ref=8e6daeb6a425f0ef976b352c3376f87bbdbd443e",
"patch": "@@ -58,7 +58,7 @@ def __call__(self, field, **kwargs):\n kwargs['value'] = data[0]\n kwargs['data-json'] = json.dumps(data)\n \n- placeholder = gettext(field.loader.options.get('placeholder', 'Please select model'))\n+ placeholder = field.loader.options.get('placeholder', gettext('Please select model'))\n kwargs.setdefault('data-placeholder', placeholder)\n \n return HTMLString('<input %s>' % html_params(name=field.name, **kwargs))"
}
] |
flask-admin | 35c5179b4a94feb0bd24be54e60e1104daf1ac5e | 65a2d5bc658b9a0a592c8cb50542e92740e7a4b2 | flask_admin/contrib/sqla/view.py | https://github.com/zhijuebin/flask-admin | true | false | true | @@ -630,7 +630,7 @@ class ModelView(BaseModelView):
# If filter related to relation column (represented by
# relation_name.target_column) we collect here relation name
joined_column_name = None
- if '.' in name:
+ if isinstance(name, string_types) and '.' in name:
joined_column_name = name.split('.')[0]
# Join not needed for hybrid properties
| if '.' in name : joined_column_name = name . split ( '.' ) [ 0 ] | if isinstance ( name , string_types ) and '.' in name : joined_column_name = name . split ( '.' ) [ 0 ] | MORE_SPECIFIC_IF | [["Insert", ["if_statement", 3, 13, 4, 56], ["boolean_operator", "N0"], 1], ["Insert", "N0", ["call", "N1"], 0], ["Insert", "N0", ["and:and", "T"], 1], ["Move", "N0", ["comparison_operator", 3, 16, 3, 27], 2], ["Insert", "N1", ["identifier:isinstance", "T"], 0], ["Insert", "N1", ["argument_list", "N2"], 1], ["Insert", "N2", ["(:(", "T"], 0], ["Insert", "N2", ["identifier:name", "T"], 1], ["Insert", "N2", [",:,", "T"], 2], ["Insert", "N2", ["identifier:string_types", "T"], 3], ["Insert", "N2", ["):)", "T"], 4]] | zhijuebin/flask-admin@35c5179b4a94feb0bd24be54e60e1104daf1ac5e | fixes a crash when specifying column filters using the field's instance rather than its name. | [
{
"sha": "0e200eb09e834fc15e1a29f95c86ea451ef0d419",
"filename": "flask_admin/contrib/sqla/view.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/zhijuebin/flask-admin/blob/35c5179b4a94feb0bd24be54e60e1104daf1ac5e/flask_admin%2Fcontrib%2Fsqla%2Fview.py",
"raw_url": "https://github.com/zhijuebin/flask-admin/raw/35c5179b4a94feb0bd24be54e60e1104daf1ac5e/flask_admin%2Fcontrib%2Fsqla%2Fview.py",
"contents_url": "https://api.github.com/repos/zhijuebin/flask-admin/contents/flask_admin%2Fcontrib%2Fsqla%2Fview.py?ref=35c5179b4a94feb0bd24be54e60e1104daf1ac5e",
"patch": "@@ -630,7 +630,7 @@ def scaffold_filters(self, name):\n # If filter related to relation column (represented by\n # relation_name.target_column) we collect here relation name\n joined_column_name = None\n- if '.' in name:\n+ if isinstance(name, string_types) and '.' in name:\n joined_column_name = name.split('.')[0]\n \n # Join not needed for hybrid properties"
}
] |
flask-admin | 4998ad8a4eadd064a81a0235e473b71c14dc8677 | 1fa4ba80052910fed4f80bc339b0f04955233ed4 | flask_admin/contrib/sqla/view.py | https://github.com/zhijuebin/flask-admin | true | false | true | @@ -594,7 +594,7 @@ class ModelView(BaseModelView):
if column.foreign_keys or column.primary_key:
continue
- visible_name = '%s / %s' % (self.get_column_name(attr.prop.table.name),
+ visible_name = '%s / %s' % (self.get_column_name(attr.prop.target.name),
self.get_column_name(p.key))
type_name = type(column.type).__name__
| visible_name = '%s / %s' % ( self . get_column_name ( attr . prop . table . name ) , self . get_column_name ( p . key ) ) | visible_name = '%s / %s' % ( self . get_column_name ( attr . prop . target . name ) , self . get_column_name ( p . key ) ) | CHANGE_ATTRIBUTE_USED | [["Update", ["identifier:table", 3, 80, 3, 85], "target"]] | zhijuebin/flask-admin@4998ad8a4eadd064a81a0235e473b71c14dc8677 | Fix DeprecationWarning raised by SQLAlchemy | [
{
"sha": "68c5edfe68a1dd49586732b7b53001633e229bad",
"filename": "flask_admin/contrib/sqla/view.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/zhijuebin/flask-admin/blob/4998ad8a4eadd064a81a0235e473b71c14dc8677/flask_admin%2Fcontrib%2Fsqla%2Fview.py",
"raw_url": "https://github.com/zhijuebin/flask-admin/raw/4998ad8a4eadd064a81a0235e473b71c14dc8677/flask_admin%2Fcontrib%2Fsqla%2Fview.py",
"contents_url": "https://api.github.com/repos/zhijuebin/flask-admin/contents/flask_admin%2Fcontrib%2Fsqla%2Fview.py?ref=4998ad8a4eadd064a81a0235e473b71c14dc8677",
"patch": "@@ -594,7 +594,7 @@ def scaffold_filters(self, name):\n if column.foreign_keys or column.primary_key:\n continue\n \n- visible_name = '%s / %s' % (self.get_column_name(attr.prop.table.name),\n+ visible_name = '%s / %s' % (self.get_column_name(attr.prop.target.name),\n self.get_column_name(p.key))\n \n type_name = type(column.type).__name__"
}
] |
flask-admin | 99a64951b84be7be785b573ae7d1de9bb93d9433 | 38e5b8057cb1acce805b6f6bfa923897371588cc | flask_admin/contrib/sqla/ajax.py | https://github.com/zhijuebin/flask-admin | true | false | true | @@ -69,7 +69,7 @@ class QueryAjaxModelLoader(AjaxModelLoader):
query = query.filter(or_(*filters))
if self.filters:
- filters = ["%s.%s" % (self.model.__name__.lower(), value) for value in self.filters]
+ filters = ["%s.%s" % (self.model.__table__.name.lower(), value) for value in self.filters]
query = query.filter(and_(*filters))
if self.order_by:
| filters = [ "%s.%s" % ( self . model . __name__ . lower ( ) , value ) for value in self . filters ] | filters = [ "%s.%s" % ( self . model . __table__ . name . lower ( ) , value ) for value in self . filters ] | SINGLE_STMT | [["Insert", ["attribute", 3, 35, 3, 54], ["attribute", "N0"], 0], ["Insert", ["attribute", 3, 35, 3, 54], [".:.", "T"], 1], ["Insert", ["attribute", 3, 35, 3, 54], ["identifier:name", "T"], 2], ["Move", "N0", ["attribute", 3, 35, 3, 45], 0], ["Move", "N0", [".:.", 3, 45, 3, 46], 1], ["Update", ["identifier:__name__", 3, 46, 3, 54], "__table__"], ["Move", "N0", ["identifier:__name__", 3, 46, 3, 54], 2]] | zhijuebin/flask-admin@99a64951b84be7be785b573ae7d1de9bb93d9433 | Use table name rather than model name construct filter query in QueryAjaxModelLoader
* https://github.com/flask-admin/flask-admin/issues/1484 | [
{
"sha": "c12f3528c5a4fb66bd386d8cf77c9e209da55e72",
"filename": "flask_admin/contrib/sqla/ajax.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/zhijuebin/flask-admin/blob/99a64951b84be7be785b573ae7d1de9bb93d9433/flask_admin%2Fcontrib%2Fsqla%2Fajax.py",
"raw_url": "https://github.com/zhijuebin/flask-admin/raw/99a64951b84be7be785b573ae7d1de9bb93d9433/flask_admin%2Fcontrib%2Fsqla%2Fajax.py",
"contents_url": "https://api.github.com/repos/zhijuebin/flask-admin/contents/flask_admin%2Fcontrib%2Fsqla%2Fajax.py?ref=99a64951b84be7be785b573ae7d1de9bb93d9433",
"patch": "@@ -69,7 +69,7 @@ def get_list(self, term, offset=0, limit=DEFAULT_PAGE_SIZE):\n query = query.filter(or_(*filters))\n \n if self.filters:\n- filters = [\"%s.%s\" % (self.model.__name__.lower(), value) for value in self.filters]\n+ filters = [\"%s.%s\" % (self.model.__table__.name.lower(), value) for value in self.filters]\n query = query.filter(and_(*filters))\n \n if self.order_by:"
}
] |
flask-admin | 7777e56e7f644a91bc61b5a692a0c1102169464b | 58e9ea7af5b90c81718e4ce5694372cd9becafa6 | flask_admin/contrib/sqla/fields.py | https://github.com/zhijuebin/flask-admin | true | false | true | @@ -276,7 +276,7 @@ class InlineModelFormList(InlineFieldList):
# Handle request data
for field in self.entries:
- field_id = field.get_pk()
+ field_id = str(field.get_pk())
is_created = field_id not in pk_map
if not is_created:
| field_id = field . get_pk ( ) | field_id = str ( field . get_pk ( ) ) | ADD_FUNCTION_AROUND_EXPRESSION | [["Insert", ["call", 3, 24, 3, 38], ["identifier:str", "T"], 0], ["Insert", ["call", 3, 24, 3, 38], ["argument_list", "N0"], 1], ["Insert", "N0", ["(:(", "T"], 0], ["Move", "N0", ["call", 3, 24, 3, 38], 1], ["Insert", "N0", ["):)", "T"], 2]] | zhijuebin/flask-admin@7777e56e7f644a91bc61b5a692a0c1102169464b | refs #39 fixed pk validate in InlineModelFormList | [
{
"sha": "88141e0ca5006d5f8b68febee73f054633fd15a2",
"filename": "flask_admin/contrib/sqla/fields.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/zhijuebin/flask-admin/blob/7777e56e7f644a91bc61b5a692a0c1102169464b/flask_admin%2Fcontrib%2Fsqla%2Ffields.py",
"raw_url": "https://github.com/zhijuebin/flask-admin/raw/7777e56e7f644a91bc61b5a692a0c1102169464b/flask_admin%2Fcontrib%2Fsqla%2Ffields.py",
"contents_url": "https://api.github.com/repos/zhijuebin/flask-admin/contents/flask_admin%2Fcontrib%2Fsqla%2Ffields.py?ref=7777e56e7f644a91bc61b5a692a0c1102169464b",
"patch": "@@ -276,7 +276,7 @@ def populate_obj(self, obj, name):\n \n # Handle request data\n for field in self.entries:\n- field_id = field.get_pk()\n+ field_id = str(field.get_pk())\n \n is_created = field_id not in pk_map\n if not is_created:"
}
] |
flask-admin | 197896a178ca4c569cfd499ab23248730955eddc | bed566553701c2d5a7ebb3c5457c4911f9895f77 | flask_admin/contrib/sqla/fields.py | https://github.com/zhijuebin/flask-admin | true | false | true | @@ -296,5 +296,5 @@ class InlineModelFormList(InlineFieldList):
def get_pk_from_identity(obj):
# TODO: Remove me
- cls, key, *token = identity_key(instance=obj)
+ key = identity_key(instance=obj)[1]
return u':'.join(text_type(x) for x in key)
| cls , key , * token = identity_key ( instance = obj ) | key = identity_key ( instance = obj ) [ 1 ] | SINGLE_STMT | [["Move", ["assignment", 3, 5, 3, 50], ["identifier:key", 3, 10, 3, 13], 0], ["Insert", ["assignment", 3, 5, 3, 50], ["subscript", "N0"], 3], ["Move", "N0", ["call", 3, 24, 3, 50], 0], ["Insert", "N0", ["[:[", "T"], 1], ["Insert", "N0", ["integer:1", "T"], 2], ["Insert", "N0", ["]:]", "T"], 3], ["Delete", ["identifier:cls", 3, 5, 3, 8]], ["Delete", [",:,", 3, 8, 3, 9]], ["Delete", [",:,", 3, 13, 3, 14]], ["Delete", ["*:*", 3, 15, 3, 16]], ["Delete", ["identifier:token", 3, 16, 3, 21]], ["Delete", ["list_splat_pattern", 3, 15, 3, 21]], ["Delete", ["pattern_list", 3, 5, 3, 21]]] | zhijuebin/flask-admin@197896a178ca4c569cfd499ab23248730955eddc | Fixed for Python2 compatibility | [
{
"sha": "e6f5eb8365e9334ff1d9ba20c4c487fec602b000",
"filename": "flask_admin/contrib/sqla/fields.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/zhijuebin/flask-admin/blob/197896a178ca4c569cfd499ab23248730955eddc/flask_admin%2Fcontrib%2Fsqla%2Ffields.py",
"raw_url": "https://github.com/zhijuebin/flask-admin/raw/197896a178ca4c569cfd499ab23248730955eddc/flask_admin%2Fcontrib%2Fsqla%2Ffields.py",
"contents_url": "https://api.github.com/repos/zhijuebin/flask-admin/contents/flask_admin%2Fcontrib%2Fsqla%2Ffields.py?ref=197896a178ca4c569cfd499ab23248730955eddc",
"patch": "@@ -296,5 +296,5 @@ def populate_obj(self, obj, name):\n \n def get_pk_from_identity(obj):\n # TODO: Remove me\n- cls, key, *token = identity_key(instance=obj)\n+ key = identity_key(instance=obj)[1]\n return u':'.join(text_type(x) for x in key)"
}
] |
radioxenon_ml | 54b91252c5b94d52c165d982ab3e98bb2284593d | c0ae516b7f7919c099943a116235ec64d4548e65 | radioxenon_ml/test_files/test_functions.py | https://github.com/SoftwareDevEngResearch/radioxenon_ml | true | false | true | @@ -103,7 +103,7 @@ def test_variance():
S = np.array([1,2,3,4,5,6,7,8,9,10,11,12])
- A = np.array([1,2,3,4])
+ A = np.array([1,2,3,4,5])
f = np.array([[0,0,0,0,0,0,1,1,1,1,1,1],[1,1,1,1,1,1,2,2,2,2,2,2],[2,2,2,2,2,2,3,3,3,3,3,3],[3,3,3,3,3,3,4,4,4,4,4,4],[0,1,0,0,1,0,2,3,1,0,0,0]])
D=np.array([])
for q in range(0,3):
| A = np . array ( [ 1 , 2 , 3 , 4 ] ) | A = np . array ( [ 1 , 2 , 3 , 4 , 5 ] ) | ADD_ELEMENTS_TO_ITERABLE | [["Insert", ["list", 1, 18, 1, 27], [",:,", "T"], 8], ["Insert", ["list", 1, 18, 1, 27], ["integer:5", "T"], 9]] | SoftwareDevEngResearch/radioxenon_ml@54b91252c5b94d52c165d982ab3e98bb2284593d | Fixed size of A vector in test_variance in compliance with size of f matrix | [
{
"sha": "9268c8a811681cff1dfff843040f65bb210b5f2a",
"filename": "radioxenon_ml/test_files/test_functions.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/SoftwareDevEngResearch/radioxenon_ml/blob/54b91252c5b94d52c165d982ab3e98bb2284593d/radioxenon_ml%2Ftest_files%2Ftest_functions.py",
"raw_url": "https://github.com/SoftwareDevEngResearch/radioxenon_ml/raw/54b91252c5b94d52c165d982ab3e98bb2284593d/radioxenon_ml%2Ftest_files%2Ftest_functions.py",
"contents_url": "https://api.github.com/repos/SoftwareDevEngResearch/radioxenon_ml/contents/radioxenon_ml%2Ftest_files%2Ftest_functions.py?ref=54b91252c5b94d52c165d982ab3e98bb2284593d",
"patch": "@@ -103,7 +103,7 @@ def test_variance():\n test the variance function using two known vectors\n \"\"\"\n S = np.array([1,2,3,4,5,6,7,8,9,10,11,12])\n- A = np.array([1,2,3,4])\n+ A = np.array([1,2,3,4,5])\n f = np.array([[0,0,0,0,0,0,1,1,1,1,1,1],[1,1,1,1,1,1,2,2,2,2,2,2],[2,2,2,2,2,2,3,3,3,3,3,3],[3,3,3,3,3,3,4,4,4,4,4,4],[0,1,0,0,1,0,2,3,1,0,0,0]])\n D=np.array([]) \n for q in range(0,3):"
}
] |
dos-azul-lambda | 69ef2b7acb2d288482195746fe3731e593f98645 | cde177e8c26ba4499270cd491abba6a450c9784f | app.py | https://github.com/DataBiosphere/dos-azul-lambda | true | false | true | @@ -21,7 +21,7 @@ def azul_to_dos(azul):
data_object = {}
data_object['id'] = azul['file_id']
- data_object['urls'] = [{'url': url for url in azul['urls']}]
+ data_object['urls'] = [{'url': url} for url in azul['urls']]
data_object['version'] = azul['file_version']
data_object['size'] = str(azul.get('fileSize', ""))
data_object['checksums'] = [
| data_object [ 'urls' ] = [ { 'url' : url for url in azul [ 'urls' ] } ] | data_object [ 'urls' ] = [ { 'url' : url } for url in azul [ 'urls' ] ] | SINGLE_STMT | [["Insert", ["assignment", 2, 5, 2, 65], ["list_comprehension", "N0"], 2], ["Move", "N0", ["[:[", 2, 27, 2, 28], 0], ["Insert", "N0", ["dictionary", "N1"], 1], ["Move", "N0", ["for_in_clause", 2, 40, 2, 63], 2], ["Move", "N0", ["]:]", 2, 64, 2, 65], 3], ["Move", "N1", ["{:{", 2, 28, 2, 29], 0], ["Move", "N1", ["pair", 2, 29, 2, 39], 1], ["Insert", "N1", ["}:}", "T"], 2], ["Delete", ["}:}", 2, 63, 2, 64]], ["Delete", ["dictionary_comprehension", 2, 28, 2, 64]], ["Delete", ["list", 2, 27, 2, 65]]] | DataBiosphere/dos-azul-lambda@69ef2b7acb2d288482195746fe3731e593f98645 | Fix url list close #55 (#56) | [
{
"sha": "0c3b4bc38b9106c5ce82d062e1db5ab6cc5a086a",
"filename": "app.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/DataBiosphere/dos-azul-lambda/blob/69ef2b7acb2d288482195746fe3731e593f98645/app.py",
"raw_url": "https://github.com/DataBiosphere/dos-azul-lambda/raw/69ef2b7acb2d288482195746fe3731e593f98645/app.py",
"contents_url": "https://api.github.com/repos/DataBiosphere/dos-azul-lambda/contents/app.py?ref=69ef2b7acb2d288482195746fe3731e593f98645",
"patch": "@@ -21,7 +21,7 @@ def azul_to_dos(azul):\n \"\"\"\n data_object = {}\n data_object['id'] = azul['file_id']\n- data_object['urls'] = [{'url': url for url in azul['urls']}]\n+ data_object['urls'] = [{'url': url} for url in azul['urls']]\n data_object['version'] = azul['file_version']\n data_object['size'] = str(azul.get('fileSize', \"\"))\n data_object['checksums'] = ["
}
] |
dos-azul-lambda | 8473122e3658ac7237cf43ba5083228b523ca3d9 | 4bcf8bf128a18a6af9821dfb240091fee1efe474 | app.py | https://github.com/DataBiosphere/dos-azul-lambda | true | false | true | @@ -358,7 +358,7 @@ def swagger():
# FIXME replace with one hosted here
- req = requests.get("https://ga4gh.github.io/data-object-service-schemas/swagger/data_object_service.swagger.yaml") # NOQA
+ req = requests.get("https://raw.githubusercontent.com/ga4gh/data-object-service-schemas/master/openapi/data_object_service.swagger.yaml") # NOQA
swagger_dict = yaml.load(req.content)
swagger_dict['basePath'] = '/api/ga4gh/dos/v1'
| req = requests . get ( "https://ga4gh.github.io/data-object-service-schemas/swagger/data_object_service.swagger.yaml" ) | req = requests . get ( "https://raw.githubusercontent.com/ga4gh/data-object-service-schemas/master/openapi/data_object_service.swagger.yaml" ) | CHANGE_STRING_LITERAL | [["Update", ["string:\"https://ga4gh.github.io/data-object-service-schemas/swagger/data_object_service.swagger.yaml\"", 1, 24, 1, 118], "\"https://raw.githubusercontent.com/ga4gh/data-object-service-schemas/master/openapi/data_object_service.swagger.yaml\""]] | DataBiosphere/dos-azul-lambda@8473122e3658ac7237cf43ba5083228b523ca3d9 | Fix link to swagger.json | [
{
"sha": "b1f7c3174cbea545bd940dc4728de0f6d9249b02",
"filename": "app.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/DataBiosphere/dos-azul-lambda/blob/8473122e3658ac7237cf43ba5083228b523ca3d9/app.py",
"raw_url": "https://github.com/DataBiosphere/dos-azul-lambda/raw/8473122e3658ac7237cf43ba5083228b523ca3d9/app.py",
"contents_url": "https://api.github.com/repos/DataBiosphere/dos-azul-lambda/contents/app.py?ref=8473122e3658ac7237cf43ba5083228b523ca3d9",
"patch": "@@ -358,7 +358,7 @@ def swagger():\n :return:\n \"\"\"\n # FIXME replace with one hosted here\n- req = requests.get(\"https://ga4gh.github.io/data-object-service-schemas/swagger/data_object_service.swagger.yaml\") # NOQA\n+ req = requests.get(\"https://raw.githubusercontent.com/ga4gh/data-object-service-schemas/master/openapi/data_object_service.swagger.yaml\") # NOQA\n swagger_dict = yaml.load(req.content)\n \n swagger_dict['basePath'] = '/api/ga4gh/dos/v1'"
}
] |
dos-azul-lambda | 71326bb287e2410320bda38146cb9ba41d7e00e0 | 36a47e64da6f0926500d39f63b33073fdba90b6a | app.py | https://github.com/DataBiosphere/dos-azul-lambda | true | false | false | @@ -177,7 +177,7 @@ es = elasticsearch.Elasticsearch(
connection_class=elasticsearch.RequestsHttpConnection
)
app = Chalice(app_name='dos-azul-lambda')
-app.debug = os.environ.get('DEBUG', False) == 'True'
+app.debug = os.environ.get('DEBUG', 'True') == 'True'
base_path = '/ga4gh/dos/v1'
| app . debug = os . environ . get ( 'DEBUG' , False ) == 'True' | app . debug = os . environ . get ( 'DEBUG' , 'True' ) == 'True' | SINGLE_TOKEN | [["Insert", ["argument_list", 3, 27, 3, 43], ["string:'True'", "T"], 3], ["Delete", ["false:False", 3, 37, 3, 42]]] | DataBiosphere/dos-azul-lambda@71326bb287e2410320bda38146cb9ba41d7e00e0 | Change default debug state to true (closes #90) (#120) | [
{
"sha": "f4a219a434f79d9c0165197e3e5b598c05dd265e",
"filename": "app.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/DataBiosphere/dos-azul-lambda/blob/71326bb287e2410320bda38146cb9ba41d7e00e0/app.py",
"raw_url": "https://github.com/DataBiosphere/dos-azul-lambda/raw/71326bb287e2410320bda38146cb9ba41d7e00e0/app.py",
"contents_url": "https://api.github.com/repos/DataBiosphere/dos-azul-lambda/contents/app.py?ref=71326bb287e2410320bda38146cb9ba41d7e00e0",
"patch": "@@ -177,7 +177,7 @@ def check_auth():\n connection_class=elasticsearch.RequestsHttpConnection\n )\n app = Chalice(app_name='dos-azul-lambda')\n-app.debug = os.environ.get('DEBUG', False) == 'True'\n+app.debug = os.environ.get('DEBUG', 'True') == 'True'\n \n base_path = '/ga4gh/dos/v1'\n "
}
] |
assign3 | 6237c22fca73a89008648b2e1bd8d74c95c2d3b9 | e108ffcbc4d1563cab3b1b6ef08b5f046c954af1 | HtmlForm.py | https://github.com/CS5331-G2/assign3 | true | false | true | @@ -14,7 +14,7 @@ class HtmlForm(HtmlElement):
form = parser.find("form")
if form is not None:
self.url = url
- self.action = form['action'] if 'action' in form.attrs.keys() else "/"
+ self.action = form['action'] if 'action' in form.attrs.keys() else ""
self.method = form['method'] if 'method' in form.attrs.keys() else "GET"
self.method = self.method.upper()
self.inputs = []
| self . action = form [ 'action' ] if 'action' in form . attrs . keys ( ) else "/" | self . action = form [ 'action' ] if 'action' in form . attrs . keys ( ) else "" | CHANGE_STRING_LITERAL | [["Update", ["string:\"/\"", 3, 71, 3, 74], "\"\""]] | CS5331-G2/assign3@6237c22fca73a89008648b2e1bd8d74c95c2d3b9 | Fixed erroneous default value for form action | [
{
"sha": "697b4eb3ba3d204cd5ea3cdc4b79c94c5e5815e4",
"filename": "HtmlForm.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/CS5331-G2/assign3/blob/6237c22fca73a89008648b2e1bd8d74c95c2d3b9/HtmlForm.py",
"raw_url": "https://github.com/CS5331-G2/assign3/raw/6237c22fca73a89008648b2e1bd8d74c95c2d3b9/HtmlForm.py",
"contents_url": "https://api.github.com/repos/CS5331-G2/assign3/contents/HtmlForm.py?ref=6237c22fca73a89008648b2e1bd8d74c95c2d3b9",
"patch": "@@ -14,7 +14,7 @@ def __init__(self, url, htmlForm):\n \t\tform = parser.find(\"form\")\n \t\tif form is not None:\n \t\t\tself.url = url\n-\t\t\tself.action = form['action'] if 'action' in form.attrs.keys() else \"/\"\n+\t\t\tself.action = form['action'] if 'action' in form.attrs.keys() else \"\"\n \t\t\tself.method = form['method'] if 'method' in form.attrs.keys() else \"GET\"\n \t\t\tself.method = self.method.upper()\n \t\t\tself.inputs = []"
}
] |
assign3 | 8d6138537984a210319c76dcd5d10ffae59eddf2 | d38ea4d05d188aab813bbfd7c1fd17283a7f20a2 | Endpoint.py | https://github.com/CS5331-G2/assign3 | true | false | true | @@ -30,7 +30,7 @@ class Endpoint(object):
return self.htmlForm
def get_url_till_path(self):
- return self.scheme + "://" + self.host + self.path
+ return self.scheme + "://" + self.host + self.get_path()
def has_query_string(self):
try:
| return self . scheme + "://" + self . host + self . path | return self . scheme + "://" + self . host + self . get_path ( ) | CHANGE_BINARY_OPERAND | [["Insert", ["binary_operator", 3, 10, 3, 53], ["call", "N0"], 2], ["Move", "N0", ["attribute", 3, 44, 3, 53], 0], ["Insert", "N0", ["argument_list", "N1"], 1], ["Update", ["identifier:path", 3, 49, 3, 53], "get_path"], ["Insert", "N1", ["(:(", "T"], 0], ["Insert", "N1", ["):)", "T"], 1]] | CS5331-G2/assign3@8d6138537984a210319c76dcd5d10ffae59eddf2 | Fix Endpoint not returning the correct path. query strings were included | [
{
"sha": "fd17017ab43948d18028c6a46d7b7ce41923fd42",
"filename": "Endpoint.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/CS5331-G2/assign3/blob/8d6138537984a210319c76dcd5d10ffae59eddf2/Endpoint.py",
"raw_url": "https://github.com/CS5331-G2/assign3/raw/8d6138537984a210319c76dcd5d10ffae59eddf2/Endpoint.py",
"contents_url": "https://api.github.com/repos/CS5331-G2/assign3/contents/Endpoint.py?ref=8d6138537984a210319c76dcd5d10ffae59eddf2",
"patch": "@@ -30,7 +30,7 @@ def get_form(self):\n \t\treturn self.htmlForm\n \n \tdef get_url_till_path(self):\n-\t\treturn self.scheme + \"://\" + self.host + self.path\n+\t\treturn self.scheme + \"://\" + self.host + self.get_path()\n \n \tdef has_query_string(self):\n \t\ttry:"
}
] |
assign3 | d94af641ffaf8947a3ec15aba5a0262d6f00f187 | 0f283eead4b4f86885263ea9343890cf6d5447bd | OpenRedirAttackModule.py | https://github.com/CS5331-G2/assign3 | true | false | true | @@ -65,7 +65,7 @@ class OpenRedirAttackModule(AttackModule):
# Otherwise look for <script>
scriptTags = bs.findAll("script")
- for script in scripts:
+ for script in scriptTags:
if len(re.findall('document\.location = "(.*?)";', str(script))) > 0:
matches = re.findall('document\.location = "(.*?)";', str(script))
for match in matches:
| for script in scripts : if len ( re . findall ( 'document\.location = "(.*?)";' , str ( script ) ) ) > 0 : matches = re . findall ( 'document\.location = "(.*?)";' , str ( script ) ) for match in matches : | for script in scriptTags : if len ( re . findall ( 'document\.location = "(.*?)";' , str ( script ) ) ) > 0 : matches = re . findall ( 'document\.location = "(.*?)";' , str ( script ) ) for match in matches : | CHANGE_IDENTIFIER_USED | [["Update", ["identifier:scripts", 3, 19, 3, 26], "scriptTags"]] | CS5331-G2/assign3@d94af641ffaf8947a3ec15aba5a0262d6f00f187 | Fix incorrect variable name | [
{
"sha": "c159b38dd46e3dcd971e481846450480b5fc6611",
"filename": "OpenRedirAttackModule.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/CS5331-G2/assign3/blob/d94af641ffaf8947a3ec15aba5a0262d6f00f187/OpenRedirAttackModule.py",
"raw_url": "https://github.com/CS5331-G2/assign3/raw/d94af641ffaf8947a3ec15aba5a0262d6f00f187/OpenRedirAttackModule.py",
"contents_url": "https://api.github.com/repos/CS5331-G2/assign3/contents/OpenRedirAttackModule.py?ref=d94af641ffaf8947a3ec15aba5a0262d6f00f187",
"patch": "@@ -65,7 +65,7 @@ def is_attack_successful(self, res):\n \n \t\t\t\t# Otherwise look for <script>\n \t\t\t\tscriptTags = bs.findAll(\"script\")\n-\t\t\t\tfor script in scripts:\n+\t\t\t\tfor script in scriptTags:\n \t\t\t\t\tif len(re.findall('document\\.location = \"(.*?)\";', str(script))) > 0:\n \t\t\t\t\t\tmatches = re.findall('document\\.location = \"(.*?)\";', str(script))\n \t\t\t\t\t\tfor match in matches:"
}
] |
djangoboards | b8e4db851a158fe4b24544f7eea6e899176d019f | 26cdb0ce58d9084e23b4188ce04462923b542f71 | djangoboards/settings.py | https://github.com/Annihilater/djangoboards | true | false | false | @@ -23,7 +23,7 @@ BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
SECRET_KEY = 'w_8*^^5-usw=j6ob78ae1noz-!^b#ts+x6jvj#y01ti%usew=j'
# SECURITY WARNING: don't run with debug turned on in production!
-DEBUG = True
+DEBUG = False
ALLOWED_HOSTS = []
| DEBUG = True | DEBUG = False | CHANGE_BOOLEAN_LITERAL | [["Insert", ["assignment", 3, 1, 3, 13], ["false:False", "T"], 2], ["Delete", ["true:True", 3, 9, 3, 13]]] | Annihilater/djangoboards@b8e4db851a158fe4b24544f7eea6e899176d019f | Set DEBUG = False | [
{
"sha": "676a256793dd74a76812c99022afd1726f4157bb",
"filename": "djangoboards/settings.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/Annihilater/djangoboards/blob/b8e4db851a158fe4b24544f7eea6e899176d019f/djangoboards%2Fsettings.py",
"raw_url": "https://github.com/Annihilater/djangoboards/raw/b8e4db851a158fe4b24544f7eea6e899176d019f/djangoboards%2Fsettings.py",
"contents_url": "https://api.github.com/repos/Annihilater/djangoboards/contents/djangoboards%2Fsettings.py?ref=b8e4db851a158fe4b24544f7eea6e899176d019f",
"patch": "@@ -23,7 +23,7 @@\n SECRET_KEY = 'w_8*^^5-usw=j6ob78ae1noz-!^b#ts+x6jvj#y01ti%usew=j'\n \n # SECURITY WARNING: don't run with debug turned on in production!\n-DEBUG = True\n+DEBUG = False\n \n ALLOWED_HOSTS = []\n "
}
] |
scikit-image | 9d64d8d0dc223d522fe91ba55d7fba17a272354a | 1b501c83e13166462d648f3a1be4f5eea7c279a4 | scikits/image/_build.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -29,7 +29,7 @@ def cython(pyx_files, working_path=''):
status = os.system(cmd)
# if the resulting file is small, cython compilation failed
- if status != 0 or os.path.getsize(c_file_new):
+ if status != 0 or os.path.getsize(c_file_new) < 100:
print "Cython compilation of %s failed. Falling back " \
"on pre-generated file." % os.path.basename(pyxfile)
continue
| if status != 0 or os . path . getsize ( c_file_new ) : print "Cython compilation of %s failed. Falling back " "on pre-generated file." % os . path . basename ( pyxfile ) continue | if status != 0 or os . path . getsize ( c_file_new ) < 100 : print "Cython compilation of %s failed. Falling back " "on pre-generated file." % os . path . basename ( pyxfile ) continue | CHANGE_BINARY_OPERAND | [["Insert", ["boolean_operator", 3, 16, 3, 58], ["comparison_operator", "N0"], 2], ["Move", "N0", ["call", 3, 31, 3, 58], 0], ["Insert", "N0", ["<:<", "T"], 1], ["Insert", "N0", ["integer:100", "T"], 2]] | matsuken92/scikit-image@9d64d8d0dc223d522fe91ba55d7fba17a272354a | setup: Fix Cython build. | [
{
"sha": "277a7eae20769c97c0302d6617ec23df080ea7de",
"filename": "scikits/image/_build.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/9d64d8d0dc223d522fe91ba55d7fba17a272354a/scikits%2Fimage%2F_build.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/9d64d8d0dc223d522fe91ba55d7fba17a272354a/scikits%2Fimage%2F_build.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2F_build.py?ref=9d64d8d0dc223d522fe91ba55d7fba17a272354a",
"patch": "@@ -29,7 +29,7 @@ def cython(pyx_files, working_path=''):\n status = os.system(cmd)\n \n # if the resulting file is small, cython compilation failed\n- if status != 0 or os.path.getsize(c_file_new):\n+ if status != 0 or os.path.getsize(c_file_new) < 100:\n print \"Cython compilation of %s failed. Falling back \" \\\n \"on pre-generated file.\" % os.path.basename(pyxfile)\n continue"
}
] |
scikit-image | 1fc7a2fa5616b100cac47f91b911177de674a78d | bf9f70444fd465b9ff9566e75dd04b55ca43d830 | setup.py | https://github.com/matsuken92/scikit-image | true | false | false | @@ -17,7 +17,7 @@ MAINTAINER_EMAIL = '[email protected]'
URL = 'http://stefanv.github.com/scikits.image'
LICENSE = 'Modified BSD'
DOWNLOAD_URL = 'http://github.com/stefanv/scikits.image'
-VERSION = '0.2'
+VERSION = '0.2.1'
import os
import setuptools
| VERSION = '0.2' | VERSION = '0.2.1' | CHANGE_STRING_LITERAL | [["Update", ["string:'0.2'", 3, 23, 3, 28], "'0.2.1'"]] | matsuken92/scikit-image@1fc7a2fa5616b100cac47f91b911177de674a78d | Release 0.2.1 to fix build issues. | [
{
"sha": "47c4134c34b3eb9e66ef9247f120b56cfe189b4e",
"filename": "setup.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/1fc7a2fa5616b100cac47f91b911177de674a78d/setup.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/1fc7a2fa5616b100cac47f91b911177de674a78d/setup.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/setup.py?ref=1fc7a2fa5616b100cac47f91b911177de674a78d",
"patch": "@@ -17,7 +17,7 @@\n URL = 'http://stefanv.github.com/scikits.image'\n LICENSE = 'Modified BSD'\n DOWNLOAD_URL = 'http://github.com/stefanv/scikits.image'\n-VERSION = '0.2'\n+VERSION = '0.2.1'\n \n import os\n import setuptools"
}
] |
scikit-image | 0bb264c977cf6db3f253f86da6ad7a2102b32288 | 0593e90dd221504af5dd545c0a9f23f604bbf9f5 | setup.py | https://github.com/matsuken92/scikit-image | true | false | false | @@ -17,7 +17,7 @@ MAINTAINER_EMAIL = '[email protected]'
URL = 'http://stefanv.github.com/scikits.image'
LICENSE = 'Modified BSD'
DOWNLOAD_URL = 'http://github.com/stefanv/scikits.image'
-VERSION = '0.2.1'
+VERSION = '0.2.2'
import os
import setuptools
| VERSION = '0.2.1' | VERSION = '0.2.2' | CHANGE_STRING_LITERAL | [["Update", ["string:'0.2.1'", 3, 23, 3, 30], "'0.2.2'"]] | matsuken92/scikit-image@0bb264c977cf6db3f253f86da6ad7a2102b32288 | Set version to 0.2.2 to release a bugfix sdist. | [
{
"sha": "679b50a908b8a5549d7a404d7598d539bbddf479",
"filename": "setup.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/0bb264c977cf6db3f253f86da6ad7a2102b32288/setup.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/0bb264c977cf6db3f253f86da6ad7a2102b32288/setup.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/setup.py?ref=0bb264c977cf6db3f253f86da6ad7a2102b32288",
"patch": "@@ -17,7 +17,7 @@\n URL = 'http://stefanv.github.com/scikits.image'\n LICENSE = 'Modified BSD'\n DOWNLOAD_URL = 'http://github.com/stefanv/scikits.image'\n-VERSION = '0.2.1'\n+VERSION = '0.2.2'\n \n import os\n import setuptools"
}
] |
scikit-image | 01dca4ef5ff04df9883d2310537974fa3a98c51f | 13199840cdb6f6cad9022a42dc547744706824c6 | scikits/image/io/_plugins/freeimage_plugin.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -299,7 +299,7 @@ def _wrap_bitmap_bits_in_array(bitmap, shape, dtype):
__array_interface__ = {
'data': (bits, False),
'strides': strides,
- 'typestr': dtype.byteorder + dtype.kind + str(dtype.itemsize),
+ 'typestr': dtype.str,
'shape': tuple(shape),
}
| __array_interface__ = { 'data' : ( bits , False ) , 'strides' : strides , 'typestr' : dtype . byteorder + dtype . kind + str ( dtype . itemsize ) , 'shape' : tuple ( shape ) , } | __array_interface__ = { 'data' : ( bits , False ) , 'strides' : strides , 'typestr' : dtype . str , 'shape' : tuple ( shape ) , } | SINGLE_STMT | [["Move", ["pair", 3, 13, 3, 74], ["attribute", 3, 24, 3, 39], 2], ["Move", ["attribute", 3, 24, 3, 39], ["identifier:str", 3, 55, 3, 58], 2], ["Delete", ["identifier:byteorder", 3, 30, 3, 39]], ["Delete", ["+:+", 3, 40, 3, 41]], ["Delete", ["identifier:dtype", 3, 42, 3, 47]], ["Delete", [".:.", 3, 47, 3, 48]], ["Delete", ["identifier:kind", 3, 48, 3, 52]], ["Delete", ["attribute", 3, 42, 3, 52]], ["Delete", ["binary_operator", 3, 24, 3, 52]], ["Delete", ["+:+", 3, 53, 3, 54]], ["Delete", ["(:(", 3, 58, 3, 59]], ["Delete", ["identifier:dtype", 3, 59, 3, 64]], ["Delete", [".:.", 3, 64, 3, 65]], ["Delete", ["identifier:itemsize", 3, 65, 3, 73]], ["Delete", ["attribute", 3, 59, 3, 73]], ["Delete", ["):)", 3, 73, 3, 74]], ["Delete", ["argument_list", 3, 58, 3, 74]], ["Delete", ["call", 3, 55, 3, 74]], ["Delete", ["binary_operator", 3, 24, 3, 74]]] | matsuken92/scikit-image@01dca4ef5ff04df9883d2310537974fa3a98c51f | Found shorthand for constructing dtype str (thanks, Zach!). | [
{
"sha": "3782472704d43c93c10832f07c50b4d9b4250b26",
"filename": "scikits/image/io/_plugins/freeimage_plugin.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/01dca4ef5ff04df9883d2310537974fa3a98c51f/scikits%2Fimage%2Fio%2F_plugins%2Ffreeimage_plugin.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/01dca4ef5ff04df9883d2310537974fa3a98c51f/scikits%2Fimage%2Fio%2F_plugins%2Ffreeimage_plugin.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Fio%2F_plugins%2Ffreeimage_plugin.py?ref=01dca4ef5ff04df9883d2310537974fa3a98c51f",
"patch": "@@ -299,7 +299,7 @@ class DummyArray:\n __array_interface__ = {\r\n 'data': (bits, False),\r\n 'strides': strides,\r\n- 'typestr': dtype.byteorder + dtype.kind + str(dtype.itemsize),\r\n+ 'typestr': dtype.str,\r\n 'shape': tuple(shape),\r\n }\r\n \r"
}
] |
scikit-image | 637a568ae4725db2c4ac89e7b69bd1e63618ce14 | 65021f481cfd4c1039a7cf9ffa08bbe010a9ddd9 | scikits/image/filter/tv_denoise.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -92,7 +92,7 @@ def _tv_denoise_3d(im, eps=2.e-4, weight=100, keep_type=False, n_iter_max=200):
else:
return out
-def _tv_denoise_2d(im, weight=50, eps=2.e-4, keep_type=False, n_iter_max=200):
+def _tv_denoise_2d(im, eps=2.e-4, weight=50, keep_type=False, n_iter_max=200):
| def _tv_denoise_2d ( im , weight = 50 , eps = 2.e-4 , keep_type = False , n_iter_max = 200 ) : | def _tv_denoise_2d ( im , eps = 2.e-4 , weight = 50 , keep_type = False , n_iter_max = 200 ) : | SINGLE_STMT | [["Move", ["default_parameter", 3, 24, 3, 33], ["parameters", 3, 19, 3, 78], 4], ["Move", ["default_parameter", 3, 35, 3, 44], ["parameters", 3, 19, 3, 78], 3]] | matsuken92/scikit-image@637a568ae4725db2c4ac89e7b69bd1e63618ce14 | Fix order of keyword arguments to _tv_denoise_2d.
tv_denoise passes keyword arguments `eps` and `weight` as positional arguments, but the order in _tv_denoise_2d was switched. | [
{
"sha": "8114837c533f4e1a0633dd57d793ba0b3e0333cb",
"filename": "scikits/image/filter/tv_denoise.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/637a568ae4725db2c4ac89e7b69bd1e63618ce14/scikits%2Fimage%2Ffilter%2Ftv_denoise.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/637a568ae4725db2c4ac89e7b69bd1e63618ce14/scikits%2Fimage%2Ffilter%2Ftv_denoise.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Ffilter%2Ftv_denoise.py?ref=637a568ae4725db2c4ac89e7b69bd1e63618ce14",
"patch": "@@ -92,7 +92,7 @@ def _tv_denoise_3d(im, eps=2.e-4, weight=100, keep_type=False, n_iter_max=200):\n else:\n return out\n \n-def _tv_denoise_2d(im, weight=50, eps=2.e-4, keep_type=False, n_iter_max=200):\n+def _tv_denoise_2d(im, eps=2.e-4, weight=50, keep_type=False, n_iter_max=200):\n \"\"\"\n Perform total-variation denoising\n "
}
] |
scikit-image | 8ceb250beeaaaafdc26bc5c859d9695d6afca352 | 26402a7e67266a47befe90bb736b4f35ba1d3c8a | scikits/image/io/_plugins/freeimage_plugin.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -514,7 +514,7 @@ def imread(filename, as_grey=False):
if as_grey and len(img) == 3:
# these are the values that wikipedia says are typical
transform = numpy.array([ 0.30, 0.59, 0.11])
- return numpy.dot(img, transform)
+ return numpy.dot(img, transform).astype('uint8')
return img
def imsave(filename, img):
| return numpy . dot ( img , transform ) | return numpy . dot ( img , transform ) . astype ( 'uint8' ) | ADD_METHOD_CALL | [["Insert", ["call", 3, 16, 3, 41], ["attribute", "N0"], 0], ["Insert", ["call", 3, 16, 3, 41], ["argument_list", "N1"], 1], ["Move", "N0", ["call", 3, 16, 3, 41], 0], ["Insert", "N0", [".:.", "T"], 1], ["Insert", "N0", ["identifier:astype", "T"], 2], ["Insert", "N1", ["(:(", "T"], 0], ["Insert", "N1", ["string:'uint8'", "T"], 1], ["Insert", "N1", ["):)", "T"], 2]] | matsuken92/scikit-image@8ceb250beeaaaafdc26bc5c859d9695d6afca352 | Return correct type for as_grey with freeimage | [
{
"sha": "0109e371c7ae5c2000fc4aa9c1493ef8069a12d4",
"filename": "scikits/image/io/_plugins/freeimage_plugin.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/8ceb250beeaaaafdc26bc5c859d9695d6afca352/scikits%2Fimage%2Fio%2F_plugins%2Ffreeimage_plugin.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/8ceb250beeaaaafdc26bc5c859d9695d6afca352/scikits%2Fimage%2Fio%2F_plugins%2Ffreeimage_plugin.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Fio%2F_plugins%2Ffreeimage_plugin.py?ref=8ceb250beeaaaafdc26bc5c859d9695d6afca352",
"patch": "@@ -514,7 +514,7 @@ def imread(filename, as_grey=False):\n if as_grey and len(img) == 3:\n # these are the values that wikipedia says are typical\n transform = numpy.array([ 0.30, 0.59, 0.11])\n- return numpy.dot(img, transform)\n+ return numpy.dot(img, transform).astype('uint8')\n return img\n \n def imsave(filename, img):"
}
] |
scikit-image | a146e80cf6b960b8ced112ef0d5332a8ebba8139 | 272fbbe1eaa0030b05e18b318f711d6902be548a | doc/ext/plot_directive.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -481,7 +481,7 @@ def run_code(code, code_path, ns=None, function_name=None):
def clear_state(plot_rcparams):
plt.close('all')
- matplotlib.rc_file_defaults()
+ matplotlib.rcdefaults()
matplotlib.rcParams.update(plot_rcparams)
def render_figures(code, code_path, output_dir, output_base, context,
| matplotlib . rc_file_defaults ( ) | matplotlib . rcdefaults ( ) | WRONG_FUNCTION_NAME | [["Update", ["identifier:rc_file_defaults", 3, 16, 3, 32], "rcdefaults"]] | matsuken92/scikit-image@a146e80cf6b960b8ced112ef0d5332a8ebba8139 | Fixed broken plot_directive.py so to build the doc. | [
{
"sha": "dc86552b638586a09b2f2148edc9dac362664dc4",
"filename": "doc/ext/plot_directive.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/a146e80cf6b960b8ced112ef0d5332a8ebba8139/doc%2Fext%2Fplot_directive.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/a146e80cf6b960b8ced112ef0d5332a8ebba8139/doc%2Fext%2Fplot_directive.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/doc%2Fext%2Fplot_directive.py?ref=a146e80cf6b960b8ced112ef0d5332a8ebba8139",
"patch": "@@ -481,7 +481,7 @@ def run_code(code, code_path, ns=None, function_name=None):\n \n def clear_state(plot_rcparams):\n plt.close('all')\n- matplotlib.rc_file_defaults()\n+ matplotlib.rcdefaults()\n matplotlib.rcParams.update(plot_rcparams)\n \n def render_figures(code, code_path, output_dir, output_base, context,"
}
] |
scikit-image | 92eec1242bf6a9dd4d888ea839aca50866bc2fe0 | 70b39b80907c7d096cad6bc75b37ce3add78f649 | doc/source/conf.py | https://github.com/matsuken92/scikit-image | true | false | false | @@ -43,7 +43,7 @@ master_doc = 'index'
# General information about the project.
project = u'scikits.image'
-copyright = u'2009, SciPy Developers'
+copyright = u'2011, scikits-image team'
# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
| copyright = u'2009, SciPy Developers' | copyright = u'2011, scikits-image team' | CHANGE_STRING_LITERAL | [["Update", ["string:u'2009, SciPy Developers'", 3, 13, 3, 38], "u'2011, scikits-image team'"]] | matsuken92/scikit-image@92eec1242bf6a9dd4d888ea839aca50866bc2fe0 | DOC: fix copyright | [
{
"sha": "ac788f4fdf1573c19ce1293a1b13b65bc4596555",
"filename": "doc/source/conf.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/92eec1242bf6a9dd4d888ea839aca50866bc2fe0/doc%2Fsource%2Fconf.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/92eec1242bf6a9dd4d888ea839aca50866bc2fe0/doc%2Fsource%2Fconf.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/doc%2Fsource%2Fconf.py?ref=92eec1242bf6a9dd4d888ea839aca50866bc2fe0",
"patch": "@@ -43,7 +43,7 @@\n \n # General information about the project.\n project = u'scikits.image'\n-copyright = u'2009, SciPy Developers'\n+copyright = u'2011, scikits-image team'\n \n # The version info for the project you're documenting, acts as replacement for\n # |version| and |release|, also used in various other places throughout the"
}
] |
scikit-image | fcf4c41bd6223e67c4469851b8cdae18f56b59c5 | 24d771d3335a2e54261bdbdbffcb301648c09bac | scikits/image/filter/canny.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -50,7 +50,7 @@ def smooth_with_function_and_mask(image, function, mask):
return output_image
-def canny(image, sigma, low_threshold, high_threshold, mask=None):
+def canny(image, sigma=1., low_threshold=.1, high_threshold=.2, mask=None):
| def canny ( image , sigma , low_threshold , high_threshold , mask = None ) : | def canny ( image , sigma = 1. , low_threshold = .1 , high_threshold = .2 , mask = None ) : | SINGLE_STMT | [["Insert", ["parameters", 3, 10, 3, 66], ["default_parameter", "N0"], 3], ["Insert", ["parameters", 3, 10, 3, 66], ["default_parameter", "N1"], 6], ["Insert", ["parameters", 3, 10, 3, 66], ["default_parameter", "N2"], 8], ["Move", "N0", ["identifier:sigma", 3, 18, 3, 23], 0], ["Insert", "N0", ["=:=", "T"], 1], ["Insert", "N0", ["float:1.", "T"], 2], ["Move", "N1", ["identifier:low_threshold", 3, 25, 3, 38], 0], ["Insert", "N1", ["=:=", "T"], 1], ["Insert", "N1", ["float:.1", "T"], 2], ["Move", "N2", ["identifier:high_threshold", 3, 40, 3, 54], 0], ["Insert", "N2", ["=:=", "T"], 1], ["Insert", "N2", ["float:.2", "T"], 2]] | matsuken92/scikit-image@fcf4c41bd6223e67c4469851b8cdae18f56b59c5 | somewhat sensible default values for canny edges | [
{
"sha": "e660d28450c1acc16b6f6adf0caa3ca280b1d0a1",
"filename": "scikits/image/filter/canny.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/fcf4c41bd6223e67c4469851b8cdae18f56b59c5/scikits%2Fimage%2Ffilter%2Fcanny.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/fcf4c41bd6223e67c4469851b8cdae18f56b59c5/scikits%2Fimage%2Ffilter%2Fcanny.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Ffilter%2Fcanny.py?ref=fcf4c41bd6223e67c4469851b8cdae18f56b59c5",
"patch": "@@ -50,7 +50,7 @@ def smooth_with_function_and_mask(image, function, mask):\n return output_image\n \n \n-def canny(image, sigma, low_threshold, high_threshold, mask=None):\n+def canny(image, sigma=1., low_threshold=.1, high_threshold=.2, mask=None):\n '''Edge filter an image using the Canny algorithm.\n \n Parameters"
}
] |
scikit-image | dfad24e68260bbf47b57b6c9c0c1f25b29486ed3 | e6f660d49df70834e2a3be8f36b787eb9f59442d | scikits/image/filter/ctmf.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -15,7 +15,7 @@ import numpy as np
from . import _ctmf
from rank_order import rank_order
-def median_filter(data, mask=None, radius=1, percent=50):
+def median_filter(data, mask=None, radius=2, percent=50):
| def median_filter ( data , mask = None , radius = 1 , percent = 50 ) : | def median_filter ( data , mask = None , radius = 2 , percent = 50 ) : | CHANGE_NUMERIC_LITERAL | [["Update", ["integer:1", 3, 43, 3, 44], "2"]] | matsuken92/scikit-image@dfad24e68260bbf47b57b6c9c0c1f25b29486ed3 | rank filter has radius 2 by default. radius 1 fails ?! | [
{
"sha": "8fe5f6f653973a6ad806b327a4d90746b5d72012",
"filename": "scikits/image/filter/ctmf.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/dfad24e68260bbf47b57b6c9c0c1f25b29486ed3/scikits%2Fimage%2Ffilter%2Fctmf.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/dfad24e68260bbf47b57b6c9c0c1f25b29486ed3/scikits%2Fimage%2Ffilter%2Fctmf.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Ffilter%2Fctmf.py?ref=dfad24e68260bbf47b57b6c9c0c1f25b29486ed3",
"patch": "@@ -15,7 +15,7 @@\n from . import _ctmf\n from rank_order import rank_order\n \n-def median_filter(data, mask=None, radius=1, percent=50):\n+def median_filter(data, mask=None, radius=2, percent=50):\n '''Masked median filter with octagon shape.\n \n Parameters"
}
] |
scikit-image | e9efbbcf16347d6b6cf1880655b9e87553d6388f | 82212dd2f7a83460cb767fd09f1c01ba2be995f2 | scikits/image/filter/tests/test_ctmf.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -105,7 +105,7 @@ def test_04_01_half_masked():
def test_default_values():
img = (np.random.random((20, 20)) * 255).astype(np.uint8)
mask = np.ones((20, 20), dtype=np.uint8)
- result1 = median_filter(img, mask, radius=1, percent=50)
+ result1 = median_filter(img, mask, radius=2, percent=50)
result2 = median_filter(img)
np.testing.assert_array_equal(result1, result2)
| result1 = median_filter ( img , mask , radius = 1 , percent = 50 ) | result1 = median_filter ( img , mask , radius = 2 , percent = 50 ) | CHANGE_NUMERIC_LITERAL | [["Update", ["integer:1", 3, 47, 3, 48], "2"]] | matsuken92/scikit-image@e9efbbcf16347d6b6cf1880655b9e87553d6388f | adjusted default value test to new default values... what does that test do? | [
{
"sha": "7b269868779cf9f7680e5e465e2b9836bdebe521",
"filename": "scikits/image/filter/tests/test_ctmf.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/e9efbbcf16347d6b6cf1880655b9e87553d6388f/scikits%2Fimage%2Ffilter%2Ftests%2Ftest_ctmf.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/e9efbbcf16347d6b6cf1880655b9e87553d6388f/scikits%2Fimage%2Ffilter%2Ftests%2Ftest_ctmf.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Ffilter%2Ftests%2Ftest_ctmf.py?ref=e9efbbcf16347d6b6cf1880655b9e87553d6388f",
"patch": "@@ -105,7 +105,7 @@ def test_04_01_half_masked():\n def test_default_values():\n img = (np.random.random((20, 20)) * 255).astype(np.uint8)\n mask = np.ones((20, 20), dtype=np.uint8)\n- result1 = median_filter(img, mask, radius=1, percent=50)\n+ result1 = median_filter(img, mask, radius=2, percent=50)\n result2 = median_filter(img)\n np.testing.assert_array_equal(result1, result2)\n "
}
] |
scikit-image | a2d939af62fa68358dbbc892d6d4b7e233b12920 | b65af2727afc11075d9504e3f1b60759e2a3e40a | scikits/image/transform/tests/test_radon_transform.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -3,7 +3,7 @@ from numpy.testing import *
from scikits.image.transform import *
def rescale(x):
- x = x.astype(float, copy=True)
+ x = x.astype(float)
x -= x.min()
x /= x.max()
return x
| x = x . astype ( float , copy = True ) | x = x . astype ( float ) | SAME_FUNCTION_LESS_ARGS | [["Delete", [",:,", 3, 23, 3, 24]], ["Delete", ["identifier:copy", 3, 25, 3, 29]], ["Delete", ["=:=", 3, 29, 3, 30]], ["Delete", ["true:True", 3, 30, 3, 34]], ["Delete", ["keyword_argument", 3, 25, 3, 34]]] | matsuken92/scikit-image@a2d939af62fa68358dbbc892d6d4b7e233b12920 | BUG: Remove numpy 2 usage of .astype. | [
{
"sha": "fdbc71cfc20ec78a3abe406351f9c93e82860c28",
"filename": "scikits/image/transform/tests/test_radon_transform.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/a2d939af62fa68358dbbc892d6d4b7e233b12920/scikits%2Fimage%2Ftransform%2Ftests%2Ftest_radon_transform.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/a2d939af62fa68358dbbc892d6d4b7e233b12920/scikits%2Fimage%2Ftransform%2Ftests%2Ftest_radon_transform.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Ftransform%2Ftests%2Ftest_radon_transform.py?ref=a2d939af62fa68358dbbc892d6d4b7e233b12920",
"patch": "@@ -3,7 +3,7 @@\n from scikits.image.transform import *\n \n def rescale(x):\n- x = x.astype(float, copy=True)\n+ x = x.astype(float)\n x -= x.min()\n x /= x.max()\n return x"
}
] |
scikit-image | 5ec5c55b1a7061164558572bb52350a675c22c13 | edfb8262bae6fa0fc6208b3a09925c05fa1df962 | scikits/image/util/dtype.py | https://github.com/matsuken92/scikit-image | true | false | false | @@ -13,7 +13,7 @@ dtype_range = {np.uint8: (0, 255),
np.float32: (0, 1),
np.float64: (0, 1)}
-integer_types = (np.uint8, np.int16, np.int8, np.int16)
+integer_types = (np.uint8, np.uint16, np.int8, np.int16)
def _convert(image, dtype, prec_loss):
| np . float32 : ( 0 , 1 ) , np . float64 : ( 0 , 1 ) } integer_types = ( np . uint8 , np . int16 , np . int8 , np . int16 ) | np . float32 : ( 0 , 1 ) , np . float64 : ( 0 , 1 ) } integer_types = ( np . uint8 , np . uint16 , np . int8 , np . int16 ) | CHANGE_ATTRIBUTE_USED | [["Update", ["identifier:int16", 3, 31, 3, 36], "uint16"]] | matsuken92/scikit-image@5ec5c55b1a7061164558572bb52350a675c22c13 | BUG: Fix typo in dtype converter integer list. | [
{
"sha": "8a6906891b08ef11de533900af64c89b16cbec3d",
"filename": "scikits/image/util/dtype.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/5ec5c55b1a7061164558572bb52350a675c22c13/scikits%2Fimage%2Futil%2Fdtype.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/5ec5c55b1a7061164558572bb52350a675c22c13/scikits%2Fimage%2Futil%2Fdtype.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Futil%2Fdtype.py?ref=5ec5c55b1a7061164558572bb52350a675c22c13",
"patch": "@@ -13,7 +13,7 @@\n np.float32: (0, 1),\n np.float64: (0, 1)}\n \n-integer_types = (np.uint8, np.int16, np.int8, np.int16)\n+integer_types = (np.uint8, np.uint16, np.int8, np.int16)\n \n def _convert(image, dtype, prec_loss):\n \"\"\""
}
] |
scikit-image | c4affd4078f7327e92089cc358948c997ce93ac8 | 0b175a345f4a81f08f4544dbd053f1547c2532fe | scikits/image/color/colorconv.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -307,7 +307,7 @@ def _convert(matrix, arr):
out.shape = oldshape
out = np.swapaxes(out, 2, 0)
- return out
+ return np.ascontiguousarray(out)
def xyz2rgb(xyz):
| return out | return np . ascontiguousarray ( out ) | ADD_FUNCTION_AROUND_EXPRESSION | [["Insert", ["return_statement", 3, 5, 3, 15], ["call", "N0"], 1], ["Insert", "N0", ["attribute", "N1"], 0], ["Insert", "N0", ["argument_list", "N2"], 1], ["Insert", "N1", ["identifier:np", "T"], 0], ["Insert", "N1", [".:.", "T"], 1], ["Insert", "N1", ["identifier:ascontiguousarray", "T"], 2], ["Insert", "N2", ["(:(", "T"], 0], ["Move", "N2", ["identifier:out", 3, 12, 3, 15], 1], ["Insert", "N2", ["):)", "T"], 2]] | matsuken92/scikit-image@c4affd4078f7327e92089cc358948c997ce93ac8 | BUG: Always return contiguous array from colour conversion. | [
{
"sha": "59b2baaf030c73e4e4b96d084c9a27a9bc8bfe49",
"filename": "scikits/image/color/colorconv.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/c4affd4078f7327e92089cc358948c997ce93ac8/scikits%2Fimage%2Fcolor%2Fcolorconv.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/c4affd4078f7327e92089cc358948c997ce93ac8/scikits%2Fimage%2Fcolor%2Fcolorconv.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Fcolor%2Fcolorconv.py?ref=c4affd4078f7327e92089cc358948c997ce93ac8",
"patch": "@@ -307,7 +307,7 @@ def _convert(matrix, arr):\n out.shape = oldshape\n out = np.swapaxes(out, 2, 0)\n \n- return out\n+ return np.ascontiguousarray(out)\n \n \n def xyz2rgb(xyz):"
}
] |
scikit-image | 0a71c9060e308a35fcd4acbf38cb70922e42c4ed | 2076876d47a304dec229ab5846a57a7e1c9d1123 | scikits/image/__init__.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -43,7 +43,7 @@ def get_log(name):
import logging, sys
- logging.basicConfig(stream=sys.stdout, level=logging.DEBUG)
+ logging.basicConfig(stream=sys.stdout, level=logging.WARNING)
return logging.getLogger(name)
from util.dtype import *
| logging . basicConfig ( stream = sys . stdout , level = logging . DEBUG ) | logging . basicConfig ( stream = sys . stdout , level = logging . WARNING ) | CHANGE_ATTRIBUTE_USED | [["Update", ["identifier:DEBUG", 1, 58, 1, 63], "WARNING"]] | matsuken92/scikit-image@0a71c9060e308a35fcd4acbf38cb70922e42c4ed | BUG: Fix default log-level. | [
{
"sha": "5aed61df678100fa330dd0fa55a61317b2d10927",
"filename": "scikits/image/__init__.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/0a71c9060e308a35fcd4acbf38cb70922e42c4ed/scikits%2Fimage%2F__init__.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/0a71c9060e308a35fcd4acbf38cb70922e42c4ed/scikits%2Fimage%2F__init__.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2F__init__.py?ref=0a71c9060e308a35fcd4acbf38cb70922e42c4ed",
"patch": "@@ -43,7 +43,7 @@ def get_log(name):\n \n \"\"\"\n import logging, sys\n- logging.basicConfig(stream=sys.stdout, level=logging.DEBUG)\n+ logging.basicConfig(stream=sys.stdout, level=logging.WARNING)\n return logging.getLogger(name)\n \n from util.dtype import *"
}
] |
scikit-image | f83076f722d66ebc27d66bc13798d4e5bc9cc27a | d22da55cdc26382b501059889ac7cdfc00862f9d | scikits/image/transform/tests/test_hough_transform.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -61,7 +61,7 @@ def test_probabilistic_hough():
sorted_lines = []
for line in lines:
line = list(line)
- line.sort(lambda x,y: cmp(x[0], y[0]))
+ line.sort(key=lambda x: x[0])
sorted_lines.append(line)
assert([(25, 75), (74, 26)] in sorted_lines)
assert([(25, 25), (74, 74)] in sorted_lines)
| line . sort ( lambda x , y : cmp ( x [ 0 ] , y [ 0 ] ) ) | line . sort ( key = lambda x : x [ 0 ] ) | SINGLE_STMT | [["Insert", ["argument_list", 3, 18, 3, 47], ["keyword_argument", "N0"], 1], ["Insert", "N0", ["identifier:key", "T"], 0], ["Insert", "N0", ["=:=", "T"], 1], ["Move", "N0", ["lambda", 3, 19, 3, 46], 2], ["Move", ["lambda", 3, 19, 3, 46], ["subscript", 3, 35, 3, 39], 3], ["Delete", [",:,", 3, 27, 3, 28]], ["Delete", ["identifier:y", 3, 28, 3, 29]], ["Delete", ["identifier:cmp", 3, 31, 3, 34]], ["Delete", ["(:(", 3, 34, 3, 35]], ["Delete", [",:,", 3, 39, 3, 40]], ["Delete", ["identifier:y", 3, 41, 3, 42]], ["Delete", ["[:[", 3, 42, 3, 43]], ["Delete", ["integer:0", 3, 43, 3, 44]], ["Delete", ["]:]", 3, 44, 3, 45]], ["Delete", ["subscript", 3, 41, 3, 45]], ["Delete", ["):)", 3, 45, 3, 46]], ["Delete", ["argument_list", 3, 34, 3, 46]], ["Delete", ["call", 3, 31, 3, 46]]] | matsuken92/scikit-image@f83076f722d66ebc27d66bc13798d4e5bc9cc27a | Fix `TypeError: must use keyword argument for key function` on Python 3 | [
{
"sha": "13593150f46565146bda547f1dde3cf3b96151fd",
"filename": "scikits/image/transform/tests/test_hough_transform.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/f83076f722d66ebc27d66bc13798d4e5bc9cc27a/scikits%2Fimage%2Ftransform%2Ftests%2Ftest_hough_transform.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/f83076f722d66ebc27d66bc13798d4e5bc9cc27a/scikits%2Fimage%2Ftransform%2Ftests%2Ftest_hough_transform.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Ftransform%2Ftests%2Ftest_hough_transform.py?ref=f83076f722d66ebc27d66bc13798d4e5bc9cc27a",
"patch": "@@ -61,7 +61,7 @@ def test_probabilistic_hough():\n sorted_lines = []\n for line in lines:\n line = list(line)\n- line.sort(lambda x,y: cmp(x[0], y[0]))\n+ line.sort(key=lambda x: x[0])\n sorted_lines.append(line)\n assert([(25, 75), (74, 26)] in sorted_lines)\n assert([(25, 25), (74, 74)] in sorted_lines)"
}
] |
scikit-image | d6a55c8b7b9481b59b4e60c60deacf7f60d0ba7d | 4336361c34296b7fc141f694c4331f67f31a28f4 | scikits/image/transform/tests/test_hough_transform.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -9,7 +9,7 @@ def append_desc(func, description):
"""Append the test function ``func`` and append
``description`` to its name.
"""
- func.description = func.__module__ + '.' + func.func_name + description
+ func.description = func.__module__ + '.' + func.__name__ + description
return func
| func . description = func . __module__ + '.' + func . func_name + description | func . description = func . __module__ + '.' + func . __name__ + description | CHANGE_ATTRIBUTE_USED | [["Update", ["identifier:func_name", 3, 53, 3, 62], "__name__"]] | matsuken92/scikit-image@d6a55c8b7b9481b59b4e60c60deacf7f60d0ba7d | Fix `AttributeError: 'function' object has no attribute 'func_name'` on Python 3 | [
{
"sha": "52c70d7aa558007a15e4df56d2d2acc1c84a4918",
"filename": "scikits/image/transform/tests/test_hough_transform.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/d6a55c8b7b9481b59b4e60c60deacf7f60d0ba7d/scikits%2Fimage%2Ftransform%2Ftests%2Ftest_hough_transform.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/d6a55c8b7b9481b59b4e60c60deacf7f60d0ba7d/scikits%2Fimage%2Ftransform%2Ftests%2Ftest_hough_transform.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Ftransform%2Ftests%2Ftest_hough_transform.py?ref=d6a55c8b7b9481b59b4e60c60deacf7f60d0ba7d",
"patch": "@@ -9,7 +9,7 @@ def append_desc(func, description):\n \"\"\"Append the test function ``func`` and append\n ``description`` to its name.\n \"\"\"\n- func.description = func.__module__ + '.' + func.func_name + description\n+ func.description = func.__module__ + '.' + func.__name__ + description\n \n return func\n "
}
] |
scikit-image | b57bd821f0df367aaf0c993bce87c60875b813d2 | 0fe16b54ac347156fe0a939a0e29a9775f70e987 | scikits/image/__init__.py | https://github.com/matsuken92/scikit-image | true | false | false | @@ -47,4 +47,4 @@ def get_log(name):
logging.basicConfig(stream=sys.stdout, level=logging.WARNING)
return logging.getLogger(name)
-from util.dtype import *
+from .util.dtype import *
| from util . dtype import * | from . util . dtype import * | SINGLE_STMT | [["Insert", ["import_from_statement", 3, 1, 3, 25], ["relative_import", "N0"], 1], ["Insert", "N0", ["import_prefix", "N1"], 0], ["Move", "N0", ["dotted_name", 3, 6, 3, 16], 1], ["Insert", "N1", [".:.", "T"], 0]] | matsuken92/scikit-image@b57bd821f0df367aaf0c993bce87c60875b813d2 | Fix Python 3 import error | [
{
"sha": "c9307cf9df1427cc46311507c273ba3ebb07ffa5",
"filename": "scikits/image/__init__.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/b57bd821f0df367aaf0c993bce87c60875b813d2/scikits%2Fimage%2F__init__.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/b57bd821f0df367aaf0c993bce87c60875b813d2/scikits%2Fimage%2F__init__.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2F__init__.py?ref=b57bd821f0df367aaf0c993bce87c60875b813d2",
"patch": "@@ -47,4 +47,4 @@ def get_log(name):\n logging.basicConfig(stream=sys.stdout, level=logging.WARNING)\n return logging.getLogger(name)\n \n-from util.dtype import *\n+from .util.dtype import *"
}
] |
scikit-image | be02b9a651d8251638c2f8cfe38621482cacb0ca | b57bd821f0df367aaf0c993bce87c60875b813d2 | scikits/image/util/__init__.py | https://github.com/matsuken92/scikit-image | true | false | false | @@ -1,2 +1,2 @@
-from dtype import *
+from .dtype import *
| from dtype import * | from . dtype import * | SINGLE_STMT | [["Insert", ["import_from_statement", 0, 1, 0, 20], ["relative_import", "N0"], 1], ["Insert", "N0", ["import_prefix", "N1"], 0], ["Move", "N0", ["dotted_name", 0, 6, 0, 11], 1], ["Insert", "N1", [".:.", "T"], 0]] | matsuken92/scikit-image@be02b9a651d8251638c2f8cfe38621482cacb0ca | Fix Python 3 import error | [
{
"sha": "6ef65e205122ba3c6a6ef4a2d2eb5485a9ab602f",
"filename": "scikits/image/util/__init__.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/be02b9a651d8251638c2f8cfe38621482cacb0ca/scikits%2Fimage%2Futil%2F__init__.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/be02b9a651d8251638c2f8cfe38621482cacb0ca/scikits%2Fimage%2Futil%2F__init__.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Futil%2F__init__.py?ref=be02b9a651d8251638c2f8cfe38621482cacb0ca",
"patch": "@@ -1,2 +1,2 @@\n-from dtype import *\n+from .dtype import *\n "
}
] |
scikit-image | 58226e3fca942f4424f2777a2ee3970b2ac7d7e8 | be02b9a651d8251638c2f8cfe38621482cacb0ca | scikits/image/transform/hough_transform.py | https://github.com/matsuken92/scikit-image | true | false | false | @@ -2,7 +2,7 @@ __all__ = ['hough', 'probabilistic_hough']
from itertools import izip
import numpy as np
-from _hough_transform import _probabilistic_hough
+from ._hough_transform import _probabilistic_hough
def _hough(img, theta=None):
if img.ndim != 2:
| from _hough_transform import _probabilistic_hough | from . _hough_transform import _probabilistic_hough | SINGLE_STMT | [["Insert", ["import_from_statement", 3, 1, 3, 50], ["relative_import", "N0"], 1], ["Insert", "N0", ["import_prefix", "N1"], 0], ["Move", "N0", ["dotted_name", 3, 6, 3, 22], 1], ["Insert", "N1", [".:.", "T"], 0]] | matsuken92/scikit-image@58226e3fca942f4424f2777a2ee3970b2ac7d7e8 | Fix Python 3 import error | [
{
"sha": "44c26623dd23c33d8e202f12f6cc08030f51a7a3",
"filename": "scikits/image/transform/hough_transform.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/58226e3fca942f4424f2777a2ee3970b2ac7d7e8/scikits%2Fimage%2Ftransform%2Fhough_transform.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/58226e3fca942f4424f2777a2ee3970b2ac7d7e8/scikits%2Fimage%2Ftransform%2Fhough_transform.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Ftransform%2Fhough_transform.py?ref=58226e3fca942f4424f2777a2ee3970b2ac7d7e8",
"patch": "@@ -2,7 +2,7 @@\n \n from itertools import izip\n import numpy as np\n-from _hough_transform import _probabilistic_hough \n+from ._hough_transform import _probabilistic_hough \n \n def _hough(img, theta=None):\n if img.ndim != 2:"
}
] |
scikit-image | fb66138f9e52a0d772d8add6165e59de31870910 | f332b177fb15ca8517a7663410495f644fb50f70 | scikits/image/morphology/grey.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -68,7 +68,7 @@ def greyscale_dilate(image, selem, out=None):
if image is out:
raise NotImplementedError("In-place dilation not supported!")
try:
- import cmorph
+ from . import cmorph
out = cmorph.dilate(image, selem, out=out)
return out;
except ImportError:
| import cmorph | from . import cmorph | SINGLE_STMT | [["Insert", ["block", 3, 9, 5, 20], ["import_from_statement", "N0"], 0], ["Insert", "N0", ["from:from", "T"], 0], ["Insert", "N0", ["relative_import", "N1"], 1], ["Move", "N0", ["import:import", 3, 9, 3, 15], 2], ["Move", "N0", ["dotted_name", 3, 16, 3, 22], 3], ["Insert", "N1", ["import_prefix", "N2"], 0], ["Insert", "N2", [".:.", "T"], 0], ["Delete", ["import_statement", 3, 9, 3, 22]]] | matsuken92/scikit-image@fb66138f9e52a0d772d8add6165e59de31870910 | Fix ImportError on Python 3 | [
{
"sha": "2eb940247273d054cf21d18bb40e5e475161d240",
"filename": "scikits/image/morphology/grey.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/fb66138f9e52a0d772d8add6165e59de31870910/scikits%2Fimage%2Fmorphology%2Fgrey.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/fb66138f9e52a0d772d8add6165e59de31870910/scikits%2Fimage%2Fmorphology%2Fgrey.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Fmorphology%2Fgrey.py?ref=fb66138f9e52a0d772d8add6165e59de31870910",
"patch": "@@ -68,7 +68,7 @@ def greyscale_dilate(image, selem, out=None):\n if image is out:\n raise NotImplementedError(\"In-place dilation not supported!\")\n try:\n- import cmorph\n+ from . import cmorph\n out = cmorph.dilate(image, selem, out=out)\n return out;\n except ImportError:"
}
] |
scikit-image | 8a06fb79cf527fcd156f4daf4b517e69f9dca0f9 | 1aa7af64a95fe866c1b0a8da0a972d2853f9c964 | scikits/image/opencv/tests/test_opencv_cv.py | https://github.com/matsuken92/scikit-image | true | false | false | @@ -24,7 +24,7 @@ opencv_skip = dec.skipif(not loaded, 'OpenCV libraries not found')
class OpenCVTest(object):
lena_RGB_U8 = np.load(os.path.join(data_dir, 'lena_RGB_U8.npz'))['arr_0']
- lena_GRAY_U8 = np.load(os.path.join(data_dir, 'lena_GRAY_U8.npy'))['arr_0']
+ lena_GRAY_U8 = np.load(os.path.join(data_dir, 'lena_GRAY_U8.npz'))['arr_0']
class TestSobel(OpenCVTest):
| lena_GRAY_U8 = np . load ( os . path . join ( data_dir , 'lena_GRAY_U8.npy' ) ) [ 'arr_0' ] | lena_GRAY_U8 = np . load ( os . path . join ( data_dir , 'lena_GRAY_U8.npz' ) ) [ 'arr_0' ] | CHANGE_STRING_LITERAL | [["Update", ["string:'lena_GRAY_U8.npy'", 3, 51, 3, 69], "'lena_GRAY_U8.npz'"]] | matsuken92/scikit-image@8a06fb79cf527fcd156f4daf4b517e69f9dca0f9 | Fix another instance of an .npy file. | [
{
"sha": "b798b6a4e70313ab7bac391f7fc9223340a4bb3e",
"filename": "scikits/image/opencv/tests/test_opencv_cv.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/8a06fb79cf527fcd156f4daf4b517e69f9dca0f9/scikits%2Fimage%2Fopencv%2Ftests%2Ftest_opencv_cv.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/8a06fb79cf527fcd156f4daf4b517e69f9dca0f9/scikits%2Fimage%2Fopencv%2Ftests%2Ftest_opencv_cv.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Fopencv%2Ftests%2Ftest_opencv_cv.py?ref=8a06fb79cf527fcd156f4daf4b517e69f9dca0f9",
"patch": "@@ -24,7 +24,7 @@\n \n class OpenCVTest(object):\n lena_RGB_U8 = np.load(os.path.join(data_dir, 'lena_RGB_U8.npz'))['arr_0']\n- lena_GRAY_U8 = np.load(os.path.join(data_dir, 'lena_GRAY_U8.npy'))['arr_0']\n+ lena_GRAY_U8 = np.load(os.path.join(data_dir, 'lena_GRAY_U8.npz'))['arr_0']\n \n \n class TestSobel(OpenCVTest):"
}
] |
scikit-image | 65b6b6bed7aabd0c392d021dfac0ca811914ea60 | b0376721ebfede6904a351b69ae6a7c745a8ba67 | scikits/image/morphology/selem.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -69,7 +69,7 @@ def diamond(radius, dtype=np.uint8):
Parameters
----------
radius : string
- The radius of the disk-shaped structuring element.
+ The radius of the diamond-shaped structuring element.
dtype : data-type
The data type of the structuring element.
| disk - shaped structuring element . dtype : data - type | diamond - shaped structuring element . dtype : data - type | CHANGE_BINARY_OPERAND | [["Update", ["identifier:disk", 3, 26, 3, 30], "diamond"]] | matsuken92/scikit-image@65b6b6bed7aabd0c392d021dfac0ca811914ea60 | Minor fix to docstring | [
{
"sha": "4a5ee0bd9b93e0c67723040ecf9ecf2b334816a5",
"filename": "scikits/image/morphology/selem.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/65b6b6bed7aabd0c392d021dfac0ca811914ea60/scikits%2Fimage%2Fmorphology%2Fselem.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/65b6b6bed7aabd0c392d021dfac0ca811914ea60/scikits%2Fimage%2Fmorphology%2Fselem.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Fmorphology%2Fselem.py?ref=65b6b6bed7aabd0c392d021dfac0ca811914ea60",
"patch": "@@ -69,7 +69,7 @@ def diamond(radius, dtype=np.uint8):\n Parameters\n ----------\n radius : string\n- The radius of the disk-shaped structuring element.\n+ The radius of the diamond-shaped structuring element.\n \n dtype : data-type\n The data type of the structuring element."
}
] |
scikit-image | 45ee2e13237aab190ca16cdac0223e78465cd9e1 | 3892d5b3aeb18c1b0fe0d23c7e767ebc0fb728ce | skimage/transform/tests/test_project.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -15,7 +15,7 @@ def test_stackcopy():
assert_array_almost_equal(x[...,i], y)
def test_homography():
- x = np.arange(9).reshape((3, 3)) + 1
+ x = np.arange(9, dtype=np.uint8).reshape((3, 3)) + 1
theta = -np.pi/2
M = np.array([[np.cos(theta),-np.sin(theta),0],
[np.sin(theta), np.cos(theta),2],
| x = np . arange ( 9 ) . reshape ( ( 3 , 3 ) ) + 1 | x = np . arange ( 9 , dtype = np . uint8 ) . reshape ( ( 3 , 3 ) ) + 1 | SAME_FUNCTION_MORE_ARGS | [["Insert", ["argument_list", 3, 18, 3, 21], [",:,", "T"], 2], ["Insert", ["argument_list", 3, 18, 3, 21], ["keyword_argument", "N0"], 3], ["Insert", "N0", ["identifier:dtype", "T"], 0], ["Insert", "N0", ["=:=", "T"], 1], ["Insert", "N0", ["attribute", "N1"], 2], ["Insert", "N1", ["identifier:np", "T"], 0], ["Insert", "N1", [".:.", "T"], 1], ["Insert", "N1", ["identifier:uint8", "T"], 2]] | matsuken92/scikit-image@45ee2e13237aab190ca16cdac0223e78465cd9e1 | BUG: Fix failing test_homography unit test. | [
{
"sha": "2482aae0eb4783df872154f16b32091dd95bd100",
"filename": "skimage/transform/tests/test_project.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/45ee2e13237aab190ca16cdac0223e78465cd9e1/skimage%2Ftransform%2Ftests%2Ftest_project.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/45ee2e13237aab190ca16cdac0223e78465cd9e1/skimage%2Ftransform%2Ftests%2Ftest_project.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/skimage%2Ftransform%2Ftests%2Ftest_project.py?ref=45ee2e13237aab190ca16cdac0223e78465cd9e1",
"patch": "@@ -15,7 +15,7 @@ def test_stackcopy():\n assert_array_almost_equal(x[...,i], y)\n \n def test_homography():\n- x = np.arange(9).reshape((3, 3)) + 1\n+ x = np.arange(9, dtype=np.uint8).reshape((3, 3)) + 1\n theta = -np.pi/2\n M = np.array([[np.cos(theta),-np.sin(theta),0],\n [np.sin(theta), np.cos(theta),2],"
}
] |
scikit-image | cc7a54412202a18c3e91fa4e4610fbb68004c704 | 989fd6673efff176aa970bec51c857f64a25343b | skimage/data/__init__.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -52,7 +52,7 @@ def checkerboard():
edges, they also visualise distortions particularly well.
"""
- return load("chessboard_GRAY_U8.png")
+ return load("chessboard_GRAY.png")
def coins():
"""Greek coins from Pompeii.
| return load ( "chessboard_GRAY_U8.png" ) | return load ( "chessboard_GRAY.png" ) | CHANGE_STRING_LITERAL | [["Update", ["string:\"chessboard_GRAY_U8.png\"", 3, 17, 3, 41], "\"chessboard_GRAY.png\""]] | matsuken92/scikit-image@cc7a54412202a18c3e91fa4e4610fbb68004c704 | BUG: data: Fix chessboard file name. | [
{
"sha": "6d955f4f27fe414580288047e4a36f1b3d6dac50",
"filename": "skimage/data/__init__.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/cc7a54412202a18c3e91fa4e4610fbb68004c704/skimage%2Fdata%2F__init__.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/cc7a54412202a18c3e91fa4e4610fbb68004c704/skimage%2Fdata%2F__init__.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/skimage%2Fdata%2F__init__.py?ref=cc7a54412202a18c3e91fa4e4610fbb68004c704",
"patch": "@@ -52,7 +52,7 @@ def checkerboard():\n edges, they also visualise distortions particularly well.\n \n \"\"\"\n- return load(\"chessboard_GRAY_U8.png\")\n+ return load(\"chessboard_GRAY.png\")\n \n def coins():\n \"\"\"Greek coins from Pompeii."
}
] |
jasper-client | 1d65c4c334884f8d276b51d162d8abd741e1447e | a14b359941b67c0601f8ae5d4ab4ff35fbf15318 | client/modules/Gmail.py | https://github.com/pneumaticdeath/jasper-client | true | false | true | @@ -122,7 +122,7 @@ def handle(text, mic, profile):
response += ". Senders include: "
response += '...'.join(senders)
else:
- response += " from " + unittest[0]
+ response += " from " + unique_senders[0]
mic.say(response)
| else : response += " from " + unittest [ 0 ] | else : response += " from " + unique_senders [ 0 ] | CHANGE_IDENTIFIER_USED | [["Update", ["identifier:unittest", 3, 36, 3, 44], "unique_senders"]] | pneumaticdeath/jasper-client@1d65c4c334884f8d276b51d162d8abd741e1447e | null | null |
jasper-client | 32218ec9f9e52dbd492d9b02add24729da319e50 | f1ffdd71347c94b3934e9a04a504084053072dea | client/vocabcompiler.py | https://github.com/pneumaticdeath/jasper-client | true | false | true | @@ -32,7 +32,7 @@ class AbstractVocabulary(object):
__metaclass__ = ABCMeta
@classmethod
- def phrases_to_revision(self, phrases):
+ def phrases_to_revision(cls, phrases):
| def phrases_to_revision ( self , phrases ) : | def phrases_to_revision ( cls , phrases ) : | CHANGE_IDENTIFIER_USED | [["Update", ["identifier:self", 3, 29, 3, 33], "cls"]] | pneumaticdeath/jasper-client@32218ec9f9e52dbd492d9b02add24729da319e50 | null | null |
jasper-client | 72f2747f1c37296110a01b2a2f7c8d9b945e099c | 32218ec9f9e52dbd492d9b02add24729da319e50 | client/mic.py | https://github.com/pneumaticdeath/jasper-client | true | false | true | @@ -175,7 +175,7 @@ class Mic:
transcribed = self.passive_stt_engine.transcribe(
f, mode=TranscriptionMode.KEYWORD)
- if PERSONA in transcribed:
+ if any(PERSONA in phrase for phrase in transcribed):
return (THRESHOLD, PERSONA)
return (False, transcribed)
| if PERSONA in transcribed : return ( THRESHOLD , PERSONA ) | if any ( PERSONA in phrase for phrase in transcribed ) : return ( THRESHOLD , PERSONA ) | SINGLE_STMT | [["Insert", ["if_statement", 3, 9, 4, 40], ["call", "N0"], 1], ["Insert", "N0", ["identifier:any", "T"], 0], ["Insert", "N0", ["generator_expression", "N1"], 1], ["Insert", "N1", ["(:(", "T"], 0], ["Move", "N1", ["comparison_operator", 3, 12, 3, 34], 1], ["Insert", "N1", ["for_in_clause", "N2"], 2], ["Insert", "N1", ["):)", "T"], 3], ["Update", ["identifier:transcribed", 3, 23, 3, 34], "phrase"], ["Insert", "N2", ["for:for", "T"], 0], ["Insert", "N2", ["identifier:phrase", "T"], 1], ["Insert", "N2", ["in:in", "T"], 2], ["Insert", "N2", ["identifier:transcribed", "T"], 3]] | pneumaticdeath/jasper-client@72f2747f1c37296110a01b2a2f7c8d9b945e099c | null | null |
jasper-client | 99fd48fee075592f0f0c20db42041052134cba80 | b457254fdae851504341391036d0bb523d5bfd31 | client/stt.py | https://github.com/pneumaticdeath/jasper-client | true | false | true | @@ -105,7 +105,7 @@ class PocketSphinxSTT(AbstractSTTEngine):
config = {}
# HMM dir
# Try to get hmm_dir from config
- profile_path = os.path.join(os.path.dirname(__file__), 'profile.yml')
+ profile_path = jasperpath.config('profile.yml')
name_default = 'default'
path_default = jasperpath.config('vocabularies')
| profile_path = os . path . join ( os . path . dirname ( __file__ ) , 'profile.yml' ) | profile_path = jasperpath . config ( 'profile.yml' ) | SINGLE_STMT | [["Move", ["call", 3, 24, 3, 78], ["attribute", 3, 24, 3, 31], 0], ["Update", ["identifier:os", 3, 24, 3, 26], "jasperpath"], ["Move", ["attribute", 3, 24, 3, 31], [".:.", 3, 31, 3, 32], 1], ["Update", ["identifier:path", 3, 27, 3, 31], "config"], ["Move", ["argument_list", 3, 36, 3, 78], ["):)", 3, 61, 3, 62], 3], ["Delete", [".:.", 3, 26, 3, 27]], ["Delete", ["identifier:join", 3, 32, 3, 36]], ["Delete", ["attribute", 3, 24, 3, 36]], ["Delete", ["identifier:os", 3, 37, 3, 39]], ["Delete", [".:.", 3, 39, 3, 40]], ["Delete", ["identifier:path", 3, 40, 3, 44]], ["Delete", ["attribute", 3, 37, 3, 44]], ["Delete", [".:.", 3, 44, 3, 45]], ["Delete", ["identifier:dirname", 3, 45, 3, 52]], ["Delete", ["attribute", 3, 37, 3, 52]], ["Delete", ["(:(", 3, 52, 3, 53]], ["Delete", ["identifier:__file__", 3, 53, 3, 61]], ["Delete", ["argument_list", 3, 52, 3, 62]], ["Delete", ["call", 3, 37, 3, 62]], ["Delete", [",:,", 3, 62, 3, 63]], ["Delete", ["):)", 3, 77, 3, 78]]] | pneumaticdeath/jasper-client@99fd48fee075592f0f0c20db42041052134cba80 | null | null |
jasper-client | 090eb91ae97f76f25fd8b3dc248f982a14f1395c | 99fd48fee075592f0f0c20db42041052134cba80 | client/stt.py | https://github.com/pneumaticdeath/jasper-client | true | false | true | @@ -240,7 +240,7 @@ class GoogleSTT(AbstractSTTEngine):
config = {}
# HMM dir
# Try to get hmm_dir from config
- profile_path = os.path.join(os.path.dirname(__file__), 'profile.yml')
+ profile_path = jasperpath.config('profile.yml')
if os.path.exists(profile_path):
with open(profile_path, 'r') as f:
profile = yaml.safe_load(f)
| profile_path = os . path . join ( os . path . dirname ( __file__ ) , 'profile.yml' ) | profile_path = jasperpath . config ( 'profile.yml' ) | SINGLE_STMT | [["Move", ["call", 3, 24, 3, 78], ["attribute", 3, 24, 3, 31], 0], ["Update", ["identifier:os", 3, 24, 3, 26], "jasperpath"], ["Move", ["attribute", 3, 24, 3, 31], [".:.", 3, 31, 3, 32], 1], ["Update", ["identifier:path", 3, 27, 3, 31], "config"], ["Move", ["argument_list", 3, 36, 3, 78], ["):)", 3, 61, 3, 62], 3], ["Delete", [".:.", 3, 26, 3, 27]], ["Delete", ["identifier:join", 3, 32, 3, 36]], ["Delete", ["attribute", 3, 24, 3, 36]], ["Delete", ["identifier:os", 3, 37, 3, 39]], ["Delete", [".:.", 3, 39, 3, 40]], ["Delete", ["identifier:path", 3, 40, 3, 44]], ["Delete", ["attribute", 3, 37, 3, 44]], ["Delete", [".:.", 3, 44, 3, 45]], ["Delete", ["identifier:dirname", 3, 45, 3, 52]], ["Delete", ["attribute", 3, 37, 3, 52]], ["Delete", ["(:(", 3, 52, 3, 53]], ["Delete", ["identifier:__file__", 3, 53, 3, 61]], ["Delete", ["argument_list", 3, 52, 3, 62]], ["Delete", ["call", 3, 37, 3, 62]], ["Delete", [",:,", 3, 62, 3, 63]], ["Delete", ["):)", 3, 77, 3, 78]]] | pneumaticdeath/jasper-client@090eb91ae97f76f25fd8b3dc248f982a14f1395c | null | null |
jasper-client | 5e4bab9df512aaeaf735036901c55bdc3dbdb1b8 | ed26aad08d86b4afba9b0ab331dca0255fd00911 | client/test.py | https://github.com/pneumaticdeath/jasper-client | true | false | false | @@ -21,7 +21,7 @@ from stt import TranscriptionMode
DEFAULT_PROFILE = {
'prefers_email': False,
- 'location': '08544',
+ 'location': 'Cape Town',
'timezone': 'US/Eastern',
'phone_number': '012344321'
}
| DEFAULT_PROFILE = { 'prefers_email' : False , 'location' : '08544' , 'timezone' : 'US/Eastern' , 'phone_number' : '012344321' } | DEFAULT_PROFILE = { 'prefers_email' : False , 'location' : 'Cape Town' , 'timezone' : 'US/Eastern' , 'phone_number' : '012344321' } | CHANGE_STRING_LITERAL | [["Update", ["string:'08544'", 3, 17, 3, 24], "'Cape Town'"]] | pneumaticdeath/jasper-client@5e4bab9df512aaeaf735036901c55bdc3dbdb1b8 | null | null |
jasper-client | f12fa52c7badd7acc10fc54fdf99bdddc6b68c78 | 0e9a08475babbe56a9bc9c80e18437380c3c2c04 | client/mic.py | https://github.com/pneumaticdeath/jasper-client | true | false | true | @@ -31,7 +31,7 @@ class Mic:
self.passive_stt_engine = passive_stt_engine
self.active_stt_engine = active_stt_engine
self._logger.info("Initializing PyAudio. ALSA/Jack error messages " +
- "that pop up during this process are normal an " +
+ "that pop up during this process are normal and " +
"can usually be safely ignored.")
self._audio = pyaudio.PyAudio()
self._logger.info("Initialization of PyAudio completed.")
| self . _logger . info ( "Initializing PyAudio. ALSA/Jack error messages " + "that pop up during this process are normal an " + "can usually be safely ignored." ) | self . _logger . info ( "Initializing PyAudio. ALSA/Jack error messages " + "that pop up during this process are normal and " + "can usually be safely ignored." ) | CHANGE_BINARY_OPERAND | [["Update", ["string:\"that pop up during this process are normal an \"", 3, 27, 3, 75], "\"that pop up during this process are normal and \""]] | pneumaticdeath/jasper-client@f12fa52c7badd7acc10fc54fdf99bdddc6b68c78 | null | null |
jasper-client | edad75b803a83c4b457f111f0c91a5eb1bbd0284 | 144f2d0f8aca3d2d93f00ce5cde30c8e665fd3c8 | client/stt.py | https://github.com/pneumaticdeath/jasper-client | true | false | true | @@ -475,7 +475,7 @@ class AttSTT(AbstractSTTEngine):
'client_secret': self.app_secret,
'scope': 'SPEECH',
'grant_type': 'client_credentials'}
- r = requests.post('https://api.att.com/oauth/token',
+ r = requests.post('https://api.att.com/oauth/v4/token',
data=payload,
headers=headers)
self._token = r.json()['access_token']
| r = requests . post ( 'https://api.att.com/oauth/token' , data = payload , headers = headers ) | r = requests . post ( 'https://api.att.com/oauth/v4/token' , data = payload , headers = headers ) | CHANGE_STRING_LITERAL | [["Update", ["string:'https://api.att.com/oauth/token'", 3, 31, 3, 64], "'https://api.att.com/oauth/v4/token'"]] | pneumaticdeath/jasper-client@edad75b803a83c4b457f111f0c91a5eb1bbd0284 | null | null |
jasper-client | 0c1df0bba0a0318b3795387d6ff6f7e1f52a9081 | 144f2d0f8aca3d2d93f00ce5cde30c8e665fd3c8 | jasper.py | https://github.com/pneumaticdeath/jasper-client | true | false | false | @@ -137,7 +137,7 @@ if __name__ == "__main__":
try:
app = Jasper()
except Exception:
- logger.exception("Error occured!", exc_info=True)
+ logger.error("Error occured!", exc_info=True)
sys.exit(1)
app.run()
| logger . exception ( "Error occured!" , exc_info = True ) | logger . error ( "Error occured!" , exc_info = True ) | WRONG_FUNCTION_NAME | [["Update", ["identifier:exception", 3, 16, 3, 25], "error"]] | pneumaticdeath/jasper-client@0c1df0bba0a0318b3795387d6ff6f7e1f52a9081 | null | null |
jasper-client | 95375241ba75db98d958442bc2837efa77315e1d | d519ec544b7e6469f2cfd7aa7d0ecc1062695a85 | client/games/blackjack.py | https://github.com/pneumaticdeath/jasper-client | true | false | true | @@ -167,7 +167,7 @@ Pass input_func and output_func with appropriate vectors for other implementatio
output_func('How many players?')
n = read_int(low_limit=1, high_limit=10, input_func=input_func, output_func=output_func)
dealer.deal(n)
- output_func('Dealer has a face down card and a {0}'.format(str(dealer.hand(0)[1])))
+ output_func('Dealer has a face down card and {0}'.format(str(dealer.hand(0)[1])))
done = set()
while len(done) < n:
for player in range(1,n+1):
| output_func ( 'Dealer has a face down card and a {0}' . format ( str ( dealer . hand ( 0 ) [ 1 ] ) ) ) | output_func ( 'Dealer has a face down card and {0}' . format ( str ( dealer . hand ( 0 ) [ 1 ] ) ) ) | CHANGE_STRING_LITERAL | [["Update", ["string:'Dealer has a face down card and a {0}'", 3, 21, 3, 60], "'Dealer has a face down card and {0}'"]] | pneumaticdeath/jasper-client@95375241ba75db98d958442bc2837efa77315e1d | null | null |
jasper-client | 87f7f668c392bee531332610d9f1ce1491578771 | 95375241ba75db98d958442bc2837efa77315e1d | client/games/animal.py | https://github.com/pneumaticdeath/jasper-client | true | false | false | @@ -150,7 +150,7 @@ if __name__ == '__main__':
answer = sys.stdin.readline().lower().strip()
return answer
- dbfile_default = os.path.join(os.path.dirname(__file__), '..', 'static', 'animals.db')
+ dbfile_default = os.path.join(os.path.dirname(__file__), '..', '..', 'static', 'animals.db')
parser = argparse.ArgumentParser('Play a game of Animal')
parser.add_argument('--database', default=dbfile_default, help='Database file')
args = parser.parse_args()
| dbfile_default = os . path . join ( os . path . dirname ( __file__ ) , '..' , 'static' , 'animals.db' ) | dbfile_default = os . path . join ( os . path . dirname ( __file__ ) , '..' , '..' , 'static' , 'animals.db' ) | SAME_FUNCTION_MORE_ARGS | [["Insert", ["argument_list", 3, 34, 3, 91], ["string:'..'", "T"], 5], ["Insert", ["argument_list", 3, 34, 3, 91], [",:,", "T"], 6]] | pneumaticdeath/jasper-client@87f7f668c392bee531332610d9f1ce1491578771 | null | null |
jasper-client | b98dfff24ac7712c7ab7d3d9e6dc60d6bcafc3be | 38ca08c0f0cbae3428bb3c02ec45797706ff3075 | client/modules/Wumpus.py | https://github.com/pneumaticdeath/jasper-client | true | false | false | @@ -36,7 +36,7 @@ instructions = [
'In this game you are hunting the wiley (and smelly) wumpus.',
'It is in one of the twenty rooms in this cave system.',
'In two other rooms exist deep pits where you would fall to your death',
- 'You can detect the presence of a cave by the breeze is causes in nearby rooms.',
+ 'You can detect the presence of a pit by the breeze is causes in nearby rooms.',
'In two other rooms reside bats, which if disturbed, will carry you off to another room.',
'In order to kill the wumpus you must shoot it with one of your very crooked arrows.',
'The arrows can be shot through up to 5 rooms, but that will wake the wumpus and it might move.',
| 'You can detect the presence of a cave by the breeze is causes in nearby rooms.' , | 'You can detect the presence of a pit by the breeze is causes in nearby rooms.' , | CHANGE_STRING_LITERAL | [["Update", ["string:'You can detect the presence of a cave by the breeze is causes in nearby rooms.'", 3, 5, 3, 85], "'You can detect the presence of a pit by the breeze is causes in nearby rooms.'"]] | pneumaticdeath/jasper-client@b98dfff24ac7712c7ab7d3d9e6dc60d6bcafc3be | null | null |
jasper-client | 6ab987d1b66e7bd684c047dd42a10849b49cc100 | 350da5c879667453bdaff1afa7db178773880c9e | client/games/wumpus.py | https://github.com/pneumaticdeath/jasper-client | true | false | true | @@ -178,7 +178,7 @@ class Wumpus(object):
return 'Your game is over because {0}'.format(self.game_over_msg)
if destination not in self.map[self.player]:
- return 'Room {} isn\'t connected to this one.'.formast(destination)
+ return 'Room {} isn\'t connected to this one.'.format(destination)
self.player = destination
msgs = ['You move to room {0}'.format(destination)]
| return 'Room {} isn\'t connected to this one.' . formast ( destination ) | return 'Room {} isn\'t connected to this one.' . format ( destination ) | WRONG_FUNCTION_NAME | [["Update", ["identifier:formast", 3, 60, 3, 67], "format"]] | pneumaticdeath/jasper-client@6ab987d1b66e7bd684c047dd42a10849b49cc100 | null | null |
jasper-client | 7425045b0f340a0f8bb73968ffc20a0610af6c4e | 140729a26f9c0bc6297c85ce3e0566f72047e8ee | client/games/hammurabi.py | https://github.com/pneumaticdeath/jasper-client | true | false | false | @@ -156,7 +156,7 @@ if __name__ == '__main__':
help='How many acres can each person till')
parser.add_argument('--food-per-person', default=Hammurabi.food_per_person, type=int,
help='How much does each person need to eat')
- parser.add_argument('--seed-per-acre', default=Hammurabi.seed_per_acre, type=int,
+ parser.add_argument('--seed-per-acre', default=Hammurabi.seed_per_acre, type=float,
help='How much grain is needed to seed an acre of land')
args = parser.parse_args()
| parser . add_argument ( '--seed-per-acre' , default = Hammurabi . seed_per_acre , type = int , help = 'How much grain is needed to seed an acre of land' ) | parser . add_argument ( '--seed-per-acre' , default = Hammurabi . seed_per_acre , type = float , help = 'How much grain is needed to seed an acre of land' ) | CHANGE_IDENTIFIER_USED | [["Update", ["identifier:int", 3, 82, 3, 85], "float"]] | pneumaticdeath/jasper-client@7425045b0f340a0f8bb73968ffc20a0610af6c4e | null | null |
estate | 9aef3174d2c372734c6a48f8c0e3884d377b0dea | 711639a82cd644055edcf67ff6b7925f9751110c | purchase_indonesia_service_receipt_note/models/inherit_purchase_order.py | https://github.com/sutanto62/estate | true | false | true | @@ -44,7 +44,7 @@ class InheritPurchaseOrder(models.Model):
'purchase_id': purchase_order.id,
'type_location': purchase_order.type_location,
'location':purchase_order.location,
- 'pr_source' : purchase_order.purchase_order.request_id.complete_name,
+ 'pr_source' : purchase_order.request_id.complete_name,
'srn_no' : self.env['ir.sequence'].next_by_code(sequence_name)
}
self.env['stock.picking'].search([('purchase_id','=',self.id)]).write(purchase_data)
| purchase_order . purchase_order . request_id . complete_name , | purchase_order . request_id . complete_name , | SINGLE_STMT | [["Delete", ["identifier:purchase_order", 3, 50, 3, 64]], ["Delete", [".:.", 3, 64, 3, 65]]] | sutanto62/estate@9aef3174d2c372734c6a48f8c0e3884d377b0dea | [FIX] purchase_indonesia_service_receipt_note : fix bug cannot approve QCF | [
{
"sha": "4b1539fb5fabf74b077b3eae94f33a31f6a41c84",
"filename": "purchase_indonesia_service_receipt_note/models/inherit_purchase_order.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/9aef3174d2c372734c6a48f8c0e3884d377b0dea/purchase_indonesia_service_receipt_note%2Fmodels%2Finherit_purchase_order.py",
"raw_url": "https://github.com/sutanto62/estate/raw/9aef3174d2c372734c6a48f8c0e3884d377b0dea/purchase_indonesia_service_receipt_note%2Fmodels%2Finherit_purchase_order.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/purchase_indonesia_service_receipt_note%2Fmodels%2Finherit_purchase_order.py?ref=9aef3174d2c372734c6a48f8c0e3884d377b0dea",
"patch": "@@ -44,7 +44,7 @@ def _update_shipping(self):\n 'purchase_id': purchase_order.id,\n 'type_location': purchase_order.type_location,\n 'location':purchase_order.location,\n- 'pr_source' : purchase_order.purchase_order.request_id.complete_name,\n+ 'pr_source' : purchase_order.request_id.complete_name,\n 'srn_no' : self.env['ir.sequence'].next_by_code(sequence_name)\n }\n self.env['stock.picking'].search([('purchase_id','=',self.id)]).write(purchase_data)"
}
] |
estate | 5001331e37eed3b08625cc50cf2d7e354f36bfa3 | 1ab540c18578943311523413fd6f9efe0c74f88c | purchase_indonesia/models/inherit_stock_picking.py | https://github.com/sutanto62/estate | true | false | true | @@ -323,7 +323,7 @@ class InheritStockPicking(models.Model):
temp_qty_done= 0
for record in item.pack_operation_product_ids:
- if record.qty_done > 0:
+ if record.qty_done > 0 or record.qty_done < 0:
temp_qty_done = temp_qty_done + 1
if temp_qty_done == 0:
| if record . qty_done > 0 : temp_qty_done = temp_qty_done + 1 | if record . qty_done > 0 or record . qty_done < 0 : temp_qty_done = temp_qty_done + 1 | LESS_SPECIFIC_IF | [["Insert", ["if_statement", 3, 17, 4, 59], ["boolean_operator", "N0"], 1], ["Move", "N0", ["comparison_operator", 3, 20, 3, 39], 0], ["Insert", "N0", ["or:or", "T"], 1], ["Insert", "N0", ["comparison_operator", "N1"], 2], ["Insert", "N1", ["attribute", "N2"], 0], ["Insert", "N1", ["<:<", "T"], 1], ["Insert", "N1", ["integer:0", "T"], 2], ["Insert", "N2", ["identifier:record", "T"], 0], ["Insert", "N2", [".:.", "T"], 1], ["Insert", "N2", ["identifier:qty_done", "T"], 2]] | sutanto62/estate@5001331e37eed3b08625cc50cf2d7e354f36bfa3 | [FIX] purchase_indonesia : kurang kondisi saat nilai qty done < 0 saat requester approve | [
{
"sha": "8b2115d2440224d46fc716bd1e24bddc0ffe3038",
"filename": "purchase_indonesia/models/inherit_stock_picking.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/5001331e37eed3b08625cc50cf2d7e354f36bfa3/purchase_indonesia%2Fmodels%2Finherit_stock_picking.py",
"raw_url": "https://github.com/sutanto62/estate/raw/5001331e37eed3b08625cc50cf2d7e354f36bfa3/purchase_indonesia%2Fmodels%2Finherit_stock_picking.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/purchase_indonesia%2Fmodels%2Finherit_stock_picking.py?ref=5001331e37eed3b08625cc50cf2d7e354f36bfa3",
"patch": "@@ -323,7 +323,7 @@ def action_validate_user(self):\n temp_qty_done= 0\n \n for record in item.pack_operation_product_ids:\n- if record.qty_done > 0:\n+ if record.qty_done > 0 or record.qty_done < 0:\n temp_qty_done = temp_qty_done + 1\n \n if temp_qty_done == 0:"
}
] |
estate | 7dc1e05ca0f48b6b034b618879339906072dd9c4 | 350d9c95e4332d2247165f105a0bf01422959822 | estate_vehicle/models/estate_timesheet.py | https://github.com/sutanto62/estate | true | false | false | @@ -324,7 +324,7 @@ class FormulaPremiActivityVehicle(models.Model):
basis = fields.Integer('Basis(Trip)')
premi_base = fields.Float('Basis Premi',digits=(2,2))
category_unit_id = fields.Many2one('master.category.unit',domain=([('type','=','1')]))
- job_id = fields.Many2one('hr.job',domain=([('department_id','=',11)]))
+ job_id = fields.Many2one('hr.job',domain=([('name','in',['Sopir','SOPIR','Driver','DRIVER'])]))
use_start = fields.Date('Use Start')
use_end = fields.Date('Use End')
| job_id = fields . Many2one ( 'hr.job' , domain = ( [ ( 'department_id' , '=' , 11 ) ] ) ) | job_id = fields . Many2one ( 'hr.job' , domain = ( [ ( 'name' , 'in' , [ 'Sopir' , 'SOPIR' , 'Driver' , 'DRIVER' ] ) ] ) ) | SINGLE_STMT | [["Move", [",:,", 3, 64, 3, 65], ["tuple", 3, 48, 3, 72], 3], ["Update", ["string:'department_id'", 3, 49, 3, 64], "'name'"], ["Insert", ["tuple", 3, 48, 3, 72], [",:,", "T"], 2], ["Update", ["string:'='", 3, 65, 3, 68], "'in'"], ["Insert", ["tuple", 3, 48, 3, 72], ["list", "N0"], 4], ["Insert", "N0", ["[:[", "T"], 0], ["Insert", "N0", ["string:'Sopir'", "T"], 1], ["Move", "N0", [",:,", 3, 68, 3, 69], 2], ["Insert", "N0", ["string:'SOPIR'", "T"], 3], ["Insert", "N0", [",:,", "T"], 4], ["Insert", "N0", ["string:'Driver'", "T"], 5], ["Insert", "N0", [",:,", "T"], 6], ["Insert", "N0", ["string:'DRIVER'", "T"], 7], ["Insert", "N0", ["]:]", "T"], 8], ["Delete", ["integer:11", 3, 69, 3, 71]]] | sutanto62/estate@7dc1e05ca0f48b6b034b618879339906072dd9c4 | [FIX] estate_vehicle : change domain job_id in master activity category | [
{
"sha": "fdb752790ed2614959d46a043a0bfbc42e613c7c",
"filename": "estate_vehicle/models/estate_timesheet.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/7dc1e05ca0f48b6b034b618879339906072dd9c4/estate_vehicle%2Fmodels%2Festate_timesheet.py",
"raw_url": "https://github.com/sutanto62/estate/raw/7dc1e05ca0f48b6b034b618879339906072dd9c4/estate_vehicle%2Fmodels%2Festate_timesheet.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate_vehicle%2Fmodels%2Festate_timesheet.py?ref=7dc1e05ca0f48b6b034b618879339906072dd9c4",
"patch": "@@ -324,7 +324,7 @@ class FormulaPremiActivityVehicle(models.Model):\n basis = fields.Integer('Basis(Trip)')\n premi_base = fields.Float('Basis Premi',digits=(2,2))\n category_unit_id = fields.Many2one('master.category.unit',domain=([('type','=','1')]))\n- job_id = fields.Many2one('hr.job',domain=([('department_id','=',11)]))\n+ job_id = fields.Many2one('hr.job',domain=([('name','in',['Sopir','SOPIR','Driver','DRIVER'])]))\n use_start = fields.Date('Use Start')\n use_end = fields.Date('Use End')\n "
}
] |
estate | 0a1fbf88df021a3457ff04f9d39c17b7c2c12661 | 2a3c69a319a1304a81861ba57b5199b7df8ae5dc | estate_workshop/__openerp__.py | https://github.com/sutanto62/estate | true | false | false | @@ -19,7 +19,7 @@
'version': '0.1',
# any module necessary for this one to work correctly
- 'depends': ['base','asset','mro','estate_vehicle','scheduler_demo'],
+ 'depends': ['base','asset','mro','estate_vehicle'],
#to create sql in odoo
# 'update_xml': ["query.sql","query_hke.sql","job_scheduling.sql"],
| 'depends' : [ 'base' , 'asset' , 'mro' , 'estate_vehicle' , 'scheduler_demo' ] , | 'depends' : [ 'base' , 'asset' , 'mro' , 'estate_vehicle' ] , | SINGLE_STMT | [["Delete", [",:,", 3, 54, 3, 55]], ["Delete", ["string:'scheduler_demo'", 3, 55, 3, 71]]] | sutanto62/estate@0a1fbf88df021a3457ff04f9d39c17b7c2c12661 | [FIX] estate_workshop : delete depends scheduler_demo | [
{
"sha": "c2f00ebbd5e5a7257bd1bdc4cf45fe94ec30b1c9",
"filename": "estate_workshop/__openerp__.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/0a1fbf88df021a3457ff04f9d39c17b7c2c12661/estate_workshop%2F__openerp__.py",
"raw_url": "https://github.com/sutanto62/estate/raw/0a1fbf88df021a3457ff04f9d39c17b7c2c12661/estate_workshop%2F__openerp__.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate_workshop%2F__openerp__.py?ref=0a1fbf88df021a3457ff04f9d39c17b7c2c12661",
"patch": "@@ -19,7 +19,7 @@\n 'version': '0.1',\n \n # any module necessary for this one to work correctly\n- 'depends': ['base','asset','mro','estate_vehicle','scheduler_demo'],\n+ 'depends': ['base','asset','mro','estate_vehicle'],\n \n #to create sql in odoo\n # 'update_xml': [\"query.sql\",\"query_hke.sql\",\"job_scheduling.sql\"],"
}
] |
estate | f65ba98f79b8c6ded6754746081fd0b08e08a99f | 16949205b032030eb9c5146ec861696577944dbe | estate/models/estate_upkeep.py | https://github.com/sutanto62/estate | true | false | true | @@ -453,7 +453,7 @@ class Upkeep(models.Model):
def draft_selected(self):
""" User asked to reopen approved or confirmed
"""
- if not self.user_has_groups('base.group_erp_manager'):
+ if not self.user_has_groups('estate.group_agronomi'):
err_msg = _('You are not authorized to redraft data')
raise ValidationError(err_msg)
| if not self . user_has_groups ( 'base.group_erp_manager' ) : err_msg = _ ( 'You are not authorized to redraft data' ) raise ValidationError ( err_msg ) | if not self . user_has_groups ( 'estate.group_agronomi' ) : err_msg = _ ( 'You are not authorized to redraft data' ) raise ValidationError ( err_msg ) | CHANGE_STRING_LITERAL | [["Update", ["string:'base.group_erp_manager'", 3, 37, 3, 61], "'estate.group_agronomi'"]] | sutanto62/estate@f65ba98f79b8c6ded6754746081fd0b08e08a99f | [FIX] estate: redraft upkeep required erp manager group - change to agranomi | [
{
"sha": "9d1bcc201a29ebbe152114650a6c45c79135015c",
"filename": "estate/models/estate_upkeep.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/f65ba98f79b8c6ded6754746081fd0b08e08a99f/estate%2Fmodels%2Festate_upkeep.py",
"raw_url": "https://github.com/sutanto62/estate/raw/f65ba98f79b8c6ded6754746081fd0b08e08a99f/estate%2Fmodels%2Festate_upkeep.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate%2Fmodels%2Festate_upkeep.py?ref=f65ba98f79b8c6ded6754746081fd0b08e08a99f",
"patch": "@@ -453,7 +453,7 @@ def button_cancel(self):\n def draft_selected(self):\n \"\"\" User asked to reopen approved or confirmed\n \"\"\"\n- if not self.user_has_groups('base.group_erp_manager'):\n+ if not self.user_has_groups('estate.group_agronomi'):\n err_msg = _('You are not authorized to redraft data')\n raise ValidationError(err_msg)\n "
}
] |
estate | 95ebf0a383fd70c828ccf31e7861643d61bcce38 | 2f508821e9d16f9a402d823590f6ae3f4e7e22ef | hr_fingerprint_report/models/inherited_fingerprint.py | https://github.com/sutanto62/estate | true | false | false | @@ -33,7 +33,7 @@ class FingerAttendance(models.Model):
schedule_id = fields.Many2one(related='contract_id.working_hours',
help='Help to get time start and time end.', store=True)
contract_id = fields.Many2one('hr.contract', 'Contract', compute='_compute_employee',
- help='Working schedule might be updated based on contract.')
+ help='Working schedule might be updated based on contract.', store=True)
# surrogate
db_id_c = fields.Char('Emp No.', compute='_compute_pivot')
| contract_id = fields . Many2one ( 'hr.contract' , 'Contract' , compute = '_compute_employee' , help = 'Working schedule might be updated based on contract.' ) | contract_id = fields . Many2one ( 'hr.contract' , 'Contract' , compute = '_compute_employee' , help = 'Working schedule might be updated based on contract.' , store = True ) | SAME_FUNCTION_MORE_ARGS | [["Insert", ["argument_list", 2, 34, 3, 95], [",:,", "T"], 8], ["Insert", ["argument_list", 2, 34, 3, 95], ["keyword_argument", "N0"], 9], ["Insert", "N0", ["identifier:store", "T"], 0], ["Insert", "N0", ["=:=", "T"], 1], ["Insert", "N0", ["true:True", "T"], 2]] | sutanto62/estate@95ebf0a383fd70c828ccf31e7861643d61bcce38 | [HOTFIX] hr_fingerprint_report : saving new contract took long time
#675: HR Employee : Penambahan Kontrak Baru Load Lama Saat Simpan | [
{
"sha": "9229267ae58637e961bf588b447cc893b4b83c9f",
"filename": "hr_fingerprint_report/models/inherited_fingerprint.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/95ebf0a383fd70c828ccf31e7861643d61bcce38/hr_fingerprint_report%2Fmodels%2Finherited_fingerprint.py",
"raw_url": "https://github.com/sutanto62/estate/raw/95ebf0a383fd70c828ccf31e7861643d61bcce38/hr_fingerprint_report%2Fmodels%2Finherited_fingerprint.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/hr_fingerprint_report%2Fmodels%2Finherited_fingerprint.py?ref=95ebf0a383fd70c828ccf31e7861643d61bcce38",
"patch": "@@ -33,7 +33,7 @@ class FingerAttendance(models.Model):\n schedule_id = fields.Many2one(related='contract_id.working_hours',\n help='Help to get time start and time end.', store=True)\n contract_id = fields.Many2one('hr.contract', 'Contract', compute='_compute_employee',\n- help='Working schedule might be updated based on contract.')\n+ help='Working schedule might be updated based on contract.', store=True)\n \n # surrogate\n db_id_c = fields.Char('Emp No.', compute='_compute_pivot')"
}
] |
estate | 0f2fcaa60791a1d0813947602c7badaee07c30d1 | 0761b4f66e58dbc3a68d6cbb21928ce757bda12a | purchase_indonesia/models/procur_request_link.py | https://github.com/sutanto62/estate | true | false | true | @@ -760,7 +760,7 @@ class InheritPurchaseRequest(models.Model):
elif self.type_functional == 'technic' and self._get_total_price_budget() < self._get_price_low() or self.type_functional == 'technic' and self._get_total_price_budget() >= self._get_price_low():
state_data = {'state':'technic5','assigned_to':self._get_technic_ie()}
elif (self.type_functional == 'general' and self.department_id.code not in self._get_department_code()and self._get_total_price_budget() < self._get_price_low()) or (self.type_functional == 'general' and self.department_id.code not in self._get_department_code() and self._get_total_price_budget() >= self._get_price_low()) :
- state_data = {'state':'technic3','assigned_to':self.product_category_id.get_technical_checker()}
+ state_data = {'state':'technic3','assigned_to':self.product_category_id.get_technical_checker().id}
elif self.type_functional == 'general' and self.department_id.code in self._get_department_code()and self._get_total_price_budget() < self._get_price_low():
if self.product_category_id.get_technical_checker():
state_data = {'state':'technic3','assigned_to':self.product_category_id.get_technical_checker().id}
| elif ( self . type_functional == 'general' and self . department_id . code not in self . _get_department_code ( ) and self . _get_total_price_budget ( ) < self . _get_price_low ( ) ) or ( self . type_functional == 'general' and self . department_id . code not in self . _get_department_code ( ) and self . _get_total_price_budget ( ) >= self . _get_price_low ( ) ) : state_data = { 'state' : 'technic3' , 'assigned_to' : self . product_category_id . get_technical_checker ( ) } | elif ( self . type_functional == 'general' and self . department_id . code not in self . _get_department_code ( ) and self . _get_total_price_budget ( ) < self . _get_price_low ( ) ) or ( self . type_functional == 'general' and self . department_id . code not in self . _get_department_code ( ) and self . _get_total_price_budget ( ) >= self . _get_price_low ( ) ) : state_data = { 'state' : 'technic3' , 'assigned_to' : self . product_category_id . get_technical_checker ( ) . id } | ADD_ATTRIBUTE_ACCESS | [["Insert", ["pair", 3, 54, 3, 116], ["attribute", "N0"], 2], ["Move", "N0", ["call", 3, 68, 3, 116], 0], ["Insert", "N0", [".:.", "T"], 1], ["Insert", "N0", ["identifier:id", "T"], 2]] | sutanto62/estate@0f2fcaa60791a1d0813947602c7badaee07c30d1 | [HOTFIX] purchase_indonesia : purchase request
#660: PP: Cross Functional | [
{
"sha": "a6ebb37c576f5370586cfc1ad39fc2a46da25f2a",
"filename": "purchase_indonesia/models/procur_request_link.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/0f2fcaa60791a1d0813947602c7badaee07c30d1/purchase_indonesia%2Fmodels%2Fprocur_request_link.py",
"raw_url": "https://github.com/sutanto62/estate/raw/0f2fcaa60791a1d0813947602c7badaee07c30d1/purchase_indonesia%2Fmodels%2Fprocur_request_link.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/purchase_indonesia%2Fmodels%2Fprocur_request_link.py?ref=0f2fcaa60791a1d0813947602c7badaee07c30d1",
"patch": "@@ -760,7 +760,7 @@ def action_budget(self,):\n elif self.type_functional == 'technic' and self._get_total_price_budget() < self._get_price_low() or self.type_functional == 'technic' and self._get_total_price_budget() >= self._get_price_low():\n state_data = {'state':'technic5','assigned_to':self._get_technic_ie()}\n elif (self.type_functional == 'general' and self.department_id.code not in self._get_department_code()and self._get_total_price_budget() < self._get_price_low()) or (self.type_functional == 'general' and self.department_id.code not in self._get_department_code() and self._get_total_price_budget() >= self._get_price_low()) :\n- state_data = {'state':'technic3','assigned_to':self.product_category_id.get_technical_checker()}\n+ state_data = {'state':'technic3','assigned_to':self.product_category_id.get_technical_checker().id}\n elif self.type_functional == 'general' and self.department_id.code in self._get_department_code()and self._get_total_price_budget() < self._get_price_low():\n if self.product_category_id.get_technical_checker():\n state_data = {'state':'technic3','assigned_to':self.product_category_id.get_technical_checker().id}"
}
] |
estate | 0cf856c71646ebbd58ab88de694a19afbdf7da42 | d5add2881e4ef45a102fee1302098a7b99c40e03 | estate_payroll/__openerp__.py | https://github.com/sutanto62/estate | true | false | false | @@ -35,7 +35,7 @@ There are three salary components.
'version': '0.1',
# any module necessary for this one to work correctly
- 'depends': ['base','hr_payroll', 'hr_indonesia'],
+ 'depends': ['base', 'estate', 'hr_payroll', 'hr_indonesia'],
# always loaded
'data': [
| 'depends' : [ 'base' , 'hr_payroll' , 'hr_indonesia' ] , | 'depends' : [ 'base' , 'estate' , 'hr_payroll' , 'hr_indonesia' ] , | SINGLE_STMT | [["Insert", ["subscript", 3, 5, 3, 53], ["string:'estate'", "T"], 5], ["Insert", ["subscript", 3, 5, 3, 53], [",:,", "T"], 6]] | sutanto62/estate@0cf856c71646ebbd58ab88de694a19afbdf7da42 | [FIX] estate_payroll: depends on estate | [
{
"sha": "c62000de2d81f2ed7f9ea69392634bde0b71fbe2",
"filename": "estate_payroll/__openerp__.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/0cf856c71646ebbd58ab88de694a19afbdf7da42/estate_payroll%2F__openerp__.py",
"raw_url": "https://github.com/sutanto62/estate/raw/0cf856c71646ebbd58ab88de694a19afbdf7da42/estate_payroll%2F__openerp__.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate_payroll%2F__openerp__.py?ref=0cf856c71646ebbd58ab88de694a19afbdf7da42",
"patch": "@@ -35,7 +35,7 @@\n 'version': '0.1',\n \n # any module necessary for this one to work correctly\n- 'depends': ['base','hr_payroll', 'hr_indonesia'],\n+ 'depends': ['base', 'estate', 'hr_payroll', 'hr_indonesia'],\n \n # always loaded\n 'data': ["
}
] |
estate | 780c130e8bfb42798f5807c651435f5aeb771957 | 427eb5a92074010215890fbf0960ee0b9ee6d406 | purchase_indonesia/models/quotation_comparison_form.py | https://github.com/sutanto62/estate | true | false | true | @@ -458,7 +458,7 @@ class QuotationComparisonForm(models.Model):
def _get_price_high(self):
#get Maximal price from purchase params for Quotation comparison Form
price_standard = self.env['purchase.params.setting'].search([('name','=',self._name)])
- price = max(price.value_params for price in price_standard)
+ price = max(float(price.value_params) for price in price_standard)
return float(price)
@api.one
| price = max ( price . value_params for price in price_standard ) | price = max ( float ( price . value_params ) for price in price_standard ) | ADD_FUNCTION_AROUND_EXPRESSION | [["Insert", ["generator_expression", 3, 20, 3, 68], ["call", "N0"], 1], ["Insert", "N0", ["identifier:float", "T"], 0], ["Insert", "N0", ["argument_list", "N1"], 1], ["Insert", "N1", ["(:(", "T"], 0], ["Move", "N1", ["attribute", 3, 21, 3, 39], 1], ["Insert", "N1", ["):)", "T"], 2]] | sutanto62/estate@780c130e8bfb42798f5807c651435f5aeb771957 | [HOTFIX] purchase_indonesia : adding cast float to string or text value | [
{
"sha": "31005642d08dbdc4caf0e6b54d0beedb7a0cc46d",
"filename": "purchase_indonesia/models/quotation_comparison_form.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/780c130e8bfb42798f5807c651435f5aeb771957/purchase_indonesia%2Fmodels%2Fquotation_comparison_form.py",
"raw_url": "https://github.com/sutanto62/estate/raw/780c130e8bfb42798f5807c651435f5aeb771957/purchase_indonesia%2Fmodels%2Fquotation_comparison_form.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/purchase_indonesia%2Fmodels%2Fquotation_comparison_form.py?ref=780c130e8bfb42798f5807c651435f5aeb771957",
"patch": "@@ -458,7 +458,7 @@ def _get_price_mid(self):\n def _get_price_high(self):\n #get Maximal price from purchase params for Quotation comparison Form\n price_standard = self.env['purchase.params.setting'].search([('name','=',self._name)])\n- price = max(price.value_params for price in price_standard)\n+ price = max(float(price.value_params) for price in price_standard)\n return float(price)\n \n @api.one"
}
] |
estate | a4600bfc93f94f3011ed2541191ae97d59999df7 | c6128d797278276c0f58b36f552e1e4a1ae849eb | estate_payroll/wizard/inherited_hr_payroll_payslips_by_employees.py | https://github.com/sutanto62/estate | true | false | true | @@ -18,7 +18,7 @@ class PayslipEmployee(models.Model):
payslip_run = self.env['hr.payslip.run'].search([('id', '=', self._context['active_id'])])
# Get upkeep labour
- domain = [('state', '=', 'approved'),
+ domain = [('state', 'in', ['approved','confirmed']),
('upkeep_date', '>=', payslip_run.date_start),
('upkeep_date', '<=', payslip_run.date_end),
('employee_id.company_id', '=', payslip_run.company_id.id)]
| domain = [ ( 'state' , '=' , 'approved' ) , ( 'upkeep_date' , '>=' , payslip_run . date_start ) , ( 'upkeep_date' , '<=' , payslip_run . date_end ) , ( 'employee_id.company_id' , '=' , payslip_run . company_id . id ) ] | domain = [ ( 'state' , 'in' , [ 'approved' , 'confirmed' ] ) , ( 'upkeep_date' , '>=' , payslip_run . date_start ) , ( 'upkeep_date' , '<=' , payslip_run . date_end ) , ( 'employee_id.company_id' , '=' , payslip_run . company_id . id ) ] | SINGLE_STMT | [["Update", ["string:'='", 3, 29, 3, 32], "'in'"], ["Insert", ["tuple", 3, 19, 3, 45], ["list", "N0"], 5], ["Insert", "N0", ["[:[", "T"], 0], ["Move", "N0", ["string:'approved'", 3, 34, 3, 44], 1], ["Insert", "N0", [",:,", "T"], 2], ["Insert", "N0", ["string:'confirmed'", "T"], 3], ["Insert", "N0", ["]:]", "T"], 4]] | sutanto62/estate@a4600bfc93f94f3011ed2541191ae97d59999df7 | [HOTFIX] estate_payroll : adding 'confirmed' status in getting upkeep labour domain/filter, in order to be able to accomodate weekly closing agronomy. | [
{
"sha": "6764c33860f351cac8a542883bb8f97a175ae661",
"filename": "estate_payroll/wizard/inherited_hr_payroll_payslips_by_employees.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/a4600bfc93f94f3011ed2541191ae97d59999df7/estate_payroll%2Fwizard%2Finherited_hr_payroll_payslips_by_employees.py",
"raw_url": "https://github.com/sutanto62/estate/raw/a4600bfc93f94f3011ed2541191ae97d59999df7/estate_payroll%2Fwizard%2Finherited_hr_payroll_payslips_by_employees.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate_payroll%2Fwizard%2Finherited_hr_payroll_payslips_by_employees.py?ref=a4600bfc93f94f3011ed2541191ae97d59999df7",
"patch": "@@ -18,7 +18,7 @@ def get_upkeep(self):\n payslip_run = self.env['hr.payslip.run'].search([('id', '=', self._context['active_id'])])\n \n # Get upkeep labour\n- domain = [('state', '=', 'approved'),\n+ domain = [('state', 'in', ['approved','confirmed']),\n ('upkeep_date', '>=', payslip_run.date_start),\n ('upkeep_date', '<=', payslip_run.date_end),\n ('employee_id.company_id', '=', payslip_run.company_id.id)]"
}
] |
estate | 67e800eda1c3e4caa5b68ae872ea2f7df0b55861 | 685e7c9b8bdc9e04b7cce7caf72175a5cd578dee | purchase_indonesia/models/inherit_purchase_order.py | https://github.com/sutanto62/estate | true | false | true | @@ -89,7 +89,7 @@ class InheritPurchaseOrder(models.Model):
arrPickingAssignedManager = []
done = item.env['stock.picking'].search([('purchase_id','=',item.id),('state','=','done')])
assigned = item.env['stock.picking'].search([('purchase_id','=',item.id),('validation_manager','=',True),('state','=','assigned')])
- assigned_user = item.env['stock.picking'].search([('purchase_id','=',item.id),('validation_user','=',True),('state','=','assigned')])
+ assigned_user = item.env['stock.picking'].search([('purchase_id','=',item.id),('state','=','assigned')])
for itemDone in done:
arrPickingDone.append(itemDone.id)
for itemAssign in assigned:
| assigned_user = item . env [ 'stock.picking' ] . search ( [ ( 'purchase_id' , '=' , item . id ) , ( 'validation_user' , '=' , True ) , ( 'state' , '=' , 'assigned' ) ] ) | assigned_user = item . env [ 'stock.picking' ] . search ( [ ( 'purchase_id' , '=' , item . id ) , ( 'state' , '=' , 'assigned' ) ] ) | SINGLE_STMT | [["Delete", ["(:(", 3, 91, 3, 92]], ["Delete", ["string:'validation_user'", 3, 92, 3, 109]], ["Delete", [",:,", 3, 109, 3, 110]], ["Delete", ["string:'='", 3, 110, 3, 113]], ["Delete", [",:,", 3, 113, 3, 114]], ["Delete", ["true:True", 3, 114, 3, 118]], ["Delete", ["):)", 3, 118, 3, 119]], ["Delete", ["tuple", 3, 91, 3, 119]], ["Delete", [",:,", 3, 119, 3, 120]]] | sutanto62/estate@67e800eda1c3e4caa5b68ae872ea2f7df0b55861 | [HOTFIX] cannot search a computed field, removing from filter | [
{
"sha": "1074f2241cf5c6cac49d776c864b6cf3b8988f4a",
"filename": "purchase_indonesia/models/inherit_purchase_order.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/67e800eda1c3e4caa5b68ae872ea2f7df0b55861/purchase_indonesia%2Fmodels%2Finherit_purchase_order.py",
"raw_url": "https://github.com/sutanto62/estate/raw/67e800eda1c3e4caa5b68ae872ea2f7df0b55861/purchase_indonesia%2Fmodels%2Finherit_purchase_order.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/purchase_indonesia%2Fmodels%2Finherit_purchase_order.py?ref=67e800eda1c3e4caa5b68ae872ea2f7df0b55861",
"patch": "@@ -89,7 +89,7 @@ def _compute_grn_or_srn(self):\n arrPickingAssignedManager = []\n done = item.env['stock.picking'].search([('purchase_id','=',item.id),('state','=','done')])\n assigned = item.env['stock.picking'].search([('purchase_id','=',item.id),('validation_manager','=',True),('state','=','assigned')])\n- assigned_user = item.env['stock.picking'].search([('purchase_id','=',item.id),('validation_user','=',True),('state','=','assigned')])\n+ assigned_user = item.env['stock.picking'].search([('purchase_id','=',item.id),('state','=','assigned')])\n for itemDone in done:\n arrPickingDone.append(itemDone.id)\n for itemAssign in assigned:"
}
] |
estate | 6dbb07c8a73f2acbb795882b42d0028be2102de1 | 89ba1326ff210b38efe32ef3d9da4fd847741b87 | estate_hk_21/models/inherit_estate_upkeep.py | https://github.com/sutanto62/estate | true | false | true | @@ -29,7 +29,7 @@ class InheritUpkeepLabour(models.Model):
('upkeep_date', '<=', end),
('attendance_code_id', 'in', att_code)])
- regular_number_of_days = sum(item.number_of_day for item in upkeep_ids) + self.number_of_day
+ regular_number_of_days = sum(item.number_of_day for item in upkeep_ids) + (self.number_of_day if not self.attendance_code_id.piece_rate else 0)
if not self.attendance_code_id.piece_rate and (regular_number_of_days > monthly_limit):
# check if month to date exceed monthly limit.
| regular_number_of_days = sum ( item . number_of_day for item in upkeep_ids ) + self . number_of_day | regular_number_of_days = sum ( item . number_of_day for item in upkeep_ids ) + ( self . number_of_day if not self . attendance_code_id . piece_rate else 0 ) | CHANGE_BINARY_OPERAND | [["Insert", ["binary_operator", 3, 34, 3, 101], ["parenthesized_expression", "N0"], 2], ["Insert", "N0", ["(:(", "T"], 0], ["Insert", "N0", ["conditional_expression", "N1"], 1], ["Insert", "N0", ["):)", "T"], 2], ["Move", "N1", ["attribute", 3, 83, 3, 101], 0], ["Insert", "N1", ["if:if", "T"], 1], ["Insert", "N1", ["not_operator", "N2"], 2], ["Insert", "N1", ["else:else", "T"], 3], ["Insert", "N1", ["integer:0", "T"], 4], ["Insert", "N2", ["not:not", "T"], 0], ["Insert", "N2", ["attribute", "N3"], 1], ["Insert", "N3", ["attribute", "N4"], 0], ["Insert", "N3", [".:.", "T"], 1], ["Insert", "N3", ["identifier:piece_rate", "T"], 2], ["Insert", "N4", ["identifier:self", "T"], 0], ["Insert", "N4", [".:.", "T"], 1], ["Insert", "N4", ["identifier:attendance_code_id", "T"], 2]] | sutanto62/estate@6dbb07c8a73f2acbb795882b42d0028be2102de1 | [HOTFIX] #750 Premi pengganti HK dg K < 20 | [
{
"sha": "3d5d61fcac8a1e1e8b545e9a328607f759e5c4a5",
"filename": "estate_hk_21/models/inherit_estate_upkeep.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/6dbb07c8a73f2acbb795882b42d0028be2102de1/estate_hk_21%2Fmodels%2Finherit_estate_upkeep.py",
"raw_url": "https://github.com/sutanto62/estate/raw/6dbb07c8a73f2acbb795882b42d0028be2102de1/estate_hk_21%2Fmodels%2Finherit_estate_upkeep.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate_hk_21%2Fmodels%2Finherit_estate_upkeep.py?ref=6dbb07c8a73f2acbb795882b42d0028be2102de1",
"patch": "@@ -29,7 +29,7 @@ def _check_attendance_code(self):\n ('upkeep_date', '<=', end),\n ('attendance_code_id', 'in', att_code)])\n \n- regular_number_of_days = sum(item.number_of_day for item in upkeep_ids) + self.number_of_day\n+ regular_number_of_days = sum(item.number_of_day for item in upkeep_ids) + (self.number_of_day if not self.attendance_code_id.piece_rate else 0) \n \n if not self.attendance_code_id.piece_rate and (regular_number_of_days > monthly_limit):\n # check if month to date exceed monthly limit."
}
] |
estate | dbcfc67035773e5cf7a87b2eb6d6957d0d888cf9 | 3245f695747d5ff8e7aab83418adccb71fddcd4b | hr_indonesia/models/hr.py | https://github.com/sutanto62/estate | true | false | true | @@ -135,7 +135,7 @@ class Employee(models.Model):
""" Support scheduled resign date."""
for employee in self:
- if employee.joindate and (employee.resigndate < employee.joindate):
+ if employee.joindate and employee.resigndate and (employee.resigndate < employee.joindate):
err_msg = _('%s resign date should not early than %s' % (employee.name, employee.joindate))
raise ValidationError(err_msg)
elif not employee.joindate:
| if employee . joindate and ( employee . resigndate < employee . joindate ) : err_msg = _ ( '%s resign date should not early than %s' % ( employee . name , employee . joindate ) ) raise ValidationError ( err_msg ) elif not employee . joindate : | if employee . joindate and employee . resigndate and ( employee . resigndate < employee . joindate ) : err_msg = _ ( '%s resign date should not early than %s' % ( employee . name , employee . joindate ) ) raise ValidationError ( err_msg ) elif not employee . joindate : | MORE_SPECIFIC_IF | [["Insert", ["boolean_operator", 3, 16, 3, 79], ["boolean_operator", "N0"], 0], ["Insert", ["boolean_operator", 3, 16, 3, 79], ["and:and", "T"], 1], ["Move", "N0", ["attribute", 3, 16, 3, 33], 0], ["Move", "N0", ["and:and", 3, 34, 3, 37], 1], ["Insert", "N0", ["attribute", "N1"], 2], ["Insert", "N1", ["identifier:employee", "T"], 0], ["Insert", "N1", [".:.", "T"], 1], ["Insert", "N1", ["identifier:resigndate", "T"], 2]] | sutanto62/estate@dbcfc67035773e5cf7a87b2eb6d6957d0d888cf9 | [HOTFIX] #798 - scheduled resign, check resigndate value and joindate value before comparing | [
{
"sha": "f00a1e01d9e9530ba5934403124d22cdf44286e5",
"filename": "hr_indonesia/models/hr.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/dbcfc67035773e5cf7a87b2eb6d6957d0d888cf9/hr_indonesia%2Fmodels%2Fhr.py",
"raw_url": "https://github.com/sutanto62/estate/raw/dbcfc67035773e5cf7a87b2eb6d6957d0d888cf9/hr_indonesia%2Fmodels%2Fhr.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/hr_indonesia%2Fmodels%2Fhr.py?ref=dbcfc67035773e5cf7a87b2eb6d6957d0d888cf9",
"patch": "@@ -135,7 +135,7 @@ def _check_resigndate(self):\n \"\"\" Support scheduled resign date.\"\"\"\n \n for employee in self:\n- if employee.joindate and (employee.resigndate < employee.joindate):\n+ if employee.joindate and employee.resigndate and (employee.resigndate < employee.joindate):\n err_msg = _('%s resign date should not early than %s' % (employee.name, employee.joindate))\n raise ValidationError(err_msg)\n elif not employee.joindate:"
}
] |
estate | 1cd4f3ef1128dd625eda982c1d6e71e3f8a15a3f | 521a39b3f4aa2bd8d142c68dd7d9e7c06469630f | estate/models/estate_hr.py | https://github.com/sutanto62/estate | true | false | true | @@ -91,7 +91,7 @@ class Team(models.Model):
for team in self:
if self.env['estate.upkeep'].search([('team_id', '=', team.id),
('date', '>=', start),
- ('dateq', '<=', end)]):
+ ('date', '<=', end)]):
err_msg = _('Do not archived active team.')
raise UserError(err_msg)
| if self . env [ 'estate.upkeep' ] . search ( [ ( 'team_id' , '=' , team . id ) , ( 'date' , '>=' , start ) , ( 'dateq' , '<=' , end ) ] ) : err_msg = _ ( 'Do not archived active team.' ) raise UserError ( err_msg ) | if self . env [ 'estate.upkeep' ] . search ( [ ( 'team_id' , '=' , team . id ) , ( 'date' , '>=' , start ) , ( 'date' , '<=' , end ) ] ) : err_msg = _ ( 'Do not archived active team.' ) raise UserError ( err_msg ) | CHANGE_STRING_LITERAL | [["Update", ["string:'dateq'", 3, 51, 3, 58], "'date'"]] | sutanto62/estate@1cd4f3ef1128dd625eda982c1d6e71e3f8a15a3f | [HOTFIX] archived function for team | [
{
"sha": "eaf1c30050aca8905de3622434e0ef3638fb3fda",
"filename": "estate/models/estate_hr.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/1cd4f3ef1128dd625eda982c1d6e71e3f8a15a3f/estate%2Fmodels%2Festate_hr.py",
"raw_url": "https://github.com/sutanto62/estate/raw/1cd4f3ef1128dd625eda982c1d6e71e3f8a15a3f/estate%2Fmodels%2Festate_hr.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate%2Fmodels%2Festate_hr.py?ref=1cd4f3ef1128dd625eda982c1d6e71e3f8a15a3f",
"patch": "@@ -91,7 +91,7 @@ def toggle_active(self):\n for team in self:\n if self.env['estate.upkeep'].search([('team_id', '=', team.id),\n ('date', '>=', start),\n- ('dateq', '<=', end)]):\n+ ('date', '<=', end)]):\n err_msg = _('Do not archived active team.')\n raise UserError(err_msg)\n "
}
] |
scikit-image | b0f20da893b07c2664d9e2dcd462f9de51463e05 | 464788aded14efece13becb23731310a61e8ff9a | scikits/image/opencv/setup.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -64,7 +64,7 @@ def configuration(parent_package='', top_path=None):
# if the generated .c file differs from the one provided,
# use that one instead
if not same_cython(c_file_new, c_file):
- shutil.cp(c_file_new, c_file)
+ shutil.copy(c_file_new, c_file)
except ImportError:
# if cython is not found, we just build from the included .c files
| shutil . cp ( c_file_new , c_file ) | shutil . copy ( c_file_new , c_file ) | WRONG_FUNCTION_NAME | [["Update", ["identifier:cp", 3, 24, 3, 26], "copy"]] | matsuken92/scikit-image@b0f20da893b07c2664d9e2dcd462f9de51463e05 | Fixed shutil.cp -> shutil.copy; the former doesn't exist on python2.6 | [
{
"sha": "06748542886f7fd8707e762d233e5cda444e02f2",
"filename": "scikits/image/opencv/setup.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/b0f20da893b07c2664d9e2dcd462f9de51463e05/scikits%2Fimage%2Fopencv%2Fsetup.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/b0f20da893b07c2664d9e2dcd462f9de51463e05/scikits%2Fimage%2Fopencv%2Fsetup.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Fopencv%2Fsetup.py?ref=b0f20da893b07c2664d9e2dcd462f9de51463e05",
"patch": "@@ -64,7 +64,7 @@ def configuration(parent_package='', top_path=None):\n # if the generated .c file differs from the one provided,\n # use that one instead\n if not same_cython(c_file_new, c_file):\n- shutil.cp(c_file_new, c_file)\n+ shutil.copy(c_file_new, c_file)\n \n except ImportError:\n # if cython is not found, we just build from the included .c files"
}
] |
scikit-image | bcedeb1c83e8f3e2d1ee15ff32e73c41834160d3 | d70dfb33d020188c928fbd1b1e3ed4f6bc36b86a | scikits/image/opencv/setup.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -64,7 +64,7 @@ def configuration(parent_package='', top_path=None):
# if the generated .c file differs from the one provided,
# use that one instead
if not same_cython(c_file_new, c_file):
- shutil.cp(c_file_new, c_file)
+ shutil.copy(c_file_new, c_file)
except ImportError:
# if cython is not found, we just build from the included .c files
| shutil . cp ( c_file_new , c_file ) | shutil . copy ( c_file_new , c_file ) | WRONG_FUNCTION_NAME | [["Update", ["identifier:cp", 3, 24, 3, 26], "copy"]] | matsuken92/scikit-image@bcedeb1c83e8f3e2d1ee15ff32e73c41834160d3 | Fix typo in opencv setup. | [
{
"sha": "06748542886f7fd8707e762d233e5cda444e02f2",
"filename": "scikits/image/opencv/setup.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/bcedeb1c83e8f3e2d1ee15ff32e73c41834160d3/scikits%2Fimage%2Fopencv%2Fsetup.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/bcedeb1c83e8f3e2d1ee15ff32e73c41834160d3/scikits%2Fimage%2Fopencv%2Fsetup.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Fopencv%2Fsetup.py?ref=bcedeb1c83e8f3e2d1ee15ff32e73c41834160d3",
"patch": "@@ -64,7 +64,7 @@ def configuration(parent_package='', top_path=None):\n # if the generated .c file differs from the one provided,\n # use that one instead\n if not same_cython(c_file_new, c_file):\n- shutil.cp(c_file_new, c_file)\n+ shutil.copy(c_file_new, c_file)\n \n except ImportError:\n # if cython is not found, we just build from the included .c files"
}
] |
scikit-image | 308e76fb9ce9ac1b958c5f435aadea9e65b0826e | 4df00cb005aaa2e9887967cd8d9afc002a85bdf4 | scikits/image/io/qt_plugin.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -37,7 +37,7 @@ else:
def show(arr, block=True):
global app
- if not '-qt4thread' in sys.argv and app is None:
+ if not '-q4thread' in sys.argv and app is None:
app = QApplication([])
arr = prepare_for_display(arr)
| if not '-qt4thread' in sys . argv and app is None : app = QApplication ( [ ] ) | if not '-q4thread' in sys . argv and app is None : app = QApplication ( [ ] ) | CHANGE_STRING_LITERAL | [["Update", ["string:'-qt4thread'", 3, 16, 3, 28], "'-q4thread'"]] | matsuken92/scikit-image@308e76fb9ce9ac1b958c5f435aadea9e65b0826e | Fix q4thread typo. | [
{
"sha": "9de1ea7fe020091b7f2d7a99e1011783b2c39fe8",
"filename": "scikits/image/io/qt_plugin.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/308e76fb9ce9ac1b958c5f435aadea9e65b0826e/scikits%2Fimage%2Fio%2Fqt_plugin.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/308e76fb9ce9ac1b958c5f435aadea9e65b0826e/scikits%2Fimage%2Fio%2Fqt_plugin.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2Fio%2Fqt_plugin.py?ref=308e76fb9ce9ac1b958c5f435aadea9e65b0826e",
"patch": "@@ -37,7 +37,7 @@ def closeEvent(self, event):\n def show(arr, block=True):\n global app\n \n- if not '-qt4thread' in sys.argv and app is None:\n+ if not '-q4thread' in sys.argv and app is None:\n app = QApplication([])\n \n arr = prepare_for_display(arr)"
}
] |
scikit-image | 7770e393e07a1e2912fd7d3e9e5cf3ee75e4d75e | c118add06272f90814f4d2f23a01128f55cae428 | scikits/image/_build.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -20,7 +20,7 @@ def cython(pyx_files, working_path=''):
else:
for pyxfile in [os.path.join(working_path, f) for f in pyx_files]:
# make a backup of the good c files
- c_file = pyxfile.rstrip('pyx') + 'c'
+ c_file = pyxfile[:-4] + 'c'
c_file_new = c_file + '.new'
# run cython compiler
| else : for pyxfile in [ os . path . join ( working_path , f ) for f in pyx_files ] : c_file = pyxfile . rstrip ( 'pyx' ) + 'c' | else : for pyxfile in [ os . path . join ( working_path , f ) for f in pyx_files ] : c_file = pyxfile [ : - 4 ] + 'c' | CHANGE_BINARY_OPERAND | [["Insert", ["binary_operator", 3, 22, 3, 49], ["subscript", "N0"], 0], ["Move", "N0", ["identifier:pyxfile", 3, 22, 3, 29], 0], ["Insert", "N0", ["[:[", "T"], 1], ["Insert", "N0", ["slice", "N1"], 2], ["Insert", "N0", ["]:]", "T"], 3], ["Insert", "N1", [":::", "T"], 0], ["Insert", "N1", ["unary_operator", "N2"], 1], ["Insert", "N2", ["-:-", "T"], 0], ["Insert", "N2", ["integer:4", "T"], 1], ["Delete", [".:.", 3, 29, 3, 30]], ["Delete", ["identifier:rstrip", 3, 30, 3, 36]], ["Delete", ["attribute", 3, 22, 3, 36]], ["Delete", ["(:(", 3, 36, 3, 37]], ["Delete", ["string:'pyx'", 3, 37, 3, 42]], ["Delete", ["):)", 3, 42, 3, 43]], ["Delete", ["argument_list", 3, 36, 3, 43]], ["Delete", ["call", 3, 22, 3, 43]]] | matsuken92/scikit-image@7770e393e07a1e2912fd7d3e9e5cf3ee75e4d75e | Fix subtle rstrip bug. | [
{
"sha": "fc899e0ad1b68aae06acf12b69d71596fab8dc34",
"filename": "scikits/image/_build.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/7770e393e07a1e2912fd7d3e9e5cf3ee75e4d75e/scikits%2Fimage%2F_build.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/7770e393e07a1e2912fd7d3e9e5cf3ee75e4d75e/scikits%2Fimage%2F_build.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2F_build.py?ref=7770e393e07a1e2912fd7d3e9e5cf3ee75e4d75e",
"patch": "@@ -20,7 +20,7 @@ def cython(pyx_files, working_path=''):\n else:\n for pyxfile in [os.path.join(working_path, f) for f in pyx_files]:\n # make a backup of the good c files\n- c_file = pyxfile.rstrip('pyx') + 'c'\n+ c_file = pyxfile[:-4] + 'c'\n c_file_new = c_file + '.new'\n \n # run cython compiler"
}
] |
scikit-image | 874eb2febdcc146b5454d450d76853866841b368 | 492ee35c92f620ea342f6d24a705805e2c6102a1 | scikits/image/_build.py | https://github.com/matsuken92/scikit-image | true | false | true | @@ -20,7 +20,7 @@ def cython(pyx_files, working_path=''):
else:
for pyxfile in [os.path.join(working_path, f) for f in pyx_files]:
# make a backup of the good c files
- c_file = pyxfile[:-4] + 'c'
+ c_file = pyxfile[:-4] + '.c'
c_file_new = c_file + '.new'
# run cython compiler
| else : for pyxfile in [ os . path . join ( working_path , f ) for f in pyx_files ] : c_file = pyxfile [ : - 4 ] + 'c' | else : for pyxfile in [ os . path . join ( working_path , f ) for f in pyx_files ] : c_file = pyxfile [ : - 4 ] + '.c' | CHANGE_BINARY_OPERAND | [["Update", ["string:'c'", 3, 37, 3, 40], "'.c'"]] | matsuken92/scikit-image@874eb2febdcc146b5454d450d76853866841b368 | build: Fix c extension. | [
{
"sha": "d03fccd4fb5c25bb5d519f55bf9b2666cde9a7e9",
"filename": "scikits/image/_build.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/matsuken92/scikit-image/blob/874eb2febdcc146b5454d450d76853866841b368/scikits%2Fimage%2F_build.py",
"raw_url": "https://github.com/matsuken92/scikit-image/raw/874eb2febdcc146b5454d450d76853866841b368/scikits%2Fimage%2F_build.py",
"contents_url": "https://api.github.com/repos/matsuken92/scikit-image/contents/scikits%2Fimage%2F_build.py?ref=874eb2febdcc146b5454d450d76853866841b368",
"patch": "@@ -20,7 +20,7 @@ def cython(pyx_files, working_path=''):\n else:\n for pyxfile in [os.path.join(working_path, f) for f in pyx_files]:\n # make a backup of the good c files\n- c_file = pyxfile[:-4] + 'c'\n+ c_file = pyxfile[:-4] + '.c'\n c_file_new = c_file + '.new'\n \n # run cython compiler"
}
] |
estate | dd758717d44c34ad055f344c7e9fae1706808992 | 9e1e9b8d9ea88b917abe4e2835d6ef79daa9dda1 | hr_indonesia/__openerp__.py | https://github.com/sutanto62/estate | true | false | false | @@ -19,7 +19,7 @@
'version': '0.1',
# any module necessary for this one to work correctly
- 'depends': ['base', 'hr', 'hr_contract', 'hr_attendance'],
+ 'depends': ['base', 'hr_contract', 'hr_attendance'],
# always loaded
'data': [
| 'depends' : [ 'base' , 'hr' , 'hr_contract' , 'hr_attendance' ] , | 'depends' : [ 'base' , 'hr_contract' , 'hr_attendance' ] , | SINGLE_STMT | [["Delete", ["string:'hr'", 3, 25, 3, 29]], ["Delete", [",:,", 3, 29, 3, 30]]] | sutanto62/estate@dd758717d44c34ad055f344c7e9fae1706808992 | [FIX] hr_indonesia: remove dependency hr (avoid looping)
* hr_contract dependency hr
* hr_attendance dependency hr | [
{
"sha": "444a11510c3e9c7a4d559790d9b80fe498a248a8",
"filename": "hr_indonesia/__openerp__.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/dd758717d44c34ad055f344c7e9fae1706808992/hr_indonesia%2F__openerp__.py",
"raw_url": "https://github.com/sutanto62/estate/raw/dd758717d44c34ad055f344c7e9fae1706808992/hr_indonesia%2F__openerp__.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/hr_indonesia%2F__openerp__.py?ref=dd758717d44c34ad055f344c7e9fae1706808992",
"patch": "@@ -19,7 +19,7 @@\n 'version': '0.1',\n \n # any module necessary for this one to work correctly\n- 'depends': ['base', 'hr', 'hr_contract', 'hr_attendance'],\n+ 'depends': ['base', 'hr_contract', 'hr_attendance'],\n \n # always loaded\n 'data': ["
}
] |
estate | 02fd8aec0b05f16e8bb718a6a04320120b4d5b8e | 08f45270c533a1f96a856dea65b734403dce467d | estate_workshop/models/inherit_hr_contract.py | https://github.com/sutanto62/estate | true | false | true | @@ -30,7 +30,7 @@ class InheritHrContract(models.Model):
def _onchange_wage(self):
if self.wage and self.hour and self.day:
self.weekly_wage = self.wage/int(4)
- self.daily_wage = self.weekly_wage/float(self.day)
+ self.daily_wage = self.wage/float(self.day)
self.hourly_wage = self.daily_wage/float(self.hour)
@api.multi
| self . daily_wage = self . weekly_wage / float ( self . day ) | self . daily_wage = self . wage / float ( self . day ) | CHANGE_ATTRIBUTE_USED | [["Update", ["identifier:weekly_wage", 3, 36, 3, 47], "wage"]] | sutanto62/estate@02fd8aec0b05f16e8bb718a6a04320120b4d5b8e | [FIX] estate_workshop : fix bug error computed salary | [
{
"sha": "e4c42e62535b01b0243036c873d35477a2d097e1",
"filename": "estate_workshop/models/inherit_hr_contract.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/02fd8aec0b05f16e8bb718a6a04320120b4d5b8e/estate_workshop%2Fmodels%2Finherit_hr_contract.py",
"raw_url": "https://github.com/sutanto62/estate/raw/02fd8aec0b05f16e8bb718a6a04320120b4d5b8e/estate_workshop%2Fmodels%2Finherit_hr_contract.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate_workshop%2Fmodels%2Finherit_hr_contract.py?ref=02fd8aec0b05f16e8bb718a6a04320120b4d5b8e",
"patch": "@@ -30,7 +30,7 @@ class InheritHrContract(models.Model):\n def _onchange_wage(self):\n if self.wage and self.hour and self.day:\n self.weekly_wage = self.wage/int(4)\n- self.daily_wage = self.weekly_wage/float(self.day)\n+ self.daily_wage = self.wage/float(self.day)\n self.hourly_wage = self.daily_wage/float(self.hour)\n \n @api.multi"
}
] |
estate | 25853855ce3dcdffffd06d82e90ac84320b164bb | 548abba598d8354057a88a8705dc7d65ea176198 | estate_vehicle/models/estate_nursery_vehicle.py | https://github.com/sutanto62/estate | true | false | true | @@ -446,7 +446,7 @@ class FleetVehicleTimesheetInherits(models.Model):
def _onchange_driver(self):
arrDriver = []
if self:
- hrjob = self.env['hr.job'].search([('name','=','Driver')],limit = 1).id
+ hrjob = self.env['hr.job'].search([('name','in',['sopir','Sopir','Driver','driver'])],limit = 1).id
driver = self.env['hr.employee'].search([('job_id.id','=',hrjob)])
for d in driver:
arrDriver.append(d.id)
| hrjob = self . env [ 'hr.job' ] . search ( [ ( 'name' , '=' , 'Driver' ) ] , limit = 1 ) . id | hrjob = self . env [ 'hr.job' ] . search ( [ ( 'name' , 'in' , [ 'sopir' , 'Sopir' , 'Driver' , 'driver' ] ) ] , limit = 1 ) . id | SINGLE_STMT | [["Update", ["string:'='", 3, 56, 3, 59], "'in'"], ["Insert", ["tuple", 3, 48, 3, 69], ["list", "N0"], 5], ["Insert", "N0", ["[:[", "T"], 0], ["Insert", "N0", ["string:'sopir'", "T"], 1], ["Insert", "N0", [",:,", "T"], 2], ["Insert", "N0", ["string:'Sopir'", "T"], 3], ["Insert", "N0", [",:,", "T"], 4], ["Move", "N0", ["string:'Driver'", 3, 60, 3, 68], 5], ["Insert", "N0", [",:,", "T"], 6], ["Insert", "N0", ["string:'driver'", "T"], 7], ["Insert", "N0", ["]:]", "T"], 8]] | sutanto62/estate@25853855ce3dcdffffd06d82e90ac84320b164bb | [FIX] estate_vehicle : bug domain in employee field in timesheet vehicle not show employee type Sopir | [
{
"sha": "9151c3632c00ef893074eac84d047bcb6c871855",
"filename": "estate_vehicle/models/estate_nursery_vehicle.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/25853855ce3dcdffffd06d82e90ac84320b164bb/estate_vehicle%2Fmodels%2Festate_nursery_vehicle.py",
"raw_url": "https://github.com/sutanto62/estate/raw/25853855ce3dcdffffd06d82e90ac84320b164bb/estate_vehicle%2Fmodels%2Festate_nursery_vehicle.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate_vehicle%2Fmodels%2Festate_nursery_vehicle.py?ref=25853855ce3dcdffffd06d82e90ac84320b164bb",
"patch": "@@ -446,7 +446,7 @@ def _onchange_distance_location(self):\n def _onchange_driver(self):\n arrDriver = []\n if self:\n- hrjob = self.env['hr.job'].search([('name','=','Driver')],limit = 1).id\n+ hrjob = self.env['hr.job'].search([('name','in',['sopir','Sopir','Driver','driver'])],limit = 1).id\n driver = self.env['hr.employee'].search([('job_id.id','=',hrjob)])\n for d in driver:\n arrDriver.append(d.id)"
}
] |
estate | ff5e96da09543548772c35ab232a56ad120abd66 | df2afec71f78bacac25d889e7d67ae83430337fc | estate_workshop/models/inherit_hr_contract.py | https://github.com/sutanto62/estate | true | false | true | @@ -64,7 +64,7 @@ class InheritHrContract(models.Model):
@api.constrains('working_hours')
def _constraint_workinghours(self):
for workingHours in self:
- if workingHours.working_hours.id != True :
+ if not workingHours.working_hours.id :
error_msg = "Working Schedule Field Must be Filled"
raise exceptions.ValidationError(error_msg)
return False
| if workingHours . working_hours . id != True : error_msg = "Working Schedule Field Must be Filled" raise exceptions . ValidationError ( error_msg ) return False | if not workingHours . working_hours . id : error_msg = "Working Schedule Field Must be Filled" raise exceptions . ValidationError ( error_msg ) return False | SINGLE_STMT | [["Insert", ["if_statement", 3, 13, 6, 29], ["not_operator", "N0"], 1], ["Insert", "N0", ["not:not", "T"], 0], ["Move", "N0", ["attribute", 3, 16, 3, 45], 1], ["Delete", ["!=:!=", 3, 46, 3, 48]], ["Delete", ["true:True", 3, 49, 3, 53]], ["Delete", ["comparison_operator", 3, 16, 3, 53]]] | sutanto62/estate@ff5e96da09543548772c35ab232a56ad120abd66 | [FIX]estate_workshop : Fixing bug constraint working schedule in hr contract | [
{
"sha": "fb9099849f12bf9a6a93008f65038b1f3bae931b",
"filename": "estate_workshop/models/inherit_hr_contract.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/ff5e96da09543548772c35ab232a56ad120abd66/estate_workshop%2Fmodels%2Finherit_hr_contract.py",
"raw_url": "https://github.com/sutanto62/estate/raw/ff5e96da09543548772c35ab232a56ad120abd66/estate_workshop%2Fmodels%2Finherit_hr_contract.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate_workshop%2Fmodels%2Finherit_hr_contract.py?ref=ff5e96da09543548772c35ab232a56ad120abd66",
"patch": "@@ -64,7 +64,7 @@ def _onchange_contract_active(self):\n @api.constrains('working_hours')\n def _constraint_workinghours(self):\n for workingHours in self:\n- if workingHours.working_hours.id != True :\n+ if not workingHours.working_hours.id :\n error_msg = \"Working Schedule Field Must be Filled\"\n raise exceptions.ValidationError(error_msg)\n return False"
}
] |
estate | b76b4afb4ddd101341fedcae5bf664584f545df3 | c38560af892d4a12b7a47d0d3141cbd2b6caaa15 | estate/models/estate_upkeep.py | https://github.com/sutanto62/estate | true | false | true | @@ -1065,7 +1065,7 @@ class UpkeepLabour(models.Model):
if activity_ids:
attendance_code_domain = []
if record.activity_id.contract:
- attendance_code_domain = [('contract', 'in', (True, False))]
+ attendance_code_domain = []
else:
attendance_code_domain = [('contract', '=', False)]
return {
| attendance_code_domain = [ ( 'contract' , 'in' , ( True , False ) ) ] | attendance_code_domain = [ ] | SINGLE_STMT | [["Delete", ["(:(", 3, 51, 3, 52]], ["Delete", ["string:'contract'", 3, 52, 3, 62]], ["Delete", [",:,", 3, 62, 3, 63]], ["Delete", ["string:'in'", 3, 64, 3, 68]], ["Delete", [",:,", 3, 68, 3, 69]], ["Delete", ["(:(", 3, 70, 3, 71]], ["Delete", ["true:True", 3, 71, 3, 75]], ["Delete", [",:,", 3, 75, 3, 76]], ["Delete", ["false:False", 3, 77, 3, 82]], ["Delete", ["):)", 3, 82, 3, 83]], ["Delete", ["tuple", 3, 70, 3, 83]], ["Delete", ["):)", 3, 83, 3, 84]], ["Delete", ["tuple", 3, 51, 3, 84]]] | sutanto62/estate@b76b4afb4ddd101341fedcae5bf664584f545df3 | [FIX] estate: contract activity did not show all attendance code | [
{
"sha": "1a09a592b3d510ba45d3e7ba78e080cbb9ddbe72",
"filename": "estate/models/estate_upkeep.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/b76b4afb4ddd101341fedcae5bf664584f545df3/estate%2Fmodels%2Festate_upkeep.py",
"raw_url": "https://github.com/sutanto62/estate/raw/b76b4afb4ddd101341fedcae5bf664584f545df3/estate%2Fmodels%2Festate_upkeep.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate%2Fmodels%2Festate_upkeep.py?ref=b76b4afb4ddd101341fedcae5bf664584f545df3",
"patch": "@@ -1065,7 +1065,7 @@ def _onchange_activity_id(self):\n if activity_ids:\n attendance_code_domain = []\n if record.activity_id.contract:\n- attendance_code_domain = [('contract', 'in', (True, False))]\n+ attendance_code_domain = []\n else:\n attendance_code_domain = [('contract', '=', False)]\n return {"
}
] |
estate | 2a58f37573e7d446eb901a8947bd161e82640c0d | 474cdef037dbfb7f262e4d83e555b7a646d571da | purchase_indonesia/models/quotation_comparison_form.py | https://github.com/sutanto62/estate | true | false | true | @@ -521,7 +521,7 @@ class QuotationComparisonForm(models.Model):
+' memberikan harga kompetitif dengan harga '+goods_price\
+' dengan klausul pembayaran '+payment_term\
+' incoterm bertipe ' + incoterm\
- +'\n\n'
+ +'\n'+'\n'
remarks = remarks + v_remarks
item.remarks = remarks
| + ' memberikan harga kompetitif dengan harga ' + goods_price + ' dengan klausul pembayaran ' + payment_term + ' incoterm bertipe ' + incoterm + '\n\n' | + ' memberikan harga kompetitif dengan harga ' + goods_price + ' dengan klausul pembayaran ' + payment_term + ' incoterm bertipe ' + incoterm + '\n' + '\n' | SINGLE_STMT | [["Insert", ["binary_operator", 0, 30, 3, 37], ["binary_operator", "N0"], 0], ["Insert", ["binary_operator", 0, 30, 3, 37], ["+:+", "T"], 1], ["Insert", ["binary_operator", 0, 30, 3, 37], ["string:'\\n'", "T"], 2], ["Move", "N0", ["binary_operator", 0, 30, 2, 62], 0], ["Move", "N0", ["+:+", 3, 30, 3, 31], 1], ["Update", ["string:'\\n\\n'", 3, 31, 3, 37], "'\\n'"], ["Move", "N0", ["string:'\\n\\n'", 3, 31, 3, 37], 2]] | sutanto62/estate@2a58f37573e7d446eb901a8947bd161e82640c0d | [FIX] purchase_indonesia : fixing bug string buffered in function append remarks | [
{
"sha": "b1a0e6d1f0fc338a770e0238dfe26b6eba9c4806",
"filename": "purchase_indonesia/models/quotation_comparison_form.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/2a58f37573e7d446eb901a8947bd161e82640c0d/purchase_indonesia%2Fmodels%2Fquotation_comparison_form.py",
"raw_url": "https://github.com/sutanto62/estate/raw/2a58f37573e7d446eb901a8947bd161e82640c0d/purchase_indonesia%2Fmodels%2Fquotation_comparison_form.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/purchase_indonesia%2Fmodels%2Fquotation_comparison_form.py?ref=2a58f37573e7d446eb901a8947bd161e82640c0d",
"patch": "@@ -521,7 +521,7 @@ def _get_value_purchase_order_line(self):\n +' memberikan harga kompetitif dengan harga '+goods_price\\\n +' dengan klausul pembayaran '+payment_term\\\n +' incoterm bertipe ' + incoterm\\\n- +'\\n\\n'\n+ +'\\n'+'\\n'\n remarks = remarks + v_remarks\n \n item.remarks = remarks"
}
] |
estate | cf3c6616afea89f748c9425e1bd258fbecea9321 | 894c131e947e96df4d4686cb7c13df9c1026dad4 | purchase_indonesia/models/procur_request_link.py | https://github.com/sutanto62/estate | true | false | true | @@ -744,7 +744,7 @@ class InheritPurchaseRequest(models.Model):
state_data = []
if self._get_max_price() >= self._get_price_low() and self._get_employee().parent_id.id:
- state_data = {'state':'approval2','assigned_to':self._get_employee().parent_id.id}
+ state_data = {'state':'approval2','assigned_to':self._get_employee().parent_id.user_id.id}
elif self._get_max_price() >= self._get_price_low() and not self._get_employee().parent_id.id or self.type_functional == 'agronomy' and self._get_max_price() < self._get_price_low() or self.type_functional == 'technic' and self._get_max_price() < self._get_price_low() or self.type_functional == 'general' and self._get_max_price() < self._get_price_low() :
state_data = {'state':'budget','assigned_to':self._get_budget_manager()}
else:
| state_data = { 'state' : 'approval2' , 'assigned_to' : self . _get_employee ( ) . parent_id . id } | state_data = { 'state' : 'approval2' , 'assigned_to' : self . _get_employee ( ) . parent_id . user_id . id } | ADD_ATTRIBUTE_ACCESS | [["Move", ["attribute", 3, 61, 3, 91], ["attribute", 3, 61, 3, 91], 0], ["Insert", ["attribute", 3, 61, 3, 91], [".:.", "T"], 1], ["Insert", ["attribute", 3, 61, 3, 91], ["identifier:user_id", "T"], 2]] | sutanto62/estate@cf3c6616afea89f748c9425e1bd258fbecea9321 | [FIX] purchase_indonesia : bug user deletion in user in assigned_to | [
{
"sha": "a6a50bd4599eae71c083f98ed55b069864a6d731",
"filename": "purchase_indonesia/models/procur_request_link.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/cf3c6616afea89f748c9425e1bd258fbecea9321/purchase_indonesia%2Fmodels%2Fprocur_request_link.py",
"raw_url": "https://github.com/sutanto62/estate/raw/cf3c6616afea89f748c9425e1bd258fbecea9321/purchase_indonesia%2Fmodels%2Fprocur_request_link.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/purchase_indonesia%2Fmodels%2Fprocur_request_link.py?ref=cf3c6616afea89f748c9425e1bd258fbecea9321",
"patch": "@@ -744,7 +744,7 @@ def check_wkf_product_price(self):\n state_data = []\n \n if self._get_max_price() >= self._get_price_low() and self._get_employee().parent_id.id:\n- state_data = {'state':'approval2','assigned_to':self._get_employee().parent_id.id}\n+ state_data = {'state':'approval2','assigned_to':self._get_employee().parent_id.user_id.id}\n elif self._get_max_price() >= self._get_price_low() and not self._get_employee().parent_id.id or self.type_functional == 'agronomy' and self._get_max_price() < self._get_price_low() or self.type_functional == 'technic' and self._get_max_price() < self._get_price_low() or self.type_functional == 'general' and self._get_max_price() < self._get_price_low() :\n state_data = {'state':'budget','assigned_to':self._get_budget_manager()}\n else:"
}
] |
estate | 0d6abb0ea9c17d2d5ae3f4d7fb3b5ca87146662a | 9e885d5bf96811e0556f87f75ac7f6643e39ff78 | purchase_indonesia/models/inherit_purchase_tenders.py | https://github.com/sutanto62/estate | true | false | true | @@ -299,7 +299,7 @@ class InheritPurchaseTenders(models.Model):
supplier = res_partner.browse(cr, uid, partner_id, context=context)
res = {}
for requisition in self.browse(cr, uid, ids, context=context):
- if not requisition.multiple_rfq_per_supplier and supplier.id in filter(lambda x: x, [rfq.state not in ['cancel','received_force_done'] and rfq.partner_id.id or None for rfq in requisition.purchase_ids]):
+ if not requisition.multiple_rfq_per_supplier and supplier.id in filter(lambda x: x, [(rfq.state != 'cancel' or rfq.state == 'received_force_done') and rfq.partner_id.id or None for rfq in requisition.purchase_ids]):
error_msg = "You have already one purchase order for this partner, you must cancel this purchase order to create a new quotation."
raise exceptions.ValidationError(error_msg)
context.update({'mail_create_nolog': True})
| if not requisition . multiple_rfq_per_supplier and supplier . id in filter ( lambda x : x , [ rfq . state not in [ 'cancel' , 'received_force_done' ] and rfq . partner_id . id or None for rfq in requisition . purchase_ids ] ) : error_msg = "You have already one purchase order for this partner, you must cancel this purchase order to create a new quotation." raise exceptions . ValidationError ( error_msg ) | if not requisition . multiple_rfq_per_supplier and supplier . id in filter ( lambda x : x , [ ( rfq . state != 'cancel' or rfq . state == 'received_force_done' ) and rfq . partner_id . id or None for rfq in requisition . purchase_ids ] ) : error_msg = "You have already one purchase order for this partner, you must cancel this purchase order to create a new quotation." raise exceptions . ValidationError ( error_msg ) | CHANGE_BINARY_OPERAND | [["Insert", ["boolean_operator", 3, 98, 3, 169], ["parenthesized_expression", "N0"], 0], ["Insert", "N0", ["(:(", "T"], 0], ["Insert", "N0", ["boolean_operator", "N1"], 1], ["Insert", "N0", ["):)", "T"], 2], ["Insert", "N1", ["comparison_operator", "N2"], 0], ["Insert", "N1", ["or:or", "T"], 1], ["Insert", "N1", ["comparison_operator", "N3"], 2], ["Move", "N2", ["attribute", 3, 98, 3, 107], 0], ["Insert", "N2", ["!=:!=", "T"], 1], ["Insert", "N2", ["string:'cancel'", "T"], 2], ["Insert", "N3", ["attribute", "N4"], 0], ["Insert", "N3", ["==:==", "T"], 1], ["Move", "N3", ["string:'received_force_done'", 3, 125, 3, 146], 2], ["Insert", "N4", ["identifier:rfq", "T"], 0], ["Insert", "N4", [".:.", "T"], 1], ["Insert", "N4", ["identifier:state", "T"], 2], ["Delete", ["not:not", 3, 108, 3, 111]], ["Delete", ["in:in", 3, 112, 3, 114]], ["Delete", ["[:[", 3, 115, 3, 116]], ["Delete", ["string:'cancel'", 3, 116, 3, 124]], ["Delete", [",:,", 3, 124, 3, 125]], ["Delete", ["]:]", 3, 146, 3, 147]], ["Delete", ["list", 3, 115, 3, 147]], ["Delete", ["comparison_operator", 3, 98, 3, 147]]] | sutanto62/estate@0d6abb0ea9c17d2d5ae3f4d7fb3b5ca87146662a | [FIX] purchase_indonesia : FIX bug purchase tender backorder | [
{
"sha": "5df977b770b60f28f95eb82d2e817638d17b520b",
"filename": "purchase_indonesia/models/inherit_purchase_tenders.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/0d6abb0ea9c17d2d5ae3f4d7fb3b5ca87146662a/purchase_indonesia%2Fmodels%2Finherit_purchase_tenders.py",
"raw_url": "https://github.com/sutanto62/estate/raw/0d6abb0ea9c17d2d5ae3f4d7fb3b5ca87146662a/purchase_indonesia%2Fmodels%2Finherit_purchase_tenders.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/purchase_indonesia%2Fmodels%2Finherit_purchase_tenders.py?ref=0d6abb0ea9c17d2d5ae3f4d7fb3b5ca87146662a",
"patch": "@@ -299,7 +299,7 @@ def make_purchase_backorder(self, cr, uid, ids, partner_id, context=None):\n supplier = res_partner.browse(cr, uid, partner_id, context=context)\n res = {}\n for requisition in self.browse(cr, uid, ids, context=context):\n- if not requisition.multiple_rfq_per_supplier and supplier.id in filter(lambda x: x, [rfq.state not in ['cancel','received_force_done'] and rfq.partner_id.id or None for rfq in requisition.purchase_ids]):\n+ if not requisition.multiple_rfq_per_supplier and supplier.id in filter(lambda x: x, [(rfq.state != 'cancel' or rfq.state == 'received_force_done') and rfq.partner_id.id or None for rfq in requisition.purchase_ids]):\n error_msg = \"You have already one purchase order for this partner, you must cancel this purchase order to create a new quotation.\"\n raise exceptions.ValidationError(error_msg)\n context.update({'mail_create_nolog': True})"
}
] |
estate | 08343514b23d07b2cdd3e1e15e7df9d0550678b6 | 9fcde40ee97371aef324ea981d13cc94e3525d5c | purchase_indonesia/models/quotation_comparison_form.py | https://github.com/sutanto62/estate | true | false | true | @@ -124,7 +124,7 @@ class QuotationComparisonForm(models.Model):
@api.multi
def purchase_request_finance(self):
- return self.env.ref('purchase_request.group_purchase_request_finance_procurement', False).id
+ return self.env.ref('purchase_indonesia.group_purchase_request_finance_procurement', False).id
#Method Get user
@api.multi
| return self . env . ref ( 'purchase_request.group_purchase_request_finance_procurement' , False ) . id | return self . env . ref ( 'purchase_indonesia.group_purchase_request_finance_procurement' , False ) . id | CHANGE_STRING_LITERAL | [["Update", ["string:'purchase_request.group_purchase_request_finance_procurement'", 3, 29, 3, 90], "'purchase_indonesia.group_purchase_request_finance_procurement'"]] | sutanto62/estate@08343514b23d07b2cdd3e1e15e7df9d0550678b6 | [FIX] purchase_indonesia : AttributeError 'NoneType' object has no attribute 'id' | [
{
"sha": "05a50bde97b6ba9cd46aabe1cc847d69a3286cbc",
"filename": "purchase_indonesia/models/quotation_comparison_form.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/08343514b23d07b2cdd3e1e15e7df9d0550678b6/purchase_indonesia%2Fmodels%2Fquotation_comparison_form.py",
"raw_url": "https://github.com/sutanto62/estate/raw/08343514b23d07b2cdd3e1e15e7df9d0550678b6/purchase_indonesia%2Fmodels%2Fquotation_comparison_form.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/purchase_indonesia%2Fmodels%2Fquotation_comparison_form.py?ref=08343514b23d07b2cdd3e1e15e7df9d0550678b6",
"patch": "@@ -124,7 +124,7 @@ def purchase_request_manager(self):\n \n @api.multi\n def purchase_request_finance(self):\n- return self.env.ref('purchase_request.group_purchase_request_finance_procurement', False).id\n+ return self.env.ref('purchase_indonesia.group_purchase_request_finance_procurement', False).id\n \n #Method Get user\n @api.multi"
}
] |
estate | 9a2a29c020509ebefb3ad23589cad26e625962c7 | c578e62872ee5a992c4f30b8e6f82183fe315dee | estate_payroll/models/inherited_hr_payslip_run.py | https://github.com/sutanto62/estate | true | false | true | @@ -46,7 +46,7 @@ class PayslipRun(models.Model):
if self.division_id:
- res = self.env['stock.location'].search([('id', '=', self.division_id.location_id.id)])
+ res = self.estate_id = self.env['stock.location'].get_estate(self.division_id.id)
if res:
self.estate_id = res
| res = self . env [ 'stock.location' ] . search ( [ ( 'id' , '=' , self . division_id . location_id . id ) ] ) | res = self . estate_id = self . env [ 'stock.location' ] . get_estate ( self . division_id . id ) | SINGLE_STMT | [["Insert", ["assignment", 1, 13, 1, 100], ["assignment", "N0"], 2], ["Insert", "N0", ["attribute", "N1"], 0], ["Insert", "N0", ["=:=", "T"], 1], ["Move", "N0", ["call", 1, 19, 1, 100], 2], ["Insert", "N1", ["identifier:self", "T"], 0], ["Insert", "N1", [".:.", "T"], 1], ["Insert", "N1", ["identifier:estate_id", "T"], 2], ["Update", ["identifier:search", 1, 46, 1, 52], "get_estate"], ["Move", ["argument_list", 1, 52, 1, 100], ["attribute", 1, 66, 1, 94], 1], ["Move", ["argument_list", 1, 52, 1, 100], ["):)", 1, 97, 1, 98], 2], ["Update", ["identifier:location_id", 1, 83, 1, 94], "id"], ["Delete", ["[:[", 1, 53, 1, 54]], ["Delete", ["(:(", 1, 54, 1, 55]], ["Delete", ["string:'id'", 1, 55, 1, 59]], ["Delete", [",:,", 1, 59, 1, 60]], ["Delete", ["string:'='", 1, 61, 1, 64]], ["Delete", [",:,", 1, 64, 1, 65]], ["Delete", [".:.", 1, 94, 1, 95]], ["Delete", ["identifier:id", 1, 95, 1, 97]], ["Delete", ["attribute", 1, 66, 1, 97]], ["Delete", ["tuple", 1, 54, 1, 98]], ["Delete", ["]:]", 1, 98, 1, 99]], ["Delete", ["list", 1, 53, 1, 99]], ["Delete", ["):)", 1, 99, 1, 100]]] | sutanto62/estate@9a2a29c020509ebefb3ad23589cad26e625962c7 | [FIX] cannot create payslip by division. | [
{
"sha": "1918803de89be497c0bb72781b3318a44967b3f0",
"filename": "estate_payroll/models/inherited_hr_payslip_run.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/9a2a29c020509ebefb3ad23589cad26e625962c7/estate_payroll%2Fmodels%2Finherited_hr_payslip_run.py",
"raw_url": "https://github.com/sutanto62/estate/raw/9a2a29c020509ebefb3ad23589cad26e625962c7/estate_payroll%2Fmodels%2Finherited_hr_payslip_run.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate_payroll%2Fmodels%2Finherited_hr_payslip_run.py?ref=9a2a29c020509ebefb3ad23589cad26e625962c7",
"patch": "@@ -46,7 +46,7 @@ def _onchange_division_id(self):\n :return: first estate and set to estate_id\n \"\"\"\n if self.division_id:\n- res = self.env['stock.location'].search([('id', '=', self.division_id.location_id.id)])\n+ res = self.estate_id = self.env['stock.location'].get_estate(self.division_id.id)\n if res:\n self.estate_id = res\n "
}
] |
estate | 98c72865363c7a06555d0f321af972f58a80d1e8 | 326954ec1e890a76d9b4f9d9990c01a1b99a6229 | estate_payroll/wizard/inherited_hr_payroll_payslips_by_employees.py | https://github.com/sutanto62/estate | true | false | true | @@ -21,7 +21,7 @@ class PayslipEmployee(models.Model):
domain = [('state', '=', 'approved'),
('upkeep_date', '>=', payslip_run.date_start),
('upkeep_date', '<=', payslip_run.date_end),
- ('company_id', '=', payslip_run.company_id.id)]
+ ('employee_id.company_id', '=', payslip_run.company_id.id)]
if payslip_run.estate_id:
domain.append(('estate_id', '=', payslip_run.estate_id.id))
| domain = [ ( 'state' , '=' , 'approved' ) , ( 'upkeep_date' , '>=' , payslip_run . date_start ) , ( 'upkeep_date' , '<=' , payslip_run . date_end ) , ( 'company_id' , '=' , payslip_run . company_id . id ) ] | domain = [ ( 'state' , '=' , 'approved' ) , ( 'upkeep_date' , '>=' , payslip_run . date_start ) , ( 'upkeep_date' , '<=' , payslip_run . date_end ) , ( 'employee_id.company_id' , '=' , payslip_run . company_id . id ) ] | CHANGE_STRING_LITERAL | [["Update", ["string:'company_id'", 3, 20, 3, 32], "'employee_id.company_id'"]] | sutanto62/estate@98c72865363c7a06555d0f321af972f58a80d1e8 | [FIX] payslip team member not complete | [
{
"sha": "b3e13bb77f999670c7dc0f26b19a6f0d155069e8",
"filename": "estate_payroll/wizard/inherited_hr_payroll_payslips_by_employees.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/98c72865363c7a06555d0f321af972f58a80d1e8/estate_payroll%2Fwizard%2Finherited_hr_payroll_payslips_by_employees.py",
"raw_url": "https://github.com/sutanto62/estate/raw/98c72865363c7a06555d0f321af972f58a80d1e8/estate_payroll%2Fwizard%2Finherited_hr_payroll_payslips_by_employees.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/estate_payroll%2Fwizard%2Finherited_hr_payroll_payslips_by_employees.py?ref=98c72865363c7a06555d0f321af972f58a80d1e8",
"patch": "@@ -21,7 +21,7 @@ def get_upkeep(self):\n domain = [('state', '=', 'approved'),\n ('upkeep_date', '>=', payslip_run.date_start),\n ('upkeep_date', '<=', payslip_run.date_end),\n- ('company_id', '=', payslip_run.company_id.id)]\n+ ('employee_id.company_id', '=', payslip_run.company_id.id)]\n \n if payslip_run.estate_id:\n domain.append(('estate_id', '=', payslip_run.estate_id.id))"
}
] |
estate | 7bb0bc9f4331e0acb001d4769867715b71dd507e | ec99a2194bd1154bf21bbb720bac5ebfde2e75e1 | purchase_indonesia/models/inherit_purchase_tenders.py | https://github.com/sutanto62/estate | true | false | true | @@ -443,7 +443,7 @@ class InheritPurchaseTenders(models.Model):
res = {}
for requisition in self.browse(cr, uid, ids, context=context):
#todo use constraint for vendor.
- if not requisition.multiple_rfq_per_supplier and supplier.id in filter(lambda x: x, [rfq.validation_check_backorder == True and rfq.partner_id.id or None for rfq in requisition.purchase_ids]):
+ if not requisition.multiple_rfq_per_supplier and supplier.id in filter(lambda x: x, [((rfq.validation_check_backorder == True and rfq.state not in ('cancel')) or (rfq.validation_check_backorder == False and rfq.state in ('draft')))and rfq.partner_id.id or None for rfq in requisition.purchase_ids]):
error_msg = "You have already one purchase order for this partner, you must cancel this purchase order to create a new quotation."
raise exceptions.ValidationError(error_msg)
context.update({'mail_create_nolog': True})
| if not requisition . multiple_rfq_per_supplier and supplier . id in filter ( lambda x : x , [ rfq . validation_check_backorder == True and rfq . partner_id . id or None for rfq in requisition . purchase_ids ] ) : error_msg = "You have already one purchase order for this partner, you must cancel this purchase order to create a new quotation." raise exceptions . ValidationError ( error_msg ) | if not requisition . multiple_rfq_per_supplier and supplier . id in filter ( lambda x : x , [ ( ( rfq . validation_check_backorder == True and rfq . state not in ( 'cancel' ) ) or ( rfq . validation_check_backorder == False and rfq . state in ( 'draft' ) ) ) and rfq . partner_id . id or None for rfq in requisition . purchase_ids ] ) : error_msg = "You have already one purchase order for this partner, you must cancel this purchase order to create a new quotation." raise exceptions . ValidationError ( error_msg ) | CHANGE_BINARY_OPERAND | [["Insert", ["boolean_operator", 3, 98, 3, 158], ["parenthesized_expression", "N0"], 0], ["Insert", ["boolean_operator", 3, 98, 3, 158], ["and:and", "T"], 1], ["Insert", "N0", ["(:(", "T"], 0], ["Insert", "N0", ["boolean_operator", "N1"], 1], ["Insert", "N0", ["):)", "T"], 2], ["Insert", "N1", ["parenthesized_expression", "N2"], 0], ["Insert", "N1", ["or:or", "T"], 1], ["Insert", "N1", ["parenthesized_expression", "N3"], 2], ["Insert", "N2", ["(:(", "T"], 0], ["Insert", "N2", ["boolean_operator", "N4"], 1], ["Insert", "N2", ["):)", "T"], 2], ["Insert", "N3", ["(:(", "T"], 0], ["Insert", "N3", ["boolean_operator", "N5"], 1], ["Insert", "N3", ["):)", "T"], 2], ["Move", "N4", ["comparison_operator", 3, 98, 3, 136], 0], ["Move", "N4", ["and:and", 3, 137, 3, 140], 1], ["Insert", "N4", ["comparison_operator", "N6"], 2], ["Insert", "N5", ["comparison_operator", "N7"], 0], ["Insert", "N5", ["and:and", "T"], 1], ["Insert", "N5", ["comparison_operator", "N8"], 2], ["Insert", "N6", ["attribute", "N9"], 0], ["Insert", "N6", ["not:not", "T"], 1], ["Insert", "N6", ["in:in", "T"], 2], ["Insert", "N6", ["parenthesized_expression", "N10"], 3], ["Insert", "N7", ["attribute", "N11"], 0], ["Insert", "N7", ["==:==", "T"], 1], ["Insert", "N7", ["false:False", "T"], 2], ["Insert", "N8", ["attribute", "N12"], 0], ["Insert", "N8", ["in:in", "T"], 1], ["Insert", "N8", ["parenthesized_expression", "N13"], 2], ["Insert", "N9", ["identifier:rfq", "T"], 0], ["Insert", "N9", [".:.", "T"], 1], ["Insert", "N9", ["identifier:state", "T"], 2], ["Insert", "N10", ["(:(", "T"], 0], ["Insert", "N10", ["string:'cancel'", "T"], 1], ["Insert", "N10", ["):)", "T"], 2], ["Insert", "N11", ["identifier:rfq", "T"], 0], ["Insert", "N11", [".:.", "T"], 1], ["Insert", "N11", ["identifier:validation_check_backorder", "T"], 2], ["Insert", "N12", ["identifier:rfq", "T"], 0], ["Insert", "N12", [".:.", "T"], 1], ["Insert", "N12", ["identifier:state", "T"], 2], ["Insert", "N13", ["(:(", "T"], 0], ["Insert", "N13", ["string:'draft'", "T"], 1], ["Insert", "N13", ["):)", "T"], 2]] | sutanto62/estate@7bb0bc9f4331e0acb001d4769867715b71dd507e | [FIX] purchase_indonesia : fix constraint outstanding | [
{
"sha": "041a4949d941be8d100b75d9f7759e753db00c50",
"filename": "purchase_indonesia/models/inherit_purchase_tenders.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/7bb0bc9f4331e0acb001d4769867715b71dd507e/purchase_indonesia%2Fmodels%2Finherit_purchase_tenders.py",
"raw_url": "https://github.com/sutanto62/estate/raw/7bb0bc9f4331e0acb001d4769867715b71dd507e/purchase_indonesia%2Fmodels%2Finherit_purchase_tenders.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/purchase_indonesia%2Fmodels%2Finherit_purchase_tenders.py?ref=7bb0bc9f4331e0acb001d4769867715b71dd507e",
"patch": "@@ -443,7 +443,7 @@ def make_purchase_backorder(self, cr, uid, ids, partner_id, context=None):\n res = {}\n for requisition in self.browse(cr, uid, ids, context=context):\n #todo use constraint for vendor.\n- if not requisition.multiple_rfq_per_supplier and supplier.id in filter(lambda x: x, [rfq.validation_check_backorder == True and rfq.partner_id.id or None for rfq in requisition.purchase_ids]):\n+ if not requisition.multiple_rfq_per_supplier and supplier.id in filter(lambda x: x, [((rfq.validation_check_backorder == True and rfq.state not in ('cancel')) or (rfq.validation_check_backorder == False and rfq.state in ('draft')))and rfq.partner_id.id or None for rfq in requisition.purchase_ids]):\n error_msg = \"You have already one purchase order for this partner, you must cancel this purchase order to create a new quotation.\"\n raise exceptions.ValidationError(error_msg)\n context.update({'mail_create_nolog': True})"
}
] |
estate | 5a524ceb57b9d919c6e7ef52160109e85b10fcbf | 5e258485f968fef7ed18ab01022f87473750977f | purchase_indonesia/models/inherit_stock_picking.py | https://github.com/sutanto62/estate | true | false | true | @@ -74,7 +74,7 @@ class InheritStockPicking(models.Model):
arrAgronomy.append(deptgroupsrecord.id)
try:
- manager_estate = self.env['res.users'].search([('id','=',arrEstateManager[0]),('id','=',arrAgronomy[0])]).id
+ manager_estate = self.env['res.users'].search([('id','in',arrEstateManager),('id','in',arrAgronomy)]).id
except:
raise exceptions.ValidationError('User Role Estate Manager Not Found in User Access')
| manager_estate = self . env [ 'res.users' ] . search ( [ ( 'id' , '=' , arrEstateManager [ 0 ] ) , ( 'id' , '=' , arrAgronomy [ 0 ] ) ] ) . id | manager_estate = self . env [ 'res.users' ] . search ( [ ( 'id' , 'in' , arrEstateManager ) , ( 'id' , 'in' , arrAgronomy ) ] ) . id | SINGLE_STMT | [["Move", ["list", 3, 59, 3, 117], ["]:]", 3, 114, 3, 115], 4], ["Update", ["string:'='", 3, 66, 3, 69], "'in'"], ["Move", ["tuple", 3, 60, 3, 90], ["identifier:arrEstateManager", 3, 70, 3, 86], 5], ["Update", ["string:'='", 3, 97, 3, 100], "'in'"], ["Move", ["tuple", 3, 91, 3, 116], ["identifier:arrAgronomy", 3, 101, 3, 112], 5], ["Delete", ["[:[", 3, 86, 3, 87]], ["Delete", ["integer:0", 3, 87, 3, 88]], ["Delete", ["]:]", 3, 88, 3, 89]], ["Delete", ["subscript", 3, 70, 3, 89]], ["Delete", ["[:[", 3, 112, 3, 113]], ["Delete", ["integer:0", 3, 113, 3, 114]], ["Delete", ["subscript", 3, 101, 3, 115]], ["Delete", ["]:]", 3, 116, 3, 117]]] | sutanto62/estate@5a524ceb57b9d919c6e7ef52160109e85b10fcbf | [FIX] puchase_indonesia : FIX manager not show in stock picking | [
{
"sha": "087278b4a61b89917c0e48e0dee184bcc032ed8e",
"filename": "purchase_indonesia/models/inherit_stock_picking.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/sutanto62/estate/blob/5a524ceb57b9d919c6e7ef52160109e85b10fcbf/purchase_indonesia%2Fmodels%2Finherit_stock_picking.py",
"raw_url": "https://github.com/sutanto62/estate/raw/5a524ceb57b9d919c6e7ef52160109e85b10fcbf/purchase_indonesia%2Fmodels%2Finherit_stock_picking.py",
"contents_url": "https://api.github.com/repos/sutanto62/estate/contents/purchase_indonesia%2Fmodels%2Finherit_stock_picking.py?ref=5a524ceb57b9d919c6e7ef52160109e85b10fcbf",
"patch": "@@ -74,7 +74,7 @@ def _get_estate_manager(self):\n arrAgronomy.append(deptgroupsrecord.id)\n \n try:\n- manager_estate = self.env['res.users'].search([('id','=',arrEstateManager[0]),('id','=',arrAgronomy[0])]).id\n+ manager_estate = self.env['res.users'].search([('id','in',arrEstateManager),('id','in',arrAgronomy)]).id\n except:\n raise exceptions.ValidationError('User Role Estate Manager Not Found in User Access')\n "
}
] |
FunnyMenuSystem | a9160e098fcebfb5d881cac6fde47479d6454c00 | ec1506e8e6abea0de7fae363e8aa71182d59cf34 | MenuSystem.py | https://github.com/existenceexists/FunnyMenuSystem | true | false | true | @@ -26,7 +26,7 @@ def init():
screen = display.get_surface()
if not screen: raise AttributeError('set video before init MenuSystem')
screen_rect = screen.get_rect()
- DISPLAY=Surface((screen_rect.width,screen_rect.height))
+ DISPLAY=Surface((screen_rect.width,screen_rect.height),SRCALPHA).convert_alpha()
DISPLAY.fill(Color(0,0,0,0))
DISPLAYRECT = DISPLAY.get_rect()
| DISPLAY = Surface ( ( screen_rect . width , screen_rect . height ) ) | DISPLAY = Surface ( ( screen_rect . width , screen_rect . height ) , SRCALPHA ) . convert_alpha ( ) | SINGLE_STMT | [["Insert", ["call", 3, 13, 3, 60], ["attribute", "N0"], 0], ["Insert", ["call", 3, 13, 3, 60], ["argument_list", "N1"], 1], ["Insert", "N0", ["call", "N2"], 0], ["Insert", "N0", [".:.", "T"], 1], ["Insert", "N0", ["identifier:convert_alpha", "T"], 2], ["Insert", "N1", ["(:(", "T"], 0], ["Insert", "N1", ["):)", "T"], 1], ["Move", "N2", ["identifier:Surface", 3, 13, 3, 20], 0], ["Move", "N2", ["argument_list", 3, 20, 3, 60], 1], ["Insert", ["argument_list", 3, 20, 3, 60], [",:,", "T"], 2], ["Insert", ["argument_list", 3, 20, 3, 60], ["identifier:SRCALPHA", "T"], 3]] | existenceexists/FunnyMenuSystem@a9160e098fcebfb5d881cac6fde47479d6454c00 | Continue to try to fix a bug
The bug is:
he menu bar background is intended to be transparent
but the background stays the same as at the beginning
even if the background changes.
This tryout does not work. | [
{
"sha": "c9e1a0c6cb352a235dbedfbd7858a3de93d6c4ca",
"filename": "MenuSystem.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/existenceexists/FunnyMenuSystem/blob/a9160e098fcebfb5d881cac6fde47479d6454c00/MenuSystem.py",
"raw_url": "https://github.com/existenceexists/FunnyMenuSystem/raw/a9160e098fcebfb5d881cac6fde47479d6454c00/MenuSystem.py",
"contents_url": "https://api.github.com/repos/existenceexists/FunnyMenuSystem/contents/MenuSystem.py?ref=a9160e098fcebfb5d881cac6fde47479d6454c00",
"patch": "@@ -26,7 +26,7 @@ def init():\n screen = display.get_surface()\n if not screen: raise AttributeError('set video before init MenuSystem')\n screen_rect = screen.get_rect()\n- DISPLAY=Surface((screen_rect.width,screen_rect.height))\n+ DISPLAY=Surface((screen_rect.width,screen_rect.height),SRCALPHA).convert_alpha()\n DISPLAY.fill(Color(0,0,0,0))\n DISPLAYRECT = DISPLAY.get_rect()\n "
}
] |
redisearch-py | 3a39ba1ac6a1a47e68e3f898fa471e41dd1aa2a9 | 9c4bc81fdf9fdaa858329ae9515f27c941013070 | redisearch/auto_complete.py | https://github.com/wilrich-msft/redisearch-py | true | false | false | @@ -1,4 +1,4 @@
-import redis
+from redis import Redis, ConnectionPool
class Suggestion(object):
| import redis | from redis import Redis , ConnectionPool | SINGLE_STMT | [["Insert", ["module", 0, 1, 3, 0], ["import_from_statement", "N0"], 0], ["Insert", "N0", ["from:from", "T"], 0], ["Move", "N0", ["dotted_name", 0, 8, 0, 13], 1], ["Insert", "N0", ["import:import", "T"], 2], ["Insert", "N0", ["dotted_name", "N1"], 3], ["Insert", "N0", [",:,", "T"], 4], ["Insert", "N0", ["dotted_name", "N2"], 5], ["Insert", "N1", ["identifier:Redis", "T"], 0], ["Insert", "N2", ["identifier:ConnectionPool", "T"], 0], ["Delete", ["import:import", 0, 1, 0, 7]], ["Delete", ["import_statement", 0, 1, 0, 13]]] | wilrich-msft/redisearch-py@3a39ba1ac6a1a47e68e3f898fa471e41dd1aa2a9 | Adds explicit imported Redis class names
Without this, trying to create a new AutoCompleter w/o passing the connection argument errors as follows:
```
Traceback (most recent call last):
...
ac = AutoCompleter('wsac')
File "redacted/redisearch/auto_complete.py", line 40, in __init__
self.redis = conn if conn is not None else Redis(
NameError: global name 'Redis' is not defined
``` | [
{
"sha": "04b09da60f338abdc1e622d0407ef5fb71fb9430",
"filename": "redisearch/auto_complete.py",
"status": "modified",
"additions": 2,
"deletions": 2,
"changes": 4,
"blob_url": "https://github.com/wilrich-msft/redisearch-py/blob/3a39ba1ac6a1a47e68e3f898fa471e41dd1aa2a9/redisearch%2Fauto_complete.py",
"raw_url": "https://github.com/wilrich-msft/redisearch-py/raw/3a39ba1ac6a1a47e68e3f898fa471e41dd1aa2a9/redisearch%2Fauto_complete.py",
"contents_url": "https://api.github.com/repos/wilrich-msft/redisearch-py/contents/redisearch%2Fauto_complete.py?ref=3a39ba1ac6a1a47e68e3f898fa471e41dd1aa2a9",
"patch": "@@ -1,4 +1,4 @@\n-import redis\n+from redis import Redis, ConnectionPool\n \n class Suggestion(object):\n \"\"\"\n@@ -106,4 +106,4 @@ def get_suggestions(self, prefix, fuzzy = False, num = 10, with_scores = False):\n \n \n \n- \n\\ No newline at end of file\n+ "
}
] |
science | ac2190d1745681fbbee7ad9d5ce4cda55de74244 | 1685f6802db6ba72ad03a6a027ba6d88957904f0 | FField/ffield.py | https://github.com/SergeyBel/science | true | false | true | @@ -539,7 +539,7 @@ x^4 + x^3
def __div__(self,other):
assert self.field == other.field
- return FElement(self.field,self.field.Divide(self.f,other.f))
+ return FElement(self.field,self.field.DoDivide(self.f,other.f))
def __str__(self):
#return self.field.ShowPolynomial(self.f)
| return FElement ( self . field , self . field . Divide ( self . f , other . f ) ) | return FElement ( self . field , self . field . DoDivide ( self . f , other . f ) ) | WRONG_FUNCTION_NAME | [["Update", ["identifier:Divide", 3, 47, 3, 53], "DoDivide"]] | SergeyBel/science@ac2190d1745681fbbee7ad9d5ce4cda55de74244 | Fix ffield divide | [
{
"sha": "757f001c0c97fdc70e91106d0ada8d58db5ecccc",
"filename": "FField/ffield.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/SergeyBel/science/blob/ac2190d1745681fbbee7ad9d5ce4cda55de74244/FField%2Fffield.py",
"raw_url": "https://github.com/SergeyBel/science/raw/ac2190d1745681fbbee7ad9d5ce4cda55de74244/FField%2Fffield.py",
"contents_url": "https://api.github.com/repos/SergeyBel/science/contents/FField%2Fffield.py?ref=ac2190d1745681fbbee7ad9d5ce4cda55de74244",
"patch": "@@ -539,7 +539,7 @@ def __floordiv__(self,o):\n \n def __div__(self,other):\n assert self.field == other.field\n- return FElement(self.field,self.field.Divide(self.f,other.f))\n+ return FElement(self.field,self.field.DoDivide(self.f,other.f))\n \n def __str__(self):\n #return self.field.ShowPolynomial(self.f)"
}
] |
proxy_pool | a4bdc2264fb86e5e716e935c7ae1bb750ec0ac51 | ad6569da82de310d0f0b5171273c0768adaf9edd | Manager/ProxyManager.py | https://github.com/lycaste/proxy_pool | true | false | false | @@ -15,7 +15,7 @@ __author__ = 'JHao'
from DB.DbClient import DbClient
from Util.GetConfig import GetConfig
-from ProxyGetter.GetFreeProxy import GetFreeProxy
+from ProxyGetter.getFreeProxy import GetFreeProxy
class ProxyManager(object):
| from ProxyGetter . GetFreeProxy import GetFreeProxy | from ProxyGetter . getFreeProxy import GetFreeProxy | CHANGE_IDENTIFIER_USED | [["Update", ["identifier:GetFreeProxy", 3, 18, 3, 30], "getFreeProxy"]] | lycaste/proxy_pool@a4bdc2264fb86e5e716e935c7ae1bb750ec0ac51 | [fix] 拼写错误 | [
{
"sha": "a1096ca76de656631483a6766741a33e8087beeb",
"filename": "Manager/ProxyManager.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/lycaste/proxy_pool/blob/a4bdc2264fb86e5e716e935c7ae1bb750ec0ac51/Manager%2FProxyManager.py",
"raw_url": "https://github.com/lycaste/proxy_pool/raw/a4bdc2264fb86e5e716e935c7ae1bb750ec0ac51/Manager%2FProxyManager.py",
"contents_url": "https://api.github.com/repos/lycaste/proxy_pool/contents/Manager%2FProxyManager.py?ref=a4bdc2264fb86e5e716e935c7ae1bb750ec0ac51",
"patch": "@@ -15,7 +15,7 @@\n \n from DB.DbClient import DbClient\n from Util.GetConfig import GetConfig\n-from ProxyGetter.GetFreeProxy import GetFreeProxy\n+from ProxyGetter.getFreeProxy import GetFreeProxy\n \n \n class ProxyManager(object):"
}
] |
proxy_pool | e554a075949b8d7f13a245476fab9de327bcf75e | 96b5ddf8228c40c5270ab0372a29539331cddf57 | Util/GetConfig.py | https://github.com/lycaste/proxy_pool | true | false | true | @@ -25,7 +25,7 @@ class GetConfig(object):
def __init__(self):
self.pwd = os.path.split(os.path.realpath(__file__))[0]
- self.config_path = os.path.join(os.path.split(self.pwd)[0], 'config.ini')
+ self.config_path = os.path.join(os.path.split(self.pwd)[0], 'Config.ini')
self.config_file = ConfigParse()
self.config_file.read(self.config_path)
| self . config_path = os . path . join ( os . path . split ( self . pwd ) [ 0 ] , 'config.ini' ) | self . config_path = os . path . join ( os . path . split ( self . pwd ) [ 0 ] , 'Config.ini' ) | CHANGE_STRING_LITERAL | [["Update", ["string:'config.ini'", 3, 69, 3, 81], "'Config.ini'"]] | lycaste/proxy_pool@e554a075949b8d7f13a245476fab9de327bcf75e | [fix] fix Config.ini | [
{
"sha": "766a29d54c376f1a85949a6500c39b85f86d5f5b",
"filename": "Util/GetConfig.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/lycaste/proxy_pool/blob/e554a075949b8d7f13a245476fab9de327bcf75e/Util%2FGetConfig.py",
"raw_url": "https://github.com/lycaste/proxy_pool/raw/e554a075949b8d7f13a245476fab9de327bcf75e/Util%2FGetConfig.py",
"contents_url": "https://api.github.com/repos/lycaste/proxy_pool/contents/Util%2FGetConfig.py?ref=e554a075949b8d7f13a245476fab9de327bcf75e",
"patch": "@@ -25,7 +25,7 @@ class GetConfig(object):\n \n def __init__(self):\n self.pwd = os.path.split(os.path.realpath(__file__))[0]\n- self.config_path = os.path.join(os.path.split(self.pwd)[0], 'config.ini')\n+ self.config_path = os.path.join(os.path.split(self.pwd)[0], 'Config.ini')\n self.config_file = ConfigParse()\n self.config_file.read(self.config_path)\n "
}
] |
Unified-Cloud-API | a98b5bf76b65c6145faddad0b492e9e2edadb0b5 | 0e7acbf57f29ef1ab580b0480c3fc4980cc46aaf | custom_api.py | https://github.com/danielwwong/Unified-Cloud-API | true | false | true | @@ -319,7 +319,7 @@ def download_object(platform, file_source_bucket, destination_path, download_fil
shared.download_info = shared.download_info + 'document.getElementById("' + file_source_bucket[x] + '_' + download_file[x] + '_AWS").innerHTML = "Downloaded!";'
except Exception:
shared.download_info = shared.download_info + 'document.getElementById("' + file_source_bucket[x] + '_' + download_file[x] + '_AWS").innerHTML = "Error!";'
- return shared.download_info
+ return None
def delete_object(platform, file_source_bucket, delete_file):
# Google
| return shared . download_info | return None | SINGLE_STMT | [["Insert", ["return_statement", 3, 5, 3, 32], ["none:None", "T"], 1], ["Delete", ["identifier:shared", 3, 12, 3, 18]], ["Delete", [".:.", 3, 18, 3, 19]], ["Delete", ["identifier:download_info", 3, 19, 3, 32]], ["Delete", ["attribute", 3, 12, 3, 32]]] | danielwwong/Unified-Cloud-API@a98b5bf76b65c6145faddad0b492e9e2edadb0b5 | Minor Fixation | [
{
"sha": "90210924d1a804ad4c995fd17387a3fcdab95148",
"filename": "custom_api.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/danielwwong/Unified-Cloud-API/blob/a98b5bf76b65c6145faddad0b492e9e2edadb0b5/custom_api.py",
"raw_url": "https://github.com/danielwwong/Unified-Cloud-API/raw/a98b5bf76b65c6145faddad0b492e9e2edadb0b5/custom_api.py",
"contents_url": "https://api.github.com/repos/danielwwong/Unified-Cloud-API/contents/custom_api.py?ref=a98b5bf76b65c6145faddad0b492e9e2edadb0b5",
"patch": "@@ -319,7 +319,7 @@ def download_object(platform, file_source_bucket, destination_path, download_fil\n shared.download_info = shared.download_info + 'document.getElementById(\"' + file_source_bucket[x] + '_' + download_file[x] + '_AWS\").innerHTML = \"Downloaded!\";'\n except Exception:\n shared.download_info = shared.download_info + 'document.getElementById(\"' + file_source_bucket[x] + '_' + download_file[x] + '_AWS\").innerHTML = \"Error!\";'\n- return shared.download_info\n+ return None\n \n def delete_object(platform, file_source_bucket, delete_file):\n # Google"
}
] |
Unified-Cloud-API | dcba4d67dd9ed70e284dab4b693d254e076d5c6c | 5ce1f81e502ed2cb07f8a8e7d9e99adef071148f | main.py | https://github.com/danielwwong/Unified-Cloud-API | true | false | false | @@ -3,7 +3,7 @@ import shared
import custom_api
import threading
import time
-import scheduler
+from scheduler import scheduler
app = Flask(__name__)
backup_file_folder = '/Users/danielwong/'
| import scheduler | from scheduler import scheduler | SINGLE_STMT | [["Insert", ["module", 0, 1, 7, 0], ["import_from_statement", "N0"], 3], ["Insert", "N0", ["from:from", "T"], 0], ["Move", "N0", ["dotted_name", 3, 8, 3, 17], 1], ["Move", "N0", ["import:import", 3, 1, 3, 7], 2], ["Insert", "N0", ["dotted_name", "N1"], 3], ["Insert", "N1", ["identifier:scheduler", "T"], 0], ["Delete", ["import_statement", 3, 1, 3, 17]]] | danielwwong/Unified-Cloud-API@dcba4d67dd9ed70e284dab4b693d254e076d5c6c | Minor Fixation | [
{
"sha": "67c0e6e34c528d4a26ce977f0086e1f8d0fa36ef",
"filename": "main.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/danielwwong/Unified-Cloud-API/blob/dcba4d67dd9ed70e284dab4b693d254e076d5c6c/main.py",
"raw_url": "https://github.com/danielwwong/Unified-Cloud-API/raw/dcba4d67dd9ed70e284dab4b693d254e076d5c6c/main.py",
"contents_url": "https://api.github.com/repos/danielwwong/Unified-Cloud-API/contents/main.py?ref=dcba4d67dd9ed70e284dab4b693d254e076d5c6c",
"patch": "@@ -3,7 +3,7 @@\n import custom_api\n import threading\n import time\n-import scheduler\n+from scheduler import scheduler\n \n app = Flask(__name__)\n backup_file_folder = '/Users/danielwong/'"
}
] |
helpo | 894b7ad3e53770132b4bf40e84b53bbbdaab4e7c | d696bf85c14965f53d9f4af054c311a99b082853 | helpo-api/actividades/views.py | https://github.com/Jumpi96/helpo | true | false | true | @@ -219,7 +219,7 @@ class ConsultaEventosOrganizacionCreateReadView(ListCreateAPIView):
def get_queryset(self):
queryset = Evento.objects.all()
queryset = queryset.filter(fecha_hora_inicio__gte=datetime.today())
- queryset = queryset.order_by('-fecha_hora_inicio')
+ queryset = queryset.order_by('fecha_hora_inicio')
return queryset
class ConsultaEventosReadUpdateDeleteView(RetrieveUpdateDestroyAPIView):
| queryset = queryset . order_by ( '-fecha_hora_inicio' ) | queryset = queryset . order_by ( 'fecha_hora_inicio' ) | CHANGE_STRING_LITERAL | [["Update", ["string:'-fecha_hora_inicio'", 3, 38, 3, 58], "'fecha_hora_inicio'"]] | Jumpi96/helpo@894b7ad3e53770132b4bf40e84b53bbbdaab4e7c | Bug orden de eventos | [
{
"sha": "f2686e9c785191f535196fd93a787f1582d8dc83",
"filename": "helpo-api/actividades/views.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/Jumpi96/helpo/blob/894b7ad3e53770132b4bf40e84b53bbbdaab4e7c/helpo-api%2Factividades%2Fviews.py",
"raw_url": "https://github.com/Jumpi96/helpo/raw/894b7ad3e53770132b4bf40e84b53bbbdaab4e7c/helpo-api%2Factividades%2Fviews.py",
"contents_url": "https://api.github.com/repos/Jumpi96/helpo/contents/helpo-api%2Factividades%2Fviews.py?ref=894b7ad3e53770132b4bf40e84b53bbbdaab4e7c",
"patch": "@@ -219,7 +219,7 @@ class ConsultaEventosOrganizacionCreateReadView(ListCreateAPIView):\n def get_queryset(self):\n queryset = Evento.objects.all()\n queryset = queryset.filter(fecha_hora_inicio__gte=datetime.today())\n- queryset = queryset.order_by('-fecha_hora_inicio')\n+ queryset = queryset.order_by('fecha_hora_inicio')\n return queryset\n \n class ConsultaEventosReadUpdateDeleteView(RetrieveUpdateDestroyAPIView):"
}
] |
helpo | ccdec0e4f7de045a328f7297afe9e96c139556ed | ee655e5bcb44646743810c7952110a3f851b2be2 | helpo-api/actividades/serializers.py | https://github.com/Jumpi96/helpo | true | false | false | @@ -214,7 +214,7 @@ class ConsultaEventoSerializer(serializers.ModelSerializer):
model = Evento
fields = ('id', 'nombre', 'descripcion', 'fecha_hora_inicio',
'fecha_hora_fin', 'rubro', 'rubro_id', 'ubicacion', 'contacto', 'organizacion_id',
- 'necesidades', 'organizacion', 'voluntarios', 'comentarios')
+ 'necesidades', 'organizacion', 'voluntarios', 'comentarios', 'estado')
class EventoImagenSerializer(serializers.ModelSerializer):
| fields = ( 'id' , 'nombre' , 'descripcion' , 'fecha_hora_inicio' , 'fecha_hora_fin' , 'rubro' , 'rubro_id' , 'ubicacion' , 'contacto' , 'organizacion_id' , 'necesidades' , 'organizacion' , 'voluntarios' , 'comentarios' ) | fields = ( 'id' , 'nombre' , 'descripcion' , 'fecha_hora_inicio' , 'fecha_hora_fin' , 'rubro' , 'rubro_id' , 'ubicacion' , 'contacto' , 'organizacion_id' , 'necesidades' , 'organizacion' , 'voluntarios' , 'comentarios' , 'estado' ) | ADD_ELEMENTS_TO_ITERABLE | [["Move", [",:,", 1, 23, 1, 24], ["tuple", 1, 18, 3, 73], 21], ["Insert", ["tuple", 1, 18, 3, 73], [",:,", "T"], 2], ["Insert", ["tuple", 1, 18, 3, 73], [",:,", "T"], 29], ["Insert", ["tuple", 1, 18, 3, 73], ["string:'estado'", "T"], 30], ["Delete", [",:,", 3, 26, 3, 27]]] | Jumpi96/helpo@ccdec0e4f7de045a328f7297afe9e96c139556ed | Minor fix para mandar estado de evento en consultar eventos | [
{
"sha": "78b2daeb309738e33df2bb594c62acec3f5e4634",
"filename": "helpo-api/actividades/serializers.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/Jumpi96/helpo/blob/ccdec0e4f7de045a328f7297afe9e96c139556ed/helpo-api%2Factividades%2Fserializers.py",
"raw_url": "https://github.com/Jumpi96/helpo/raw/ccdec0e4f7de045a328f7297afe9e96c139556ed/helpo-api%2Factividades%2Fserializers.py",
"contents_url": "https://api.github.com/repos/Jumpi96/helpo/contents/helpo-api%2Factividades%2Fserializers.py?ref=ccdec0e4f7de045a328f7297afe9e96c139556ed",
"patch": "@@ -214,7 +214,7 @@ class Meta:\n model = Evento\n fields = ('id', 'nombre', 'descripcion', 'fecha_hora_inicio',\n 'fecha_hora_fin', 'rubro', 'rubro_id', 'ubicacion', 'contacto', 'organizacion_id',\n- 'necesidades', 'organizacion', 'voluntarios', 'comentarios')\n+ 'necesidades', 'organizacion', 'voluntarios', 'comentarios', 'estado')\n \n class EventoImagenSerializer(serializers.ModelSerializer):\n "
}
] |
helpo | 04d253a34acff2d58f9c8ecbcedb0435351a47da | e29c7cbdd1e158ccf870b51844506a0f2bd406ca | helpo-api/actividades/serializers.py | https://github.com/Jumpi96/helpo | true | false | false | @@ -250,7 +250,7 @@ class EventoImagenSerializer(serializers.ModelSerializer):
class Meta:
model = EventoImagen
- fields = ('id', 'url', 'evento', 'necesidades', 'organizacion', 'voluntarios', 'comentarios')
+ fields = ('id', 'url', 'evento')
class MensajeSerializer(serializers.ModelSerializer):
evento_id = serializers.PrimaryKeyRelatedField(
| fields = ( 'id' , 'url' , 'evento' , 'necesidades' , 'organizacion' , 'voluntarios' , 'comentarios' ) | fields = ( 'id' , 'url' , 'evento' ) | SINGLE_STMT | [["Delete", [",:,", 3, 40, 3, 41]], ["Delete", ["string:'necesidades'", 3, 42, 3, 55]], ["Delete", [",:,", 3, 55, 3, 56]], ["Delete", ["string:'organizacion'", 3, 57, 3, 71]], ["Delete", [",:,", 3, 71, 3, 72]], ["Delete", ["string:'voluntarios'", 3, 73, 3, 86]], ["Delete", [",:,", 3, 86, 3, 87]], ["Delete", ["string:'comentarios'", 3, 88, 3, 101]]] | Jumpi96/helpo@04d253a34acff2d58f9c8ecbcedb0435351a47da | Serializer fix | [
{
"sha": "0b857d0e582c272fa25dee9d38e8f5ab50ea35ca",
"filename": "helpo-api/actividades/serializers.py",
"status": "modified",
"additions": 1,
"deletions": 1,
"changes": 2,
"blob_url": "https://github.com/Jumpi96/helpo/blob/04d253a34acff2d58f9c8ecbcedb0435351a47da/helpo-api%2Factividades%2Fserializers.py",
"raw_url": "https://github.com/Jumpi96/helpo/raw/04d253a34acff2d58f9c8ecbcedb0435351a47da/helpo-api%2Factividades%2Fserializers.py",
"contents_url": "https://api.github.com/repos/Jumpi96/helpo/contents/helpo-api%2Factividades%2Fserializers.py?ref=04d253a34acff2d58f9c8ecbcedb0435351a47da",
"patch": "@@ -250,7 +250,7 @@ class EventoImagenSerializer(serializers.ModelSerializer):\n \n class Meta:\n model = EventoImagen\n- fields = ('id', 'url', 'evento', 'necesidades', 'organizacion', 'voluntarios', 'comentarios')\n+ fields = ('id', 'url', 'evento')\n \n class MensajeSerializer(serializers.ModelSerializer):\n evento_id = serializers.PrimaryKeyRelatedField("
}
] |