Auditing the state of the revision's metadata field, we use the field metadata to convey multiple meanings.
It'd be great we have a look at how we want to set that.
Understanding that this should not be there (but it is for now).
## current reimplementation for gnu/pypi/npm (T1389)
```
'metadata': {
'intrinsic_metadata': intrinsic_metadata, # raw metadata parsed out of internal file (PKG-INFO, package.json)
'original_artifact': a_metadata, # extrinsic artifact metadata, raw data from api/provider
'hashes_artifact': a_c_metadata, # extra artifact metadata computed by us
},
```
## in-production pypi
```
'metadata': {
'original_artifact': artifact, # extrinsic metadata about the release artifact to download
'project': project_info, # extrinsic metadata about the project
},
```
## in-production npm
```
'metadata': {
'package_source': package_source_data,
'package': package_metadata,
},
```
## mercurial
all intrinsic metadata:
```
'node': hash_to_hex(header['node']), # -> this probably should be in extra headers, must check if it is or not (unsure)
'extra_headers': [
['time_offset_seconds',
str(commit['time_offset_seconds']).encode('utf-8')],
] + extra_meta
```
## git
```
ret['metadata'] = {
'extra_headers': git_metadata, # intrinsic metadata
}
```
## svn
all intrinsic metadata
```
'extra_headers': [
['svn_repo_uuid', repo_uuid],
['svn_revision', str(rev).encode('utf-8')]
]
```
## tar
Those are computations and extrinsic metadata:
```
'metadata': {
'original_artifact': {
'name': filename
'archive_type': 'zip' || 'tar'
**hashes
}
}
```
## debian
```
'metadata': {
'original_artifact': [{
name,
**hashes,
}], # <- built from intrinsic metadata parsed out of *.dsc
package_info: # <- built from intrinsic metadata parsed out of debian/changelog
}
```