Skip to content

Commit

Permalink
Merge branch 'develop' into feat/add-inheritance-view
Browse files Browse the repository at this point in the history
  • Loading branch information
jpower432 authored Nov 4, 2023
2 parents b1f601d + 5ac3067 commit 5319028
Show file tree
Hide file tree
Showing 28 changed files with 116,167 additions and 47 deletions.
20 changes: 20 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,26 @@

<!--next-version-placeholder-->

## v2.4.0 (2023-10-26)
### Feature
* Adding validate template type to author docs command ([#1465](https://github.com/IBM/compliance-trestle/issues/1465)) ([`5289f51`](https://github.com/IBM/compliance-trestle/commit/5289f516e9710361e0dc391cefd979b5e2d46ed0))

### Fix
* Upgrade urllib version to fix vulnerability ([#1472](https://github.com/IBM/compliance-trestle/issues/1472)) ([`e9d4175`](https://github.com/IBM/compliance-trestle/commit/e9d4175fabd015ada6e8cdd26450c454ad83fbe8))
* Improve bad property error message by including csv row number ([#1466](https://github.com/IBM/compliance-trestle/issues/1466)) ([`ab97beb`](https://github.com/IBM/compliance-trestle/commit/ab97beb2367112e9e68fb258af6dc2c75d909279))
* Cryptic error message + feat: # indicates comment column ([#1459](https://github.com/IBM/compliance-trestle/issues/1459)) ([`45eda01`](https://github.com/IBM/compliance-trestle/commit/45eda015751d2f9121e14fe609b14acd890440fd))
* Update community call information ([#1444](https://github.com/IBM/compliance-trestle/issues/1444)) ([`5a03d06`](https://github.com/IBM/compliance-trestle/commit/5a03d06783fff8db4bf402b1e21acb99fd485454))

### Documentation
* Updating vtt documentation for trestle author docs ([#1471](https://github.com/IBM/compliance-trestle/issues/1471)) ([`63d436a`](https://github.com/IBM/compliance-trestle/commit/63d436a7752e50ef0c52c93cbab36f4c1fc16748))

## v2.3.1 (2023-09-20)
### Fix
* Improper indentation structure validation not working ([#1451](https://github.com/IBM/compliance-trestle/issues/1451)) ([`2e6936a`](https://github.com/IBM/compliance-trestle/commit/2e6936a4705251fd8412fd67163a7cd9d801a4b8))
* Fixing typo in encoding name ([#1448](https://github.com/IBM/compliance-trestle/issues/1448)) ([`bdf60b2`](https://github.com/IBM/compliance-trestle/commit/bdf60b26075f7250bcdbbe08745630b27042ad74))
* Parameter aggregation fix ([#1443](https://github.com/IBM/compliance-trestle/issues/1443)) ([`dd9e3bc`](https://github.com/IBM/compliance-trestle/commit/dd9e3bc2ebaeab23f3c4fc0647ec3942d38bed16))
* Prevent duplicates in set-parameters ([#1450](https://github.com/IBM/compliance-trestle/issues/1450)) ([`62e2f05`](https://github.com/IBM/compliance-trestle/commit/62e2f059dd2ae08616895ebdfd6e37258483019d))

## v2.3.0 (2023-09-06)
### Feature
* Extend multiple templates validation to trestle author folders ([#1430](https://github.com/IBM/compliance-trestle/issues/1430)) ([`c7bef58`](https://github.com/IBM/compliance-trestle/commit/c7bef589a6e671b96170e93feb88c6436a094da6))
Expand Down
41 changes: 21 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,28 +92,29 @@ The community call will happen every 2 week(s) on Tuesday at 10.00am EST.\
Meeting information:

```
You have been invited to Attend at the following event :
Compliance Trestle Community Call
Every 2nd week on Tuesday; from June 27th, 2023 at 10:00 am EST for 0.5 hour
To join, select from the following options:
1) Web Browser
a) https://primetime.bluejeans.com/a2m/live-event/dcwuavtj
2) Laptop paired with room system (Best Experience)
a) Dial: [email protected] or 104.238.247.247 in the room system.
b) Go to https://primetime.bluejeans.com/a2m/live-event/dcwuavtj/room-system/
c) Enter the pairing code displayed on your room system's screen into your browser.
3) Room System
a) Dial: [email protected] or 104.238.247.247 in the room system.
b) Enter Meeting ID : 499830564 and Passcode : 8231
4) Joining via a mobile device?
a) Open this link : https://primetime.bluejeans.com/a2m/live-event/dcwuavtj
b) Download the app if you don’t have it already
c) Enter event ID : dcwuavtj
Join from the meeting link
https://ibm.webex.com/ibm/j.php?MTID=m030fdef5ac2d09f46f04813bb5e9dc6b
Tuesday, September 5, 2023 10:00 AM | 30 minutes | (UTC-04:00) Eastern Time (US & Canada)
Occurs every 2 week(s) on Tuesday effective 9/5/2023 from 10:00 AM to 10:30 AM, (UTC-04:00) Eastern Time (US & Canada)
Join by meeting number
Meeting number (access code): 146 967 4515
Tap to join from a mobile device (attendees only)
1-844-531-0958,,1469674515#43533276# United States Toll Free
+1-669-234-1178,,1469674515#43533276# United States Toll
Some mobile devices may ask attendees to enter a numeric password.
Join by phone
1-844-531-0958 United States Toll Free
1-669-234-1178 United States Toll
Global call-in numbers | Toll-free calling restrictions
Join from a video system or application
Dial [email protected]
You can also dial 173.243.2.68 and enter your meeting number.
```

Expand Down
55 changes: 55 additions & 0 deletions docs/trestle_author.md
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,61 @@ Running `trestle author docs validate -tn docs_task -gh="Governed section"` will
- If `--template-version 1.0.0` (`-tv`) is passed the header field `x-trestle-template-version` will be ignored and document will be forcefully validated against template of version `1.0.0`.
Use this for testing purposes _only_ when you need to validate the document against a specific template. By default the template version will be determined based on `x-trestle-template-version` in the document.

### Validating the documents against different templates

Validation against multiple templates can be done when there is a scenario where you have multiple templates that will have multiple instances. In this particular case you can have a 1:1 relationship between the template and the instance document you are creating out of it, so validation can be performed based on template type and version of that particular template defined in headers.

For that to happen you will need to provide your template with the following parameter at the yaml header level, matching the type of template to be implemented so that the validation can occur:

> x-trestle-template-type: insert_template_type_here
Please, take into consideration that for the validation to happen you will also need to provide each instance document in the task folder a field called `x-trestle-template-type: insert_template_type_here` in the yaml header matching with the template name.

```yaml
---
authors: tmp
owner: tmp
valid:
from: null
to: null
x-trestle-template-type: insert_template_type_here
---
```

With that, you will be able to create more than 1 instance document per template and give the instance the desired name.

For instance, let´s consider the next folder structure:

```text
trestle_root
┣ .trestle
┃ ┣ author
┃ ┃ ┣ my_task_2
┃ ┃ ┃ ┣ 0.0.1
┃ ┃ ┃ ┃ ┣ a_template.md
┃ ┃ ┃ ┃ ┣ another_template.md
┃ ┃ ┃ ┃ ┗ arhitecture.drawio
┃ ┗ config.ini
trestle_root
┣ .trestle
┣ my_task_2
┃ ┣ sample_folder_0
┃ ┃ ┣ a_template_1.md
┃ ┃ ┣ a_template_2.md
┃ ┃ ┣ arhitecture_1.drawio
┃ ┃ ┗ another_template_123.md
```

If you noticed, names are no longer needed to match with exact template names, and that´s because validation will run through `x-trestle-template-type` field defined at the instance header, not through the name.

To validate the documents against their respective templates using `x-trestle-template-type`, run:

> trestle author docs validate -tn my_task_name -vtt
Now, `-vtt` stands for validate template type. Validate template type option will provide you the ability to have more than 1 instance per template validated.

</details>

<details markdown>
Expand Down
1 change: 1 addition & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ dev =
pytest-xdist
pre-commit>=2.4.0
setuptools
urllib3==1.26.17
wheel
yapf
python-semantic-release==7.33.2
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
authors: tmp
owner: tmp
valid:
from: null
to: null
x-trestle-template-type: a
x-trestle-template-version: 1.0.0
---
# System architecture

## Overview

## Security model
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
authors: tmp
owner: tmp
valid:
from: null
to: null
x-trestle-template-type: a
x-trestle-template-version: 2.0.0
---
# System architecture

## Overview

## Security model
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
authors: tmp
owner: tmp
valid:
from:
to:
x-trestle-template-type: b
x-trestle-template-version: 1.1.1
---

# Network architectures

## External interconnections

## Corporate interconnections

## Out of scope interconnections
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
authors: tmp
owner: tmp
valid:
from: null
to: null
x-trestle-template-type: a
x-trestle-template-version: 3.0.0
---
# System architecture

## Overview

## Security model
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
authors: tmp
owner: tmp
valid:
from:
to:
x-trestle-template-type: b
x-trestle-template-version: 1.0.0
---

# Network architecture

## External interconnections

## Corporate interconnections

## Out of scope interconnections
14 changes: 14 additions & 0 deletions tests/data/author/docs/a_folder_template/1.0.0/a.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
authors: tmp
owner: tmp
valid:
from: null
to: null
x-trestle-template-type: a
x-trestle-template-version: 1.0.0
---
# System architecture

## Overview

## Security model
17 changes: 17 additions & 0 deletions tests/data/author/docs/a_folder_template/1.0.0/b.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
authors: tmp
owner: tmp
valid:
from:
to:
x-trestle-template-type: b
x-trestle-template-version: 1.0.0
---

# Network architecture

## External interconnections

## Corporate interconnections

## Out of scope interconnections
17 changes: 17 additions & 0 deletions tests/data/author/docs/a_folder_template/1.1.1/b.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
authors: tmp
owner: tmp
valid:
from:
to:
x-trestle-template-type: b
x-trestle-template-version: 1.1.1
---

# Network architectures

## External interconnections

## Corporate interconnections

## Out of scope interconnections
14 changes: 14 additions & 0 deletions tests/data/author/docs/a_folder_template/2.0.0/a.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
authors: tmp
owner: tmp
valid:
from: null
to: null
x-trestle-template-type: a
x-trestle-template-version: 2.0.0
---
# System architecture

## Overview

## Security model
14 changes: 14 additions & 0 deletions tests/data/author/docs/a_folder_template/3.0.0/a.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
authors: tmp
owner: tmp
valid:
from: null
to: null
x-trestle-template-type: a
x-trestle-template-version: 3.0.0
---
# System architecture

## Overview

## Security model
Loading

0 comments on commit 5319028

Please sign in to comment.