(self, pool_name_or_id, data, branch_name='main',
commit_author=getpass.getuser(), commit_body='')
| 45 | self.__raise_for_status(r) |
| 46 | |
| 47 | def load(self, pool_name_or_id, data, branch_name='main', |
| 48 | commit_author=getpass.getuser(), commit_body=''): |
| 49 | pool = urllib.parse.quote(pool_name_or_id, safe='') |
| 50 | branch = urllib.parse.quote(branch_name, safe='') |
| 51 | url = self.base_url + '/pool/' + pool + '/branch/' + branch |
| 52 | commit_message = {'author': commit_author, 'body': commit_body} |
| 53 | headers = {'SuperDB-Commit': json.dumps(commit_message)} |
| 54 | r = self.session.post(url, headers=headers, data=data) |
| 55 | self.__raise_for_status(r) |
| 56 | |
| 57 | def query(self, query): |
| 58 | r = self.query_raw(query) |
nothing calls this directly
no test coverage detected