Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
db.execute('UPDATE names SET refcount=refcount+1 WHERE id=?', (name_id,))
# Break every once in a while - note that we can't yield
# right here because there's an active DB query.
processed += 1
if processed > 200:
queue.append((src_id, target_id, name_id))
break
await trio.hazmat.checkpoint()
# Make replication visible
self.db.execute('UPDATE contents SET parent_inode=? WHERE parent_inode=?',
(target_inode.id, tmp.id))
del self.inodes[tmp.id]
pyfuse3.invalidate_inode(target_inode.id)
log.debug('finished')