Skip to content

2.7.0

Compare
Choose a tag to compare
@nathankw nathankw released this 12 Apr 02:52
· 35 commits to master since this release

Updates:

  • Updated connection.Connection.before_post_file() such that it will calculate file_size now (in addition to md5sum), and that whenever the md5sum needs to be set, the file_size will also be set.

Novelties:

  • Added connection.Connection.get_biosample_type() to aid in searching for a BiosampleType with a given classification and term_id or term_name.
  • Added function utils.orient_jpg() which fixes misoriented images, rotating them as necessary. connection.Connection.set_attachment() now calls this if the input file is a JPEG or TIFF.
  • Added aws_storage.py that includes two classes: S3Upload that simplifies the process of uploading files to a bucket in a specific location with the specified acl, and S3Object which represents an object in a S3 bucket and is internally used for calculating the md5sum and file size when submitting S3 objects to the ENCODE Portal.
  • Added utils.url_join() which is now used for property joining URL paths, rather than incorrectly with os.path.join since that doesn't construct the right paths on Windows systems.
  • Added new function in profiles.py called remove_duplicate_associations(). This is called when patching a record so that EU can detect and remove duplicates in array values (when extending arrays).

Bug fixes

  • Added patch to profiles.Profile._set_profile_id() to include exceptional cases, such as antibody_lot records using @id values like '/antibodies/ENCAB719MQZ' instead of the expected '/antibody_lots/ENCAB719MQZ'.