更改目标分支以提交

时间:2019-02-20 09:35:50

标签: gerrit

我可以更改Gerrit上的代码审查的“目标分支”吗?例如,传入的更改请求被配置为合并到for row in df.itertuples(index=True, name='Pandas'): variable=getattr(row, "c1") df.loc[{variable}]=1 Error what I Am getting is: --------------------------------------------------------------------------- KeyError Traceback (most recent call last) <ipython-input-226-e67900963f1d> in <module> 7 for row in df.itertuples(index=True, name='Pandas'): 8 variable=getattr(row, "c1") ----> 9 df.loc[{variable}]=1 10 11 df /usr/local/lib/python3.6/dist-packages/pandas/core/indexing.py in __setitem__(self, key, value) 187 else: 188 key = com.apply_if_callable(key, self.obj) --> 189 indexer = self._get_setitem_indexer(key) 190 self._setitem_with_indexer(indexer, value) 191 /usr/local/lib/python3.6/dist-packages/pandas/core/indexing.py in _get_setitem_indexer(self, key) 173 174 try: --> 175 return self._convert_to_indexer(key, is_setter=True) 176 except TypeError as e: 177 /usr/local/lib/python3.6/dist-packages/pandas/core/indexing.py in _convert_to_indexer(self, obj, axis, is_setter, raise_missing) 1352 kwargs = {'raise_missing': True if is_setter else 1353 raise_missing} -> 1354 return self._get_listlike_indexer(obj, axis, **kwargs)[1] 1355 else: 1356 try: /usr/local/lib/python3.6/dist-packages/pandas/core/indexing.py in _get_listlike_indexer(self, key, axis, raise_missing) 1159 self._validate_read_indexer(keyarr, indexer, 1160 o._get_axis_number(axis), -> 1161 raise_missing=raise_missing) 1162 return keyarr, indexer 1163 /usr/local/lib/python3.6/dist-packages/pandas/core/indexing.py in _validate_read_indexer(self, key, indexer, axis, raise_missing) 1244 raise KeyError( 1245 u"None of [{key}] are in the [{axis}]".format( -> 1246 key=key, axis=self.obj._get_axis_name(axis))) 1247 1248 # We (temporarily) allow for some missing keys with .loc, except in KeyError: "None of [Int64Index([10], dtype='int64')] are in the [index]" 中,但是我看到这会破坏事情。我可以更改该更改请求的目标分支吗?

1 个答案:

答案 0 :(得分:1)

您不能更改目标分支。

您需要使用Gerrit UI中的相应按钮将更改樱桃选择到其他分支,或将其他更改手动推送到Gerrit,然后您可以放弃一个。