From 07943f1d58f722637ada2cb97ac21732f6b71f0e Mon Sep 17 00:00:00 2001 From: Jose Celano Date: Wed, 10 May 2023 16:27:56 +0100 Subject: [PATCH] docs: add adr for lowercase infohashes --- adrs/20230510152112_lowercas_infohashes.md | 20 +++++++++++++++++++ adrs/README.md | 23 ++++++++++++++++++++++ 2 files changed, 43 insertions(+) create mode 100644 adrs/20230510152112_lowercas_infohashes.md create mode 100644 adrs/README.md diff --git a/adrs/20230510152112_lowercas_infohashes.md b/adrs/20230510152112_lowercas_infohashes.md new file mode 100644 index 00000000..f03bb12b --- /dev/null +++ b/adrs/20230510152112_lowercas_infohashes.md @@ -0,0 +1,20 @@ +# Lowercase infohashes + +## Description + +We use both uppercase and lowercase infohashes. This is a problem because +we have to check both cases. For example, we have to convert to uppercase before +inserting into the database or querying the database. + +The database and API URLs use uppercase infohashes, and they are case-sensitive. + +## Agreement + +We agree on use lowercase infohashes everywhere and try to convert then as soon +as possible from the input. + +There is no specific reason to use lowercase infohashes, but we have to choose +one of them. We decided to use lowercase because the infohash is a hash, and +hashes are usually lowercase. + +We will change them progressively. diff --git a/adrs/README.md b/adrs/README.md new file mode 100644 index 00000000..85986fc3 --- /dev/null +++ b/adrs/README.md @@ -0,0 +1,23 @@ +# Architectural Decision Records (ADRs) + +This directory contains the architectural decision records (ADRs) for the +project. ADRs are a way to document the architectural decisions made in the +project. + +More info: . + +## How to add a new record + +For the prefix: + +```s +date -u +"%Y%m%d%H%M%S" +``` + +Then you can create a new markdown file with the following format: + +```s +20230510152112_title.md +``` + +For the time being, we are not following any specific template.