mirror of
https://github.com/zkldi/Tachi.git
synced 2026-10-04 12:58:11 +03:00
docs: Fix a lot of random typos and formatting issues (#1245)
This is far from perfect (or everything), but in theory provides a better experience.
This commit is contained in:
@@ -19,4 +19,4 @@ being automated in the background).
|
||||
|
||||
## That's it!
|
||||
|
||||
Seriously -- that's it.
|
||||
Seriously -- that's it.
|
||||
|
||||
@@ -143,7 +143,7 @@ can only be used for USC.
|
||||
- inGameID
|
||||
|
||||
This uses the in-game-ID for this **SONG**. You, therefore,
|
||||
**MUST** specify the difficulty for this chart aswell.
|
||||
**MUST** specify the difficulty for this chart as well.
|
||||
|
||||
This is supported for the following games:
|
||||
|
||||
@@ -158,7 +158,7 @@ This is supported for the following games:
|
||||
- sdvxInGameID
|
||||
|
||||
This uses the in-game-ID for this SDVX song. You must specify
|
||||
the difficulty for this chart aswell.
|
||||
the difficulty for this chart as well.
|
||||
|
||||
The reason SDVX gets its own special `matchType` is because this
|
||||
matchType supports `difficulty: "ANY_INF"`. This special difficulty
|
||||
|
||||
@@ -5,4 +5,3 @@ codebase reference is technically about implementation details, this part is
|
||||
for miscellaneous implementation details that wouldn't fit anywhere else.
|
||||
|
||||
*****
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ representing the same thing.
|
||||
|
||||
## Hashing
|
||||
|
||||
To create the Goal ID, we perform a [json stable hash](https://github.com/zkrising/fast-json-stable-hash) on the
|
||||
To create the Goal ID, we perform a [JSON stable hash](https://github.com/zkrising/fast-json-stable-hash) on the
|
||||
`game`, `playtype`, `charts` and `criteria` of this field.
|
||||
|
||||
This enforces that goals are unique on those fields.
|
||||
|
||||
@@ -40,4 +40,3 @@ pieces of info (i.e. no judgements), then trying to import that same score with
|
||||
judgements later will not work, as the scoreID sees it as a duplicate.
|
||||
|
||||
See [Clobbering](todo).
|
||||
|
||||
|
||||
@@ -43,7 +43,7 @@ An example of this would be an IIDX score with -1 EX Score.
|
||||
## Internal Failure
|
||||
|
||||
This is an internal failure, and thrown when something bad
|
||||
has occured on our end.
|
||||
has occurred on our end.
|
||||
|
||||
The most common case for throwing this is the "Song-Chart"
|
||||
desync. This occurs when a chart has no parent song (and
|
||||
@@ -57,4 +57,4 @@ a chart must have a parent song.)
|
||||
|
||||
If any exception is thrown from a converter that is **NOT**
|
||||
an `instanceof` ConverterFailure, it is treated as an
|
||||
InternalFailure.
|
||||
InternalFailure.
|
||||
|
||||
@@ -19,7 +19,7 @@ Else, the import is logged as debug.
|
||||
|
||||
An internal document - Import Timings - is created by
|
||||
storing the time each step of the import process took
|
||||
in miliseconds.
|
||||
in milliseconds.
|
||||
|
||||
This is analysed regularly to check for performance
|
||||
degradation and look for potential optimisations.
|
||||
|
||||
@@ -17,7 +17,7 @@ fledged Tachi score, and then goes over how it is imported.
|
||||
|
||||
## Return Format
|
||||
|
||||
The `ImportIterableDatapoint` returns
|
||||
The `ImportIterableDatapoint` returns
|
||||
`ImportProcessingInfo` or `null`. The format for the former
|
||||
can be found in `tachi-common`, and **should be read** before
|
||||
following this document!
|
||||
|
||||
@@ -147,10 +147,9 @@ value of this function.
|
||||
|
||||
### Import Timings
|
||||
|
||||
Every step in this process is timed in miliseconds.
|
||||
Every step in this process is timed in milliseconds.
|
||||
|
||||
The time each step took is saved alongside the ImportID.
|
||||
|
||||
This is used for internal debugging and degraded performance
|
||||
checks.
|
||||
|
||||
|
||||
@@ -30,4 +30,4 @@ If it results in a success, we have a new DryScore we can import.
|
||||
!!! note
|
||||
This is why Converter Functions are completely
|
||||
static, so we can safely call the same Converter
|
||||
Function with this data to unorphan scores.
|
||||
Function with this data to unorphan scores.
|
||||
|
||||
@@ -276,6 +276,7 @@ that means that they cannot be dynamically constructed
|
||||
with closures or similar.
|
||||
|
||||
### Arguments
|
||||
|
||||
Converters are called with these four arguments:
|
||||
|
||||
| Property | Type | Description |
|
||||
|
||||
@@ -29,4 +29,4 @@ in successive score import steps.
|
||||
Some imports may import scores from multiple Playtypes. We
|
||||
frequently want to only refer to the set of scores modified
|
||||
under a given playtype (For importing a users game:playtype stats, as an example)
|
||||
so this is a very useful data structure to have.
|
||||
so this is a very useful data structure to have.
|
||||
|
||||
@@ -17,4 +17,4 @@ is emitted, which could be hooked into by our Discord Bot.
|
||||
|
||||
If the progress has changed at all, the data is
|
||||
pushed to an array which is then returned. This is
|
||||
attached onto the Import Document.
|
||||
attached onto the Import Document.
|
||||
|
||||
@@ -12,4 +12,4 @@ Tachi fully supports OAuth2. When you create a Tachi API Client, you can set a `
|
||||
|
||||
## Client File Flow
|
||||
|
||||
Alternatively, if you're just looking for a nice UI for users to create an API Key with the right permissions, check out the [Client File Flow](./file-flow.md).
|
||||
Alternatively, if you're just looking for a nice UI for users to create an API Key with the right permissions, check out the [Client File Flow](./file-flow.md).
|
||||
|
||||
@@ -37,7 +37,7 @@ logger.severe("foo");
|
||||
|
||||
`severe` is the second most severe log level in tachi.
|
||||
|
||||
Calling this means an error has occured, and that error implies
|
||||
Calling this means an error has occurred, and that error implies
|
||||
it will apply to multiple parts of the codebase.
|
||||
|
||||
This log level is used with things like a Song-Chart
|
||||
@@ -54,7 +54,7 @@ logger.error("foo");
|
||||
|
||||
`error` is the third most severe log level in tachi.
|
||||
|
||||
Calling this means an error has occured, but the impact of
|
||||
Calling this means an error has occurred, but the impact of
|
||||
it is limited to the function or general area it was called in.
|
||||
|
||||
Errors may be recovered from or ignored by the code, but generally that should be reserved for `warn`.
|
||||
|
||||
@@ -179,7 +179,6 @@ If present, and a string, this points to the local dev server for a react app. H
|
||||
option set results in CORS being enabled for *that* specific URL. This is useful for local
|
||||
development, but should not be used in production.
|
||||
|
||||
|
||||
### RATE_LIMIT
|
||||
|
||||
- Type: Positive Integer
|
||||
@@ -242,7 +241,6 @@ Where *this* server is hosted. This is used to
|
||||
provide callback URLs inside emails. You may stub
|
||||
it out if emails are unsupported.
|
||||
|
||||
|
||||
### EMAIL_CONFIG
|
||||
|
||||
- Type: EMAIL_CONFIG | undefined.
|
||||
|
||||
@@ -130,7 +130,7 @@ https://boku.tachi.ac/api/v1/foo/bar
|
||||
|
||||
The only files allowed to declare endpoints are `router.ts` files.
|
||||
|
||||
This allows us to seperate functionality from API structure
|
||||
This allows us to separate functionality from API structure
|
||||
in cases where an API call needs to do a lot of things.
|
||||
|
||||
## Test Files
|
||||
|
||||
Reference in New Issue
Block a user