Skip to content

Commit 2faba5b

Browse files
authored
Merge pull request #142 from AllenNeuralDynamics/release-v0.17.1
Release v0.17.1
2 parents 53f2ab9 + 29c5245 commit 2faba5b

File tree

6 files changed

+153
-31
lines changed

6 files changed

+153
-31
lines changed

.env.template

Lines changed: 0 additions & 9 deletions
This file was deleted.

CODE_OF_CONDUCT.md

Lines changed: 133 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,133 @@
1+
2+
# Contributor Covenant Code of Conduct
3+
4+
## Our Pledge
5+
6+
We as members, contributors, and leaders pledge to make participation in our
7+
community a harassment-free experience for everyone, regardless of age, body
8+
size, visible or invisible disability, ethnicity, sex characteristics, gender
9+
identity and expression, level of experience, education, socio-economic status,
10+
nationality, personal appearance, race, religion, or sexual identity
11+
and orientation.
12+
13+
We pledge to act and interact in ways that contribute to an open, welcoming,
14+
diverse, inclusive, and healthy community.
15+
16+
## Our Standards
17+
18+
Examples of behavior that contributes to a positive environment for our
19+
community include:
20+
21+
* Demonstrating empathy and kindness toward other people
22+
* Being respectful of differing opinions, viewpoints, and experiences
23+
* Giving and gracefully accepting constructive feedback
24+
* Accepting responsibility and apologizing to those affected by our mistakes,
25+
and learning from the experience
26+
* Focusing on what is best not just for us as individuals, but for the
27+
overall community
28+
29+
Examples of unacceptable behavior include:
30+
31+
* The use of sexualized language or imagery, and sexual attention or
32+
advances of any kind
33+
* Trolling, insulting or derogatory comments, and personal or political attacks
34+
* Public or private harassment
35+
* Publishing others' private information, such as a physical or email
36+
address, without their explicit permission
37+
* Other conduct which could reasonably be considered inappropriate in a
38+
professional setting
39+
40+
## Enforcement Responsibilities
41+
42+
Community leaders are responsible for clarifying and enforcing our standards of
43+
acceptable behavior and will take appropriate and fair corrective action in
44+
response to any behavior that they deem inappropriate, threatening, offensive,
45+
or harmful.
46+
47+
Community leaders have the right and responsibility to remove, edit, or reject
48+
comments, commits, code, wiki edits, issues, and other contributions that are
49+
not aligned to this Code of Conduct, and will communicate reasons for moderation
50+
decisions when appropriate.
51+
52+
## Scope
53+
54+
This Code of Conduct applies within all community spaces, and also applies when
55+
an individual is officially representing the community in public spaces.
56+
Examples of representing our community include using an official email address,
57+
posting via an official social media account, or acting as an appointed
58+
representative at an online or offline event.
59+
60+
## Enforcement
61+
62+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
63+
reported to the community leaders responsible for enforcement at
64+
65+
All complaints will be reviewed and investigated promptly and fairly.
66+
67+
All community leaders are obligated to respect the privacy and security of the
68+
reporter of any incident.
69+
70+
## Enforcement Guidelines
71+
72+
Community leaders will follow these Community Impact Guidelines in determining
73+
the consequences for any action they deem in violation of this Code of Conduct:
74+
75+
### 1. Correction
76+
77+
**Community Impact**: Use of inappropriate language or other behavior deemed
78+
unprofessional or unwelcome in the community.
79+
80+
**Consequence**: A private, written warning from community leaders, providing
81+
clarity around the nature of the violation and an explanation of why the
82+
behavior was inappropriate. A public apology may be requested.
83+
84+
### 2. Warning
85+
86+
**Community Impact**: A violation through a single incident or series
87+
of actions.
88+
89+
**Consequence**: A warning with consequences for continued behavior. No
90+
interaction with the people involved, including unsolicited interaction with
91+
those enforcing the Code of Conduct, for a specified period of time. This
92+
includes avoiding interactions in community spaces as well as external channels
93+
like social media. Violating these terms may lead to a temporary or
94+
permanent ban.
95+
96+
### 3. Temporary Ban
97+
98+
**Community Impact**: A serious violation of community standards, including
99+
sustained inappropriate behavior.
100+
101+
**Consequence**: A temporary ban from any sort of interaction or public
102+
communication with the community for a specified period of time. No public or
103+
private interaction with the people involved, including unsolicited interaction
104+
with those enforcing the Code of Conduct, is allowed during this period.
105+
Violating these terms may lead to a permanent ban.
106+
107+
### 4. Permanent Ban
108+
109+
**Community Impact**: Demonstrating a pattern of violation of community
110+
standards, including sustained inappropriate behavior, harassment of an
111+
individual, or aggression toward or disparagement of classes of individuals.
112+
113+
**Consequence**: A permanent ban from any sort of public interaction within
114+
the community.
115+
116+
## Attribution
117+
118+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
119+
version 2.0, available at
120+
[https://www.contributor-covenant.org/version/2/0/code_of_conduct.html][v2.0].
121+
122+
Community Impact Guidelines were inspired by
123+
[Mozilla's code of conduct enforcement ladder][Mozilla CoC].
124+
125+
For answers to common questions about this code of conduct, see the FAQ at
126+
[https://www.contributor-covenant.org/faq][FAQ]. Translations are available
127+
at [https://www.contributor-covenant.org/translations][translations].
128+
129+
[homepage]: https://www.contributor-covenant.org
130+
[v2.0]: https://www.contributor-covenant.org/version/2/0/code_of_conduct.html
131+
[Mozilla CoC]: https://github.com/mozilla/diversity
132+
[FAQ]: https://www.contributor-covenant.org/faq
133+
[translations]: https://www.contributor-covenant.org/translations

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@ AIND metadata for data assets is stored in various places and must be
1010
kept in sync:
1111

1212
1. **S3 buckets** store raw metadata files, including the ``metadata.nd.json``.
13-
2. A **document database (DocDB)** contains unstructured json
13+
2. A **document database (DocDB)** contains unstructured JSON
1414
documents describing the ``metadata.nd.json`` for a data asset.
15-
3. **Code Ocean**: data assets are mounted as CodeOcean data assets.
15+
3. **Code Ocean**: data assets are mounted as Code Ocean data assets.
1616
Processed results are also stored in an internal Code Ocean bucket.
1717

18-
We have automated jobs to keep changes in DocDB and S3 in sync.
18+
We have automated jobs to keep changes in DocDB, S3 and Code Ocean in sync.
1919
This repository contains the code for these index jobs.
2020

2121
More information including a user guide and contributor guidelines can be found at [readthedocs](https://aind-data-asset-indexer.readthedocs.io).

docs/source/Contributing.rst

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ For development,
3232
off of ``main``
3333

3434
Consult the `Branches and Pull Requests <#branches-and-pull-requests>`__
35-
and `Release Cycles <#release-cycles>`__ for more details.
35+
and `Release Cycles <#release-cycles>`__ sections for more details.
3636

3737
From the root directory, run:
3838

@@ -47,14 +47,13 @@ to install the relevant code for development.
4747
Running indexer jobs locally
4848
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4949

50-
5150
The jobs are intended to be run as scheduled AWS ECS tasks.
5251
The job settings are stored in AWS Parameter Store.
5352

5453
If you wish to run the jobs locally, follow these steps:
5554

5655
1. Ensure the correct ``AWS_PROFILE`` is exported. This profile will be used to
57-
read/write from S3 bucketsand DocumentDB (through the API Gateway).
56+
read/write from S3 buckets and DocumentDB (through the API Gateway).
5857

5958
2. For the `IndexAindBucketsJob`, you will need to set the ``PARAM_STORE_NAME``.
6059
Then, run the following:
@@ -206,7 +205,7 @@ Hotfixes
206205
~~~~~~~~
207206

208207
- A ``hotfix`` branch is created off of ``main``
209-
- A Pull Request into is ``main`` is opened, reviewed, and merged into
208+
- A Pull Request into ``main`` is opened, reviewed, and merged into
210209
``main``
211210
- A new ``tag`` with a patch bump is created, and a new ``release`` is
212211
deployed
@@ -235,7 +234,7 @@ Pre-release checklist
235234
~~~~~~~~~~~~~~~~~~~~~
236235

237236
- ☐ Increment ``__version__`` in
238-
``aind_data_asset-indexer/__init__.py`` file
237+
``aind_data_asset_indexer/__init__.py`` file
239238
- ☐ Run linters, unit tests, and integration tests
240239
- ☐ Verify code is deployed and tested in test environment
241240
- ☐ Update examples

docs/source/UserGuide.rst

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -20,35 +20,34 @@ kept in sync:
2020
all core schema fields.
2121
- ``original_metadata/{core_schema}.json``: a copy of each
2222
core schema file as it was originally uploaded to S3.
23-
2. A **document database (DocDB)** contains unstructured json
23+
2. A **document database (DocDB)** contains unstructured JSON
2424
documents describing the ``metadata.nd.json`` for a data asset.
25-
3. **Code Ocean**: data assets are mounted as CodeOcean data asssets.
25+
3. **Code Ocean**: data assets are mounted as Code Ocean data assets.
2626
Processed results are also stored in an internal Code Ocean bucket.
2727

2828
Once the data is initially uploaded, the DocDB is assumed to be the
2929
source of truth for metadata. All updates to existing metadata should
3030
be made in the DocDB.
3131

32-
We have automated jobs to keep changes in DocDB and S3 in sync.
32+
We have automated jobs to keep changes in DocDB, S3, and Code Ocean in sync.
3333
This repository contains the code for these index jobs:
3434

3535
1. `AindIndexBucketJob <#aindindexbucketjob>`__: Syncs changes in S3 and DocDB.
36-
2. `CodeOceanIndexBucketJob <#codeoceanindexbucketjob>`__: Syncs changes in CodeOcean and DocDB.
36+
2. `CodeOceanIndexBucketJob <#codeoceanindexbucketjob>`__: Syncs changes in Code Ocean and DocDB.
3737

3838

3939
AindIndexBucketJob
4040
------------------
4141

4242
The `AindIndexBucketJob` handles syncing changes from DocDB to S3 for a
43-
particular S3 bucket. There is a `IndexAindBucketsJob` wrapper job that
43+
particular S3 bucket. There is an `IndexAindBucketsJob` wrapper job that
4444
runs the `AindIndexBucketJob` for a list of buckets.
4545

46-
4746
The workflow is generally as follows:
4847

4948
1. Paginate DocDB to get records for a particular bucket.
5049

51-
- Typically we filter for records that have been updated in the last
50+
- Typically, we filter for records that have been updated in the last
5251
14 days.
5352
2. For each DocDB record, process by syncing any changes in DocDB to S3.
5453

@@ -66,7 +65,7 @@ The workflow is generally as follows:
6665
- If the metadata record exists in S3 but not in DocDB, copy it
6766
to DocDB.
6867
- If the metadata record does not exist in S3, create it and save
69-
it to S3. Assume a lambda function will move it over to DocDB.
68+
it to S3. Assume a Lambda function will move it over to DocDB.
7069
- In both cases above, ensure the original metadata folder and core
7170
files are in sync with the metadata.nd.json file.
7271

@@ -77,16 +76,16 @@ CodeOceanIndexBucketJob
7776
-----------------------
7877

7978
The `CodeOceanIndexBucketJob` updates the external links for DocDB records
80-
with their CO data asset ids and indexes Code Ocean (CO) processed results.
79+
with their Code Ocean (CO) data asset IDs and indexes CO processed results.
8180

8281
The workflow is generally as follows:
8382

8483
1. For records in AIND buckets, update the external links with CO data
85-
asset ids if needed.
84+
asset IDs if needed.
8685

87-
- Retrieve a list of CO data asset ids and locations
88-
- Paginate through docdb records where the location does not match
89-
internal CO bucket
86+
- Retrieve a list of CO data asset IDs and locations.
87+
- Paginate through DocDB records where the location does not match
88+
the internal CO bucket.
9089
- Add or remove the external links from the DocDB record as needed.
9190
2. Index CO processed results from the CO internal bucket.
9291

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
"""Package"""
22

3-
__version__ = "0.17.0"
3+
__version__ = "0.17.1"

0 commit comments

Comments
 (0)