encode_utils¶
An API and scripts for submitting datasetss to the ENCODE Portal.
-
encode_utils.AWARD_PROP_NAME= 'award'¶ The award property name that is common to all ENCODE Portal object profiles.
-
encode_utils.ALIAS_PROP_NAME= 'aliases'¶ The aliases property name that is common to almost all ENCODE Portal object profiles. Notably, the following profiles lack this property as of 2018-04-03: [‘access_key_admin’, ‘publication’, ‘award’, ‘organism’, ‘page’, ‘image’, ‘user’, ‘lab’]
-
encode_utils.LAB_PROP_NAME= 'lab'¶ The lab property name that is common to all ENCODE Portal object profiles.
-
encode_utils.LAB= {}¶ dict. Stores the lab property to the value of the environment variable DCC_LAB to serve as the default lab when submitting an object to the Portal.
encode_utils.connection.Connection.post()will use this default if this property doesn’t appear in the payload.
-
encode_utils.LAB_PREFIX= ''¶ str. Stores the prefix to add to each record alias when doing a POST operation. Most profiles have an ‘alias’ key, which stores a list of alias names that are useful to the lab. When POSTING objects to the Portal, these aliases must be prefixed with the lab name and end with a colon, and this configuration variable stores that prefix value.
-
encode_utils.AWARD= {}¶ dict. Stores the award property to the value of the environment variable DCC_AWARD to act as the default award when submiting an object to the Portal.
encode_utils.connection.Connection.post()will use this default if this property doesn’t appear in the payload, and the profile at hand isn’t a member of the listencode_utils.utils.Profile.AWARDLESS_PROFILES.
-
encode_utils.PROFILES_URL= 'profiles'¶ The relative ENCODE Portal URL that points to all the profiles (schemas).
-
encode_utils.DCC_MODES= {'dev': {'url': 'https://test.encodedcc.org'}, 'prod': {'url': 'https://www.encodeproject.org'}}¶ A hash of known hosts one can connect to, where the key can be passed to the dcc_mode argument when instantiating the connection.Connection class.
-
encode_utils.TIMEOUT= 60¶ The timeout in seconds when making HTTP requests via the
requestsmodule.
-
encode_utils.DEBUG_LOGGER_NAME= 'eu_debug'¶ The name of the debug
logginginstance.
-
encode_utils.ERROR_LOGGER_NAME= 'eu_error'¶ The name of the error
logginginstance created inencode_utils.connection.Connection(), and referenced elsewhere.
-
encode_utils.POST_LOGGER_NAME= 'eu_post'¶ The name of the POST
logginginstance created inencode_utils.connection.Connection(), and referenced elsewhere.
-
encode_utils.debug_logger= <Logger eu_debug (DEBUG)>¶ A
logginginstance that logs all messages sent to it to STDOUT.
-
encode_utils.error_logger= <Logger eu_error (ERROR)>¶ A
logginginstance that accepts messages at the ERROR level.