From f0b6b0405fa98636579e25e27b23880215beea97 Mon Sep 17 00:00:00 2001 From: ikelos Date: Tue, 25 Mar 2025 17:27:31 +0000 Subject: [PATCH] Update CODING_STYLE.md Hehehe, good catch, thanks! 5:D Co-authored-by: Donghyun Kim --- CODING_STYLE.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CODING_STYLE.md b/CODING_STYLE.md index bf12288d3..700167258 100644 --- a/CODING_STYLE.md +++ b/CODING_STYLE.md @@ -66,7 +66,7 @@ Shared functionality -------------------- Within a plugin, there may be functions that are useful to other plugins. These are created as `classmethod`s so that the plugin can be depended upon by other plugins in their requirements section, without needing to instantiate a whole copy of the plugin. It is not a staticmethod, because the caller may wish to determine information about the class the method is defined in, and this is not easily accessible for staticmethods. -A classmethod usually takes a `context` for its first method (and if it requires one, a configuration string for it second). All other parameters should generally be basic types (such as strings, numbers, etc) so that future work requiring paralellization does not have complex types to have to keep in sync. In particular, the idea was to ensure only one context was used per method (and each object brings its own context with it, meaning the function signature should not include objects to avoid discrepancies). +A classmethod usually takes a `context` for its first method (and if it requires one, a configuration string for it second). All other parameters should generally be basic types (such as strings, numbers, etc) so that future work requiring parallelization does not have complex types to have to keep in sync. In particular, the idea was to ensure only one context was used per method (and each object brings its own context with it, meaning the function signature should not include objects to avoid discrepancies). Comprehensions --------------