Sepiida

Latest version: v18.96

Safety actively analyzes 682387 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 10 of 31

12.1

----
Automatically convert content provided to storage.put if necessary. This will happen if you provide bytes directly to the function and request compression.

Also fix some unit tests I had broken in 12.0

12.0

----
Change the calling conventions for sepiida.storage.get() and put(). First, put() now takes a parameter, compress, which will compress the data on the fly and cause the mimetype for the data to be altered to show that it is compressed. In order to make that work, second, put() now takes in a file-like object that must implement read(). This causes the storage layer to no longer require reading the full block of data in to memory but instead allows for streaming it to woodhouse which can in turn stream to disk or to S3, as the situation may require. On the flip side, storage.get() will now return a context manager object (for automatic closing) which streams the data from woodhouse and decompresses it if necessary

Pre-12.0 code such as:


with open('foo', 'rb') as f:
content = f.read()
sepiida.storage.put(key, bucket, content, 'application/text')


should now look like


with open('foo', 'rb') as f:
sepiida.storage.put(key, bucket, f, 'application/text')


and code that looked like


content = sepiida.storage.get(key)


should now look like


with sepiida.storage.get(key) as f:
content = f.read()

11.4

----
Fix bug with leaking privileged_sessions. Before this change a privileged session would not
properly keep track of the fact that it had exited when an unhandled exception occurred within the privileged session
Now it does.

11.3

----
Allow for storage.put to indicate it is willing to overwrite the data. Normally we raise an exception because we expect data in storage to be stored by UUID and be immutable. Sometimes we want to be able to change it. We just have to opt-in to that behavior with overwrite=True

11.2

----
Log any permissions queries that take longer than a second. That's not long. It's a good threshold for part of the system that is so critical

11.1

----
Remove the 'queue' module. It makes us depend on boto because it was designed to work with SQS, but we don't do events with SQS and so it can reduce our dependency count to remove it

Page 10 of 31

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.