(self, data, block=True, timeout=None)
| 139 | return data_buffer |
| 140 | |
| 141 | def put(self, data, block=True, timeout=None): |
| 142 | if self.client is None: |
| 143 | self.client = plasma.connect(self.socket_name) |
| 144 | try: |
| 145 | object_id = self.client.put(data) |
| 146 | except plasma.PlasmaStoreFull: |
| 147 | where = "in DataLoader Plasma Store Put Full" |
| 148 | exc_type = "PlasmaStoreFull" |
| 149 | error = self.get_error(exc_type, where) |
| 150 | object_id = self.client.put((error,)) |
| 151 | |
| 152 | try: |
| 153 | self.queue.put(object_id, block, timeout) |
| 154 | except queue.Full: |
| 155 | self.client.delete([object_id]) |
| 156 | raise queue.Full |
| 157 | |
| 158 | def get(self, block=True, timeout=None): |
| 159 | if self.client is None: |
no test coverage detected