Skip to content
This repository was archived by the owner on May 20, 2025. It is now read-only.

Commit 9226821

Browse files
committed
fix implicit expectations list
1 parent 9d7fc77 commit 9226821

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

docs/get-started/foundations/why-nitric.mdx

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,12 +142,15 @@ Future<List<int>> getReceiptDoc(String filename) async {
142142

143143
</CodeSwitcher>
144144

145-
Code like this makes very clear demands of the environment it expects to run in:
145+
Code like very clearly sets up a list of implicit expectations of the environment it runs in:
146146

147147
- I need a bucket to be available
148148
- I need to be able to read objects from that bucket
149149
- The bucket must be an AWS S3 bucket
150-
- I need to know the ARN/Name of the bucket
150+
- I expect the S3 API to be accessible (networking)
151+
- I need to know the name of the bucket
152+
- I expect the bucket name to be provided via an environment variable
153+
- The environment variable must be named `RECEIPT_DOCUMENTS_BUCKET`
151154

152155
The problem is that these requirements are implicit. They're hidden throughout the code and for non-trivial apps it's challenging to collect them all and be sure the requirements are met.
153156

0 commit comments

Comments
 (0)