ruby-lsp-rake 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +0 -14
- data/lib/ruby/lsp/rake/version.rb +2 -1
- data/lib/ruby/lsp/rake.rb +1 -0
- data/lib/ruby_lsp/ruby_lsp_rake/addon.rb +4 -2
- data/lib/ruby_lsp/ruby_lsp_rake/hover.rb +2 -1
- data/lib/ruby_lsp/ruby_lsp_rake/indexing_enhancement.rb +7 -4
- data/sorbet/config +4 -0
- data/sorbet/rbi/annotations/.gitattributes +1 -0
- data/sorbet/rbi/annotations/minitest.rbi +119 -0
- data/sorbet/rbi/annotations/rainbow.rbi +269 -0
- data/sorbet/rbi/gems/.gitattributes +1 -0
- data/sorbet/rbi/gems/ast@2.4.2.rbi +585 -0
- data/sorbet/rbi/gems/erubi@1.13.0.rbi +150 -0
- data/sorbet/rbi/gems/json@2.8.2.rbi +1901 -0
- data/sorbet/rbi/gems/language_server-protocol@3.17.0.3.rbi +14238 -0
- data/sorbet/rbi/gems/logger@1.6.1.rbi +920 -0
- data/sorbet/rbi/gems/minitest@5.25.2.rbi +2209 -0
- data/sorbet/rbi/gems/netrc@0.11.0.rbi +159 -0
- data/sorbet/rbi/gems/parallel@1.26.3.rbi +291 -0
- data/sorbet/rbi/gems/parser@3.3.6.0.rbi +5519 -0
- data/sorbet/rbi/gems/prism@1.2.0.rbi +39085 -0
- data/sorbet/rbi/gems/racc@1.8.1.rbi +162 -0
- data/sorbet/rbi/gems/rainbow@3.1.1.rbi +403 -0
- data/sorbet/rbi/gems/rake@13.2.1.rbi +3028 -0
- data/sorbet/rbi/gems/rbi@0.2.1.rbi +4535 -0
- data/sorbet/rbi/gems/rbs@3.6.1.rbi +6857 -0
- data/sorbet/rbi/gems/regexp_parser@2.9.2.rbi +3772 -0
- data/sorbet/rbi/gems/rubocop-ast@1.36.2.rbi +7570 -0
- data/sorbet/rbi/gems/rubocop@1.69.0.rbi +59347 -0
- data/sorbet/rbi/gems/ruby-lsp@0.22.1.rbi +6119 -0
- data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +1318 -0
- data/sorbet/rbi/gems/spoom@1.5.0.rbi +4932 -0
- data/sorbet/rbi/gems/tapioca@0.16.5.rbi +3598 -0
- data/sorbet/rbi/gems/thor@1.3.2.rbi +4378 -0
- data/sorbet/rbi/gems/unicode-display_width@3.1.2.rbi +130 -0
- data/sorbet/rbi/gems/unicode-emoji@4.0.4.rbi +251 -0
- data/sorbet/rbi/gems/yard-sorbet@0.9.0.rbi +435 -0
- data/sorbet/rbi/gems/yard@0.9.37.rbi +18379 -0
- data/sorbet/tapioca/config.yml +13 -0
- data/sorbet/tapioca/require.rb +11 -0
- metadata +36 -2
@@ -0,0 +1,920 @@
|
|
1
|
+
# typed: false
|
2
|
+
|
3
|
+
# DO NOT EDIT MANUALLY
|
4
|
+
# This is an autogenerated file for types exported from the `logger` gem.
|
5
|
+
# Please instead update this file by running `bin/tapioca gem logger`.
|
6
|
+
|
7
|
+
|
8
|
+
# \Class \Logger provides a simple but sophisticated logging utility that
|
9
|
+
# you can use to create one or more
|
10
|
+
# {event logs}[https://en.wikipedia.org/wiki/Logging_(software)#Event_logs]
|
11
|
+
# for your program.
|
12
|
+
# Each such log contains a chronological sequence of entries
|
13
|
+
# that provides a record of the program's activities.
|
14
|
+
#
|
15
|
+
# == About the Examples
|
16
|
+
#
|
17
|
+
# All examples on this page assume that \Logger has been required:
|
18
|
+
#
|
19
|
+
# require 'logger'
|
20
|
+
#
|
21
|
+
# == Synopsis
|
22
|
+
#
|
23
|
+
# Create a log with Logger.new:
|
24
|
+
#
|
25
|
+
# # Single log file.
|
26
|
+
# logger = Logger.new('t.log')
|
27
|
+
# # Size-based rotated logging: 3 10-megabyte files.
|
28
|
+
# logger = Logger.new('t.log', 3, 10485760)
|
29
|
+
# # Period-based rotated logging: daily (also allowed: 'weekly', 'monthly').
|
30
|
+
# logger = Logger.new('t.log', 'daily')
|
31
|
+
# # Log to an IO stream.
|
32
|
+
# logger = Logger.new($stdout)
|
33
|
+
#
|
34
|
+
# Add entries (level, message) with Logger#add:
|
35
|
+
#
|
36
|
+
# logger.add(Logger::DEBUG, 'Maximal debugging info')
|
37
|
+
# logger.add(Logger::INFO, 'Non-error information')
|
38
|
+
# logger.add(Logger::WARN, 'Non-error warning')
|
39
|
+
# logger.add(Logger::ERROR, 'Non-fatal error')
|
40
|
+
# logger.add(Logger::FATAL, 'Fatal error')
|
41
|
+
# logger.add(Logger::UNKNOWN, 'Most severe')
|
42
|
+
#
|
43
|
+
# Close the log with Logger#close:
|
44
|
+
#
|
45
|
+
# logger.close
|
46
|
+
#
|
47
|
+
# == Entries
|
48
|
+
#
|
49
|
+
# You can add entries with method Logger#add:
|
50
|
+
#
|
51
|
+
# logger.add(Logger::DEBUG, 'Maximal debugging info')
|
52
|
+
# logger.add(Logger::INFO, 'Non-error information')
|
53
|
+
# logger.add(Logger::WARN, 'Non-error warning')
|
54
|
+
# logger.add(Logger::ERROR, 'Non-fatal error')
|
55
|
+
# logger.add(Logger::FATAL, 'Fatal error')
|
56
|
+
# logger.add(Logger::UNKNOWN, 'Most severe')
|
57
|
+
#
|
58
|
+
# These shorthand methods also add entries:
|
59
|
+
#
|
60
|
+
# logger.debug('Maximal debugging info')
|
61
|
+
# logger.info('Non-error information')
|
62
|
+
# logger.warn('Non-error warning')
|
63
|
+
# logger.error('Non-fatal error')
|
64
|
+
# logger.fatal('Fatal error')
|
65
|
+
# logger.unknown('Most severe')
|
66
|
+
#
|
67
|
+
# When you call any of these methods,
|
68
|
+
# the entry may or may not be written to the log,
|
69
|
+
# depending on the entry's severity and on the log level;
|
70
|
+
# see {Log Level}[rdoc-ref:Logger@Log+Level]
|
71
|
+
#
|
72
|
+
# An entry always has:
|
73
|
+
#
|
74
|
+
# - A severity (the required argument to #add).
|
75
|
+
# - An automatically created timestamp.
|
76
|
+
#
|
77
|
+
# And may also have:
|
78
|
+
#
|
79
|
+
# - A message.
|
80
|
+
# - A program name.
|
81
|
+
#
|
82
|
+
# Example:
|
83
|
+
#
|
84
|
+
# logger = Logger.new($stdout)
|
85
|
+
# logger.add(Logger::INFO, 'My message.', 'mung')
|
86
|
+
# # => I, [2022-05-07T17:21:46.536234 #20536] INFO -- mung: My message.
|
87
|
+
#
|
88
|
+
# The default format for an entry is:
|
89
|
+
#
|
90
|
+
# "%s, [%s #%d] %5s -- %s: %s\n"
|
91
|
+
#
|
92
|
+
# where the values to be formatted are:
|
93
|
+
#
|
94
|
+
# - \Severity (one letter).
|
95
|
+
# - Timestamp.
|
96
|
+
# - Process id.
|
97
|
+
# - \Severity (word).
|
98
|
+
# - Program name.
|
99
|
+
# - Message.
|
100
|
+
#
|
101
|
+
# You can use a different entry format by:
|
102
|
+
#
|
103
|
+
# - Setting a custom format proc (affects following entries);
|
104
|
+
# see {formatter=}[Logger.html#attribute-i-formatter].
|
105
|
+
# - Calling any of the methods above with a block
|
106
|
+
# (affects only the one entry).
|
107
|
+
# Doing so can have two benefits:
|
108
|
+
#
|
109
|
+
# - Context: the block can evaluate the entire program context
|
110
|
+
# and create a context-dependent message.
|
111
|
+
# - Performance: the block is not evaluated unless the log level
|
112
|
+
# permits the entry actually to be written:
|
113
|
+
#
|
114
|
+
# logger.error { my_slow_message_generator }
|
115
|
+
#
|
116
|
+
# Contrast this with the string form, where the string is
|
117
|
+
# always evaluated, regardless of the log level:
|
118
|
+
#
|
119
|
+
# logger.error("#{my_slow_message_generator}")
|
120
|
+
#
|
121
|
+
# === \Severity
|
122
|
+
#
|
123
|
+
# The severity of a log entry has two effects:
|
124
|
+
#
|
125
|
+
# - Determines whether the entry is selected for inclusion in the log;
|
126
|
+
# see {Log Level}[rdoc-ref:Logger@Log+Level].
|
127
|
+
# - Indicates to any log reader (whether a person or a program)
|
128
|
+
# the relative importance of the entry.
|
129
|
+
#
|
130
|
+
# === Timestamp
|
131
|
+
#
|
132
|
+
# The timestamp for a log entry is generated automatically
|
133
|
+
# when the entry is created.
|
134
|
+
#
|
135
|
+
# The logged timestamp is formatted by method
|
136
|
+
# {Time#strftime}[https://docs.ruby-lang.org/en/master/Time.html#method-i-strftime]
|
137
|
+
# using this format string:
|
138
|
+
#
|
139
|
+
# '%Y-%m-%dT%H:%M:%S.%6N'
|
140
|
+
#
|
141
|
+
# Example:
|
142
|
+
#
|
143
|
+
# logger = Logger.new($stdout)
|
144
|
+
# logger.add(Logger::INFO)
|
145
|
+
# # => I, [2022-05-07T17:04:32.318331 #20536] INFO -- : nil
|
146
|
+
#
|
147
|
+
# You can set a different format using method #datetime_format=.
|
148
|
+
#
|
149
|
+
# === Message
|
150
|
+
#
|
151
|
+
# The message is an optional argument to an entry method:
|
152
|
+
#
|
153
|
+
# logger = Logger.new($stdout)
|
154
|
+
# logger.add(Logger::INFO, 'My message')
|
155
|
+
# # => I, [2022-05-07T18:15:37.647581 #20536] INFO -- : My message
|
156
|
+
#
|
157
|
+
# For the default entry formatter, <tt>Logger::Formatter</tt>,
|
158
|
+
# the message object may be:
|
159
|
+
#
|
160
|
+
# - A string: used as-is.
|
161
|
+
# - An Exception: <tt>message.message</tt> is used.
|
162
|
+
# - Anything else: <tt>message.inspect</tt> is used.
|
163
|
+
#
|
164
|
+
# *Note*: Logger::Formatter does not escape or sanitize
|
165
|
+
# the message passed to it.
|
166
|
+
# Developers should be aware that malicious data (user input)
|
167
|
+
# may be in the message, and should explicitly escape untrusted data.
|
168
|
+
#
|
169
|
+
# You can use a custom formatter to escape message data;
|
170
|
+
# see the example at {formatter=}[Logger.html#attribute-i-formatter].
|
171
|
+
#
|
172
|
+
# === Program Name
|
173
|
+
#
|
174
|
+
# The program name is an optional argument to an entry method:
|
175
|
+
#
|
176
|
+
# logger = Logger.new($stdout)
|
177
|
+
# logger.add(Logger::INFO, 'My message', 'mung')
|
178
|
+
# # => I, [2022-05-07T18:17:38.084716 #20536] INFO -- mung: My message
|
179
|
+
#
|
180
|
+
# The default program name for a new logger may be set in the call to
|
181
|
+
# Logger.new via optional keyword argument +progname+:
|
182
|
+
#
|
183
|
+
# logger = Logger.new('t.log', progname: 'mung')
|
184
|
+
#
|
185
|
+
# The default program name for an existing logger may be set
|
186
|
+
# by a call to method #progname=:
|
187
|
+
#
|
188
|
+
# logger.progname = 'mung'
|
189
|
+
#
|
190
|
+
# The current program name may be retrieved with method
|
191
|
+
# {progname}[Logger.html#attribute-i-progname]:
|
192
|
+
#
|
193
|
+
# logger.progname # => "mung"
|
194
|
+
#
|
195
|
+
# == Log Level
|
196
|
+
#
|
197
|
+
# The log level setting determines whether an entry is actually
|
198
|
+
# written to the log, based on the entry's severity.
|
199
|
+
#
|
200
|
+
# These are the defined severities (least severe to most severe):
|
201
|
+
#
|
202
|
+
# logger = Logger.new($stdout)
|
203
|
+
# logger.add(Logger::DEBUG, 'Maximal debugging info')
|
204
|
+
# # => D, [2022-05-07T17:57:41.776220 #20536] DEBUG -- : Maximal debugging info
|
205
|
+
# logger.add(Logger::INFO, 'Non-error information')
|
206
|
+
# # => I, [2022-05-07T17:59:14.349167 #20536] INFO -- : Non-error information
|
207
|
+
# logger.add(Logger::WARN, 'Non-error warning')
|
208
|
+
# # => W, [2022-05-07T18:00:45.337538 #20536] WARN -- : Non-error warning
|
209
|
+
# logger.add(Logger::ERROR, 'Non-fatal error')
|
210
|
+
# # => E, [2022-05-07T18:02:41.592912 #20536] ERROR -- : Non-fatal error
|
211
|
+
# logger.add(Logger::FATAL, 'Fatal error')
|
212
|
+
# # => F, [2022-05-07T18:05:24.703931 #20536] FATAL -- : Fatal error
|
213
|
+
# logger.add(Logger::UNKNOWN, 'Most severe')
|
214
|
+
# # => A, [2022-05-07T18:07:54.657491 #20536] ANY -- : Most severe
|
215
|
+
#
|
216
|
+
# The default initial level setting is Logger::DEBUG, the lowest level,
|
217
|
+
# which means that all entries are to be written, regardless of severity:
|
218
|
+
#
|
219
|
+
# logger = Logger.new($stdout)
|
220
|
+
# logger.level # => 0
|
221
|
+
# logger.add(0, "My message")
|
222
|
+
# # => D, [2022-05-11T15:10:59.773668 #20536] DEBUG -- : My message
|
223
|
+
#
|
224
|
+
# You can specify a different setting in a new logger
|
225
|
+
# using keyword argument +level+ with an appropriate value:
|
226
|
+
#
|
227
|
+
# logger = Logger.new($stdout, level: Logger::ERROR)
|
228
|
+
# logger = Logger.new($stdout, level: 'error')
|
229
|
+
# logger = Logger.new($stdout, level: :error)
|
230
|
+
# logger.level # => 3
|
231
|
+
#
|
232
|
+
# With this level, entries with severity Logger::ERROR and higher
|
233
|
+
# are written, while those with lower severities are not written:
|
234
|
+
#
|
235
|
+
# logger = Logger.new($stdout, level: Logger::ERROR)
|
236
|
+
# logger.add(3)
|
237
|
+
# # => E, [2022-05-11T15:17:20.933362 #20536] ERROR -- : nil
|
238
|
+
# logger.add(2) # Silent.
|
239
|
+
#
|
240
|
+
# You can set the log level for an existing logger
|
241
|
+
# with method #level=:
|
242
|
+
#
|
243
|
+
# logger.level = Logger::ERROR
|
244
|
+
#
|
245
|
+
# These shorthand methods also set the level:
|
246
|
+
#
|
247
|
+
# logger.debug! # => 0
|
248
|
+
# logger.info! # => 1
|
249
|
+
# logger.warn! # => 2
|
250
|
+
# logger.error! # => 3
|
251
|
+
# logger.fatal! # => 4
|
252
|
+
#
|
253
|
+
# You can retrieve the log level with method #level.
|
254
|
+
#
|
255
|
+
# logger.level = Logger::ERROR
|
256
|
+
# logger.level # => 3
|
257
|
+
#
|
258
|
+
# These methods return whether a given
|
259
|
+
# level is to be written:
|
260
|
+
#
|
261
|
+
# logger.level = Logger::ERROR
|
262
|
+
# logger.debug? # => false
|
263
|
+
# logger.info? # => false
|
264
|
+
# logger.warn? # => false
|
265
|
+
# logger.error? # => true
|
266
|
+
# logger.fatal? # => true
|
267
|
+
#
|
268
|
+
# == Log File Rotation
|
269
|
+
#
|
270
|
+
# By default, a log file is a single file that grows indefinitely
|
271
|
+
# (until explicitly closed); there is no file rotation.
|
272
|
+
#
|
273
|
+
# To keep log files to a manageable size,
|
274
|
+
# you can use _log_ _file_ _rotation_, which uses multiple log files:
|
275
|
+
#
|
276
|
+
# - Each log file has entries for a non-overlapping
|
277
|
+
# time interval.
|
278
|
+
# - Only the most recent log file is open and active;
|
279
|
+
# the others are closed and inactive.
|
280
|
+
#
|
281
|
+
# === Size-Based Rotation
|
282
|
+
#
|
283
|
+
# For size-based log file rotation, call Logger.new with:
|
284
|
+
#
|
285
|
+
# - Argument +logdev+ as a file path.
|
286
|
+
# - Argument +shift_age+ with a positive integer:
|
287
|
+
# the number of log files to be in the rotation.
|
288
|
+
# - Argument +shift_size+ as a positive integer:
|
289
|
+
# the maximum size (in bytes) of each log file;
|
290
|
+
# defaults to 1048576 (1 megabyte).
|
291
|
+
#
|
292
|
+
# Examples:
|
293
|
+
#
|
294
|
+
# logger = Logger.new('t.log', 3) # Three 1-megabyte files.
|
295
|
+
# logger = Logger.new('t.log', 5, 10485760) # Five 10-megabyte files.
|
296
|
+
#
|
297
|
+
# For these examples, suppose:
|
298
|
+
#
|
299
|
+
# logger = Logger.new('t.log', 3)
|
300
|
+
#
|
301
|
+
# Logging begins in the new log file, +t.log+;
|
302
|
+
# the log file is "full" and ready for rotation
|
303
|
+
# when a new entry would cause its size to exceed +shift_size+.
|
304
|
+
#
|
305
|
+
# The first time +t.log+ is full:
|
306
|
+
#
|
307
|
+
# - +t.log+ is closed and renamed to +t.log.0+.
|
308
|
+
# - A new file +t.log+ is opened.
|
309
|
+
#
|
310
|
+
# The second time +t.log+ is full:
|
311
|
+
#
|
312
|
+
# - +t.log.0 is renamed as +t.log.1+.
|
313
|
+
# - +t.log+ is closed and renamed to +t.log.0+.
|
314
|
+
# - A new file +t.log+ is opened.
|
315
|
+
#
|
316
|
+
# Each subsequent time that +t.log+ is full,
|
317
|
+
# the log files are rotated:
|
318
|
+
#
|
319
|
+
# - +t.log.1+ is removed.
|
320
|
+
# - +t.log.0 is renamed as +t.log.1+.
|
321
|
+
# - +t.log+ is closed and renamed to +t.log.0+.
|
322
|
+
# - A new file +t.log+ is opened.
|
323
|
+
#
|
324
|
+
# === Periodic Rotation
|
325
|
+
#
|
326
|
+
# For periodic rotation, call Logger.new with:
|
327
|
+
#
|
328
|
+
# - Argument +logdev+ as a file path.
|
329
|
+
# - Argument +shift_age+ as a string period indicator.
|
330
|
+
#
|
331
|
+
# Examples:
|
332
|
+
#
|
333
|
+
# logger = Logger.new('t.log', 'daily') # Rotate log files daily.
|
334
|
+
# logger = Logger.new('t.log', 'weekly') # Rotate log files weekly.
|
335
|
+
# logger = Logger.new('t.log', 'monthly') # Rotate log files monthly.
|
336
|
+
#
|
337
|
+
# Example:
|
338
|
+
#
|
339
|
+
# logger = Logger.new('t.log', 'daily')
|
340
|
+
#
|
341
|
+
# When the given period expires:
|
342
|
+
#
|
343
|
+
# - The base log file, +t.log+ is closed and renamed
|
344
|
+
# with a date-based suffix such as +t.log.20220509+.
|
345
|
+
# - A new log file +t.log+ is opened.
|
346
|
+
# - Nothing is removed.
|
347
|
+
#
|
348
|
+
# The default format for the suffix is <tt>'%Y%m%d'</tt>,
|
349
|
+
# which produces a suffix similar to the one above.
|
350
|
+
# You can set a different format using create-time option
|
351
|
+
# +shift_period_suffix+;
|
352
|
+
# see details and suggestions at
|
353
|
+
# {Time#strftime}[https://docs.ruby-lang.org/en/master/Time.html#method-i-strftime].
|
354
|
+
#
|
355
|
+
# source://logger/lib/logger/version.rb#3
|
356
|
+
class Logger
|
357
|
+
include ::Logger::Severity
|
358
|
+
|
359
|
+
# :call-seq:
|
360
|
+
# Logger.new(logdev, shift_age = 0, shift_size = 1048576, **options)
|
361
|
+
#
|
362
|
+
# With the single argument +logdev+,
|
363
|
+
# returns a new logger with all default options:
|
364
|
+
#
|
365
|
+
# Logger.new('t.log') # => #<Logger:0x000001e685dc6ac8>
|
366
|
+
#
|
367
|
+
# Argument +logdev+ must be one of:
|
368
|
+
#
|
369
|
+
# - A string filepath: entries are to be written
|
370
|
+
# to the file at that path; if the file at that path exists,
|
371
|
+
# new entries are appended.
|
372
|
+
# - An IO stream (typically +$stdout+, +$stderr+. or an open file):
|
373
|
+
# entries are to be written to the given stream.
|
374
|
+
# - +nil+ or +File::NULL+: no entries are to be written.
|
375
|
+
#
|
376
|
+
# Examples:
|
377
|
+
#
|
378
|
+
# Logger.new('t.log')
|
379
|
+
# Logger.new($stdout)
|
380
|
+
#
|
381
|
+
# The keyword options are:
|
382
|
+
#
|
383
|
+
# - +level+: sets the log level; default value is Logger::DEBUG.
|
384
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level]:
|
385
|
+
#
|
386
|
+
# Logger.new('t.log', level: Logger::ERROR)
|
387
|
+
#
|
388
|
+
# - +progname+: sets the default program name; default is +nil+.
|
389
|
+
# See {Program Name}[rdoc-ref:Logger@Program+Name]:
|
390
|
+
#
|
391
|
+
# Logger.new('t.log', progname: 'mung')
|
392
|
+
#
|
393
|
+
# - +formatter+: sets the entry formatter; default is +nil+.
|
394
|
+
# See {formatter=}[Logger.html#attribute-i-formatter].
|
395
|
+
# - +datetime_format+: sets the format for entry timestamp;
|
396
|
+
# default is +nil+.
|
397
|
+
# See #datetime_format=.
|
398
|
+
# - +binmode+: sets whether the logger writes in binary mode;
|
399
|
+
# default is +false+.
|
400
|
+
# - +shift_period_suffix+: sets the format for the filename suffix
|
401
|
+
# for periodic log file rotation; default is <tt>'%Y%m%d'</tt>.
|
402
|
+
# See {Periodic Rotation}[rdoc-ref:Logger@Periodic+Rotation].
|
403
|
+
# - +reraise_write_errors+: An array of exception classes, which will
|
404
|
+
# be reraised if there is an error when writing to the log device.
|
405
|
+
# The default is to swallow all exceptions raised.
|
406
|
+
#
|
407
|
+
# @return [Logger] a new instance of Logger
|
408
|
+
#
|
409
|
+
# source://logger/lib/logger.rb#581
|
410
|
+
def initialize(logdev, shift_age = T.unsafe(nil), shift_size = T.unsafe(nil), level: T.unsafe(nil), progname: T.unsafe(nil), formatter: T.unsafe(nil), datetime_format: T.unsafe(nil), binmode: T.unsafe(nil), shift_period_suffix: T.unsafe(nil), reraise_write_errors: T.unsafe(nil)); end
|
411
|
+
|
412
|
+
# Writes the given +msg+ to the log with no formatting;
|
413
|
+
# returns the number of characters written,
|
414
|
+
# or +nil+ if no log device exists:
|
415
|
+
#
|
416
|
+
# logger = Logger.new($stdout)
|
417
|
+
# logger << 'My message.' # => 10
|
418
|
+
#
|
419
|
+
# Output:
|
420
|
+
#
|
421
|
+
# My message.
|
422
|
+
#
|
423
|
+
# source://logger/lib/logger.rb#689
|
424
|
+
def <<(msg); end
|
425
|
+
|
426
|
+
# Creates a log entry, which may or may not be written to the log,
|
427
|
+
# depending on the entry's severity and on the log level.
|
428
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level]
|
429
|
+
# and {Entries}[rdoc-ref:Logger@Entries] for details.
|
430
|
+
#
|
431
|
+
# Examples:
|
432
|
+
#
|
433
|
+
# logger = Logger.new($stdout, progname: 'mung')
|
434
|
+
# logger.add(Logger::INFO)
|
435
|
+
# logger.add(Logger::ERROR, 'No good')
|
436
|
+
# logger.add(Logger::ERROR, 'No good', 'gnum')
|
437
|
+
#
|
438
|
+
# Output:
|
439
|
+
#
|
440
|
+
# I, [2022-05-12T16:25:31.469726 #36328] INFO -- mung: mung
|
441
|
+
# E, [2022-05-12T16:25:55.349414 #36328] ERROR -- mung: No good
|
442
|
+
# E, [2022-05-12T16:26:35.841134 #36328] ERROR -- gnum: No good
|
443
|
+
#
|
444
|
+
# These convenience methods have implicit severity:
|
445
|
+
#
|
446
|
+
# - #debug.
|
447
|
+
# - #info.
|
448
|
+
# - #warn.
|
449
|
+
# - #error.
|
450
|
+
# - #fatal.
|
451
|
+
# - #unknown.
|
452
|
+
#
|
453
|
+
# source://logger/lib/logger.rb#656
|
454
|
+
def add(severity, message = T.unsafe(nil), progname = T.unsafe(nil)); end
|
455
|
+
|
456
|
+
# Closes the logger; returns +nil+:
|
457
|
+
#
|
458
|
+
# logger = Logger.new('t.log')
|
459
|
+
# logger.close # => nil
|
460
|
+
# logger.info('foo') # Prints "log writing failed. closed stream"
|
461
|
+
#
|
462
|
+
# Related: Logger#reopen.
|
463
|
+
#
|
464
|
+
# source://logger/lib/logger.rb#736
|
465
|
+
def close; end
|
466
|
+
|
467
|
+
# Returns the date-time format; see #datetime_format=.
|
468
|
+
#
|
469
|
+
# source://logger/lib/logger.rb#438
|
470
|
+
def datetime_format; end
|
471
|
+
|
472
|
+
# Sets the date-time format.
|
473
|
+
#
|
474
|
+
# Argument +datetime_format+ should be either of these:
|
475
|
+
#
|
476
|
+
# - A string suitable for use as a format for method
|
477
|
+
# {Time#strftime}[https://docs.ruby-lang.org/en/master/Time.html#method-i-strftime].
|
478
|
+
# - +nil+: the logger uses <tt>'%Y-%m-%dT%H:%M:%S.%6N'</tt>.
|
479
|
+
#
|
480
|
+
# source://logger/lib/logger.rb#432
|
481
|
+
def datetime_format=(datetime_format); end
|
482
|
+
|
483
|
+
# Equivalent to calling #add with severity <tt>Logger::DEBUG</tt>.
|
484
|
+
#
|
485
|
+
# source://logger/lib/logger.rb#695
|
486
|
+
def debug(progname = T.unsafe(nil), &block); end
|
487
|
+
|
488
|
+
# Sets the log level to Logger::DEBUG.
|
489
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level].
|
490
|
+
#
|
491
|
+
# source://logger/lib/logger.rb#487
|
492
|
+
def debug!; end
|
493
|
+
|
494
|
+
# Returns +true+ if the log level allows entries with severity
|
495
|
+
# Logger::DEBUG to be written, +false+ otherwise.
|
496
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level].
|
497
|
+
#
|
498
|
+
# @return [Boolean]
|
499
|
+
#
|
500
|
+
# source://logger/lib/logger.rb#482
|
501
|
+
def debug?; end
|
502
|
+
|
503
|
+
# Equivalent to calling #add with severity <tt>Logger::ERROR</tt>.
|
504
|
+
#
|
505
|
+
# source://logger/lib/logger.rb#713
|
506
|
+
def error(progname = T.unsafe(nil), &block); end
|
507
|
+
|
508
|
+
# Sets the log level to Logger::ERROR.
|
509
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level].
|
510
|
+
#
|
511
|
+
# source://logger/lib/logger.rb#520
|
512
|
+
def error!; end
|
513
|
+
|
514
|
+
# Returns +true+ if the log level allows entries with severity
|
515
|
+
# Logger::ERROR to be written, +false+ otherwise.
|
516
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level].
|
517
|
+
#
|
518
|
+
# @return [Boolean]
|
519
|
+
#
|
520
|
+
# source://logger/lib/logger.rb#515
|
521
|
+
def error?; end
|
522
|
+
|
523
|
+
# Equivalent to calling #add with severity <tt>Logger::FATAL</tt>.
|
524
|
+
#
|
525
|
+
# source://logger/lib/logger.rb#719
|
526
|
+
def fatal(progname = T.unsafe(nil), &block); end
|
527
|
+
|
528
|
+
# Sets the log level to Logger::FATAL.
|
529
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level].
|
530
|
+
#
|
531
|
+
# source://logger/lib/logger.rb#531
|
532
|
+
def fatal!; end
|
533
|
+
|
534
|
+
# Returns +true+ if the log level allows entries with severity
|
535
|
+
# Logger::FATAL to be written, +false+ otherwise.
|
536
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level].
|
537
|
+
#
|
538
|
+
# @return [Boolean]
|
539
|
+
#
|
540
|
+
# source://logger/lib/logger.rb#526
|
541
|
+
def fatal?; end
|
542
|
+
|
543
|
+
# Sets or retrieves the logger entry formatter proc.
|
544
|
+
#
|
545
|
+
# When +formatter+ is +nil+, the logger uses Logger::Formatter.
|
546
|
+
#
|
547
|
+
# When +formatter+ is a proc, a new entry is formatted by the proc,
|
548
|
+
# which is called with four arguments:
|
549
|
+
#
|
550
|
+
# - +severity+: The severity of the entry.
|
551
|
+
# - +time+: A Time object representing the entry's timestamp.
|
552
|
+
# - +progname+: The program name for the entry.
|
553
|
+
# - +msg+: The message for the entry (string or string-convertible object).
|
554
|
+
#
|
555
|
+
# The proc should return a string containing the formatted entry.
|
556
|
+
#
|
557
|
+
# This custom formatter uses
|
558
|
+
# {String#dump}[https://docs.ruby-lang.org/en/master/String.html#method-i-dump]
|
559
|
+
# to escape the message string:
|
560
|
+
#
|
561
|
+
# logger = Logger.new($stdout, progname: 'mung')
|
562
|
+
# original_formatter = logger.formatter || Logger::Formatter.new
|
563
|
+
# logger.formatter = proc { |severity, time, progname, msg|
|
564
|
+
# original_formatter.call(severity, time, progname, msg.dump)
|
565
|
+
# }
|
566
|
+
# logger.add(Logger::INFO, "hello \n ''")
|
567
|
+
# logger.add(Logger::INFO, "\f\x00\xff\\\"")
|
568
|
+
#
|
569
|
+
# Output:
|
570
|
+
#
|
571
|
+
# I, [2022-05-13T13:16:29.637488 #8492] INFO -- mung: "hello \n ''"
|
572
|
+
# I, [2022-05-13T13:16:29.637610 #8492] INFO -- mung: "\f\x00\xFF\\\""
|
573
|
+
#
|
574
|
+
# source://logger/lib/logger.rb#473
|
575
|
+
def formatter; end
|
576
|
+
|
577
|
+
# Sets or retrieves the logger entry formatter proc.
|
578
|
+
#
|
579
|
+
# When +formatter+ is +nil+, the logger uses Logger::Formatter.
|
580
|
+
#
|
581
|
+
# When +formatter+ is a proc, a new entry is formatted by the proc,
|
582
|
+
# which is called with four arguments:
|
583
|
+
#
|
584
|
+
# - +severity+: The severity of the entry.
|
585
|
+
# - +time+: A Time object representing the entry's timestamp.
|
586
|
+
# - +progname+: The program name for the entry.
|
587
|
+
# - +msg+: The message for the entry (string or string-convertible object).
|
588
|
+
#
|
589
|
+
# The proc should return a string containing the formatted entry.
|
590
|
+
#
|
591
|
+
# This custom formatter uses
|
592
|
+
# {String#dump}[https://docs.ruby-lang.org/en/master/String.html#method-i-dump]
|
593
|
+
# to escape the message string:
|
594
|
+
#
|
595
|
+
# logger = Logger.new($stdout, progname: 'mung')
|
596
|
+
# original_formatter = logger.formatter || Logger::Formatter.new
|
597
|
+
# logger.formatter = proc { |severity, time, progname, msg|
|
598
|
+
# original_formatter.call(severity, time, progname, msg.dump)
|
599
|
+
# }
|
600
|
+
# logger.add(Logger::INFO, "hello \n ''")
|
601
|
+
# logger.add(Logger::INFO, "\f\x00\xff\\\"")
|
602
|
+
#
|
603
|
+
# Output:
|
604
|
+
#
|
605
|
+
# I, [2022-05-13T13:16:29.637488 #8492] INFO -- mung: "hello \n ''"
|
606
|
+
# I, [2022-05-13T13:16:29.637610 #8492] INFO -- mung: "\f\x00\xFF\\\""
|
607
|
+
#
|
608
|
+
# source://logger/lib/logger.rb#473
|
609
|
+
def formatter=(_arg0); end
|
610
|
+
|
611
|
+
# Equivalent to calling #add with severity <tt>Logger::INFO</tt>.
|
612
|
+
#
|
613
|
+
# source://logger/lib/logger.rb#701
|
614
|
+
def info(progname = T.unsafe(nil), &block); end
|
615
|
+
|
616
|
+
# Sets the log level to Logger::INFO.
|
617
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level].
|
618
|
+
#
|
619
|
+
# source://logger/lib/logger.rb#498
|
620
|
+
def info!; end
|
621
|
+
|
622
|
+
# Returns +true+ if the log level allows entries with severity
|
623
|
+
# Logger::INFO to be written, +false+ otherwise.
|
624
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level].
|
625
|
+
#
|
626
|
+
# @return [Boolean]
|
627
|
+
#
|
628
|
+
# source://logger/lib/logger.rb#493
|
629
|
+
def info?; end
|
630
|
+
|
631
|
+
# Logging severity threshold (e.g. <tt>Logger::INFO</tt>).
|
632
|
+
#
|
633
|
+
# source://logger/lib/logger.rb#383
|
634
|
+
def level; end
|
635
|
+
|
636
|
+
# Sets the log level; returns +severity+.
|
637
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level].
|
638
|
+
#
|
639
|
+
# Argument +severity+ may be an integer, a string, or a symbol:
|
640
|
+
#
|
641
|
+
# logger.level = Logger::ERROR # => 3
|
642
|
+
# logger.level = 3 # => 3
|
643
|
+
# logger.level = 'error' # => "error"
|
644
|
+
# logger.level = :error # => :error
|
645
|
+
#
|
646
|
+
# Logger#sev_threshold= is an alias for Logger#level=.
|
647
|
+
#
|
648
|
+
# source://logger/lib/logger.rb#399
|
649
|
+
def level=(severity); end
|
650
|
+
|
651
|
+
# Creates a log entry, which may or may not be written to the log,
|
652
|
+
# depending on the entry's severity and on the log level.
|
653
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level]
|
654
|
+
# and {Entries}[rdoc-ref:Logger@Entries] for details.
|
655
|
+
#
|
656
|
+
# Examples:
|
657
|
+
#
|
658
|
+
# logger = Logger.new($stdout, progname: 'mung')
|
659
|
+
# logger.add(Logger::INFO)
|
660
|
+
# logger.add(Logger::ERROR, 'No good')
|
661
|
+
# logger.add(Logger::ERROR, 'No good', 'gnum')
|
662
|
+
#
|
663
|
+
# Output:
|
664
|
+
#
|
665
|
+
# I, [2022-05-12T16:25:31.469726 #36328] INFO -- mung: mung
|
666
|
+
# E, [2022-05-12T16:25:55.349414 #36328] ERROR -- mung: No good
|
667
|
+
# E, [2022-05-12T16:26:35.841134 #36328] ERROR -- gnum: No good
|
668
|
+
#
|
669
|
+
# These convenience methods have implicit severity:
|
670
|
+
#
|
671
|
+
# - #debug.
|
672
|
+
# - #info.
|
673
|
+
# - #warn.
|
674
|
+
# - #error.
|
675
|
+
# - #fatal.
|
676
|
+
# - #unknown.
|
677
|
+
#
|
678
|
+
# source://logger/lib/logger.rb#656
|
679
|
+
def log(severity, message = T.unsafe(nil), progname = T.unsafe(nil)); end
|
680
|
+
|
681
|
+
# Program name to include in log messages.
|
682
|
+
#
|
683
|
+
# source://logger/lib/logger.rb#422
|
684
|
+
def progname; end
|
685
|
+
|
686
|
+
# Program name to include in log messages.
|
687
|
+
#
|
688
|
+
# source://logger/lib/logger.rb#422
|
689
|
+
def progname=(_arg0); end
|
690
|
+
|
691
|
+
# Sets the logger's output stream:
|
692
|
+
#
|
693
|
+
# - If +logdev+ is +nil+, reopens the current output stream.
|
694
|
+
# - If +logdev+ is a filepath, opens the indicated file for append.
|
695
|
+
# - If +logdev+ is an IO stream
|
696
|
+
# (usually <tt>$stdout</tt>, <tt>$stderr</tt>, or an open File object),
|
697
|
+
# opens the stream for append.
|
698
|
+
#
|
699
|
+
# Example:
|
700
|
+
#
|
701
|
+
# logger = Logger.new('t.log')
|
702
|
+
# logger.add(Logger::ERROR, 'one')
|
703
|
+
# logger.close
|
704
|
+
# logger.add(Logger::ERROR, 'two') # Prints 'log writing failed. closed stream'
|
705
|
+
# logger.reopen
|
706
|
+
# logger.add(Logger::ERROR, 'three')
|
707
|
+
# logger.close
|
708
|
+
# File.readlines('t.log')
|
709
|
+
# # =>
|
710
|
+
# # ["# Logfile created on 2022-05-12 14:21:19 -0500 by logger.rb/v1.5.0\n",
|
711
|
+
# # "E, [2022-05-12T14:21:27.596726 #22428] ERROR -- : one\n",
|
712
|
+
# # "E, [2022-05-12T14:23:05.847241 #22428] ERROR -- : three\n"]
|
713
|
+
#
|
714
|
+
# source://logger/lib/logger.rb#624
|
715
|
+
def reopen(logdev = T.unsafe(nil)); end
|
716
|
+
|
717
|
+
# Logging severity threshold (e.g. <tt>Logger::INFO</tt>).
|
718
|
+
#
|
719
|
+
# source://logger/lib/logger.rb#383
|
720
|
+
def sev_threshold; end
|
721
|
+
|
722
|
+
# Sets the log level; returns +severity+.
|
723
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level].
|
724
|
+
#
|
725
|
+
# Argument +severity+ may be an integer, a string, or a symbol:
|
726
|
+
#
|
727
|
+
# logger.level = Logger::ERROR # => 3
|
728
|
+
# logger.level = 3 # => 3
|
729
|
+
# logger.level = 'error' # => "error"
|
730
|
+
# logger.level = :error # => :error
|
731
|
+
#
|
732
|
+
# Logger#sev_threshold= is an alias for Logger#level=.
|
733
|
+
#
|
734
|
+
# source://logger/lib/logger.rb#399
|
735
|
+
def sev_threshold=(severity); end
|
736
|
+
|
737
|
+
# Equivalent to calling #add with severity <tt>Logger::UNKNOWN</tt>.
|
738
|
+
#
|
739
|
+
# source://logger/lib/logger.rb#725
|
740
|
+
def unknown(progname = T.unsafe(nil), &block); end
|
741
|
+
|
742
|
+
# Equivalent to calling #add with severity <tt>Logger::WARN</tt>.
|
743
|
+
#
|
744
|
+
# source://logger/lib/logger.rb#707
|
745
|
+
def warn(progname = T.unsafe(nil), &block); end
|
746
|
+
|
747
|
+
# Sets the log level to Logger::WARN.
|
748
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level].
|
749
|
+
#
|
750
|
+
# source://logger/lib/logger.rb#509
|
751
|
+
def warn!; end
|
752
|
+
|
753
|
+
# Returns +true+ if the log level allows entries with severity
|
754
|
+
# Logger::WARN to be written, +false+ otherwise.
|
755
|
+
# See {Log Level}[rdoc-ref:Logger@Log+Level].
|
756
|
+
#
|
757
|
+
# @return [Boolean]
|
758
|
+
#
|
759
|
+
# source://logger/lib/logger.rb#504
|
760
|
+
def warn?; end
|
761
|
+
|
762
|
+
# Adjust the log level during the block execution for the current Fiber only
|
763
|
+
#
|
764
|
+
# logger.with_level(:debug) do
|
765
|
+
# logger.debug { "Hello" }
|
766
|
+
# end
|
767
|
+
#
|
768
|
+
# source://logger/lib/logger.rb#408
|
769
|
+
def with_level(severity); end
|
770
|
+
|
771
|
+
private
|
772
|
+
|
773
|
+
# source://logger/lib/logger.rb#754
|
774
|
+
def format_message(severity, datetime, progname, msg); end
|
775
|
+
|
776
|
+
# source://logger/lib/logger.rb#745
|
777
|
+
def format_severity(severity); end
|
778
|
+
|
779
|
+
# Guarantee the existence of this ivar even when subclasses don't call the superclass constructor.
|
780
|
+
#
|
781
|
+
# source://logger/lib/logger.rb#750
|
782
|
+
def level_override; end
|
783
|
+
end
|
784
|
+
|
785
|
+
# Default formatter for log messages.
|
786
|
+
#
|
787
|
+
# source://logger/lib/logger/formatter.rb#5
|
788
|
+
class Logger::Formatter
|
789
|
+
# @return [Formatter] a new instance of Formatter
|
790
|
+
#
|
791
|
+
# source://logger/lib/logger/formatter.rb#11
|
792
|
+
def initialize; end
|
793
|
+
|
794
|
+
# source://logger/lib/logger/formatter.rb#15
|
795
|
+
def call(severity, time, progname, msg); end
|
796
|
+
|
797
|
+
# Returns the value of attribute datetime_format.
|
798
|
+
#
|
799
|
+
# source://logger/lib/logger/formatter.rb#9
|
800
|
+
def datetime_format; end
|
801
|
+
|
802
|
+
# Sets the attribute datetime_format
|
803
|
+
#
|
804
|
+
# @param value the value to set the attribute datetime_format to.
|
805
|
+
#
|
806
|
+
# source://logger/lib/logger/formatter.rb#9
|
807
|
+
def datetime_format=(_arg0); end
|
808
|
+
|
809
|
+
private
|
810
|
+
|
811
|
+
# source://logger/lib/logger/formatter.rb#21
|
812
|
+
def format_datetime(time); end
|
813
|
+
|
814
|
+
# source://logger/lib/logger/formatter.rb#25
|
815
|
+
def msg2str(msg); end
|
816
|
+
end
|
817
|
+
|
818
|
+
# source://logger/lib/logger/formatter.rb#7
|
819
|
+
Logger::Formatter::DatetimeFormat = T.let(T.unsafe(nil), String)
|
820
|
+
|
821
|
+
# source://logger/lib/logger/formatter.rb#6
|
822
|
+
Logger::Formatter::Format = T.let(T.unsafe(nil), String)
|
823
|
+
|
824
|
+
# Device used for logging messages.
|
825
|
+
#
|
826
|
+
# source://logger/lib/logger/log_device.rb#7
|
827
|
+
class Logger::LogDevice
|
828
|
+
include ::Logger::Period
|
829
|
+
include ::MonitorMixin
|
830
|
+
|
831
|
+
# @return [LogDevice] a new instance of LogDevice
|
832
|
+
#
|
833
|
+
# source://logger/lib/logger/log_device.rb#14
|
834
|
+
def initialize(log = T.unsafe(nil), shift_age: T.unsafe(nil), shift_size: T.unsafe(nil), shift_period_suffix: T.unsafe(nil), binmode: T.unsafe(nil), reraise_write_errors: T.unsafe(nil)); end
|
835
|
+
|
836
|
+
# source://logger/lib/logger/log_device.rb#59
|
837
|
+
def close; end
|
838
|
+
|
839
|
+
# Returns the value of attribute dev.
|
840
|
+
#
|
841
|
+
# source://logger/lib/logger/log_device.rb#10
|
842
|
+
def dev; end
|
843
|
+
|
844
|
+
# Returns the value of attribute filename.
|
845
|
+
#
|
846
|
+
# source://logger/lib/logger/log_device.rb#11
|
847
|
+
def filename; end
|
848
|
+
|
849
|
+
# source://logger/lib/logger/log_device.rb#69
|
850
|
+
def reopen(log = T.unsafe(nil)); end
|
851
|
+
|
852
|
+
# source://logger/lib/logger/log_device.rb#32
|
853
|
+
def write(message); end
|
854
|
+
|
855
|
+
private
|
856
|
+
|
857
|
+
# source://logger/lib/logger/log_device.rb#126
|
858
|
+
def add_log_header(file); end
|
859
|
+
|
860
|
+
# source://logger/lib/logger/log_device.rb#132
|
861
|
+
def check_shift_log; end
|
862
|
+
|
863
|
+
# source://logger/lib/logger/log_device.rb#110
|
864
|
+
def create_logfile(filename); end
|
865
|
+
|
866
|
+
# source://logger/lib/logger/log_device.rb#152
|
867
|
+
def lock_shift_log; end
|
868
|
+
|
869
|
+
# source://logger/lib/logger/log_device.rb#102
|
870
|
+
def open_logfile(filename); end
|
871
|
+
|
872
|
+
# source://logger/lib/logger/log_device.rb#86
|
873
|
+
def set_dev(log); end
|
874
|
+
|
875
|
+
# source://logger/lib/logger/log_device.rb#183
|
876
|
+
def shift_log_age; end
|
877
|
+
|
878
|
+
# source://logger/lib/logger/log_device.rb#195
|
879
|
+
def shift_log_period(period_end); end
|
880
|
+
end
|
881
|
+
|
882
|
+
# source://logger/lib/logger/period.rb#4
|
883
|
+
module Logger::Period
|
884
|
+
private
|
885
|
+
|
886
|
+
# source://logger/lib/logger/period.rb#9
|
887
|
+
def next_rotate_time(now, shift_age); end
|
888
|
+
|
889
|
+
# source://logger/lib/logger/period.rb#31
|
890
|
+
def previous_period_end(now, shift_age); end
|
891
|
+
|
892
|
+
class << self
|
893
|
+
# source://logger/lib/logger/period.rb#9
|
894
|
+
def next_rotate_time(now, shift_age); end
|
895
|
+
|
896
|
+
# source://logger/lib/logger/period.rb#31
|
897
|
+
def previous_period_end(now, shift_age); end
|
898
|
+
end
|
899
|
+
end
|
900
|
+
|
901
|
+
# source://logger/lib/logger/period.rb#7
|
902
|
+
Logger::Period::SiD = T.let(T.unsafe(nil), Integer)
|
903
|
+
|
904
|
+
# \Severity label for logging (max 5 chars).
|
905
|
+
#
|
906
|
+
# source://logger/lib/logger.rb#743
|
907
|
+
Logger::SEV_LABEL = T.let(T.unsafe(nil), Array)
|
908
|
+
|
909
|
+
# Logging severity.
|
910
|
+
#
|
911
|
+
# source://logger/lib/logger/severity.rb#5
|
912
|
+
module Logger::Severity
|
913
|
+
class << self
|
914
|
+
# source://logger/lib/logger/severity.rb#29
|
915
|
+
def coerce(severity); end
|
916
|
+
end
|
917
|
+
end
|
918
|
+
|
919
|
+
# source://logger/lib/logger/severity.rb#19
|
920
|
+
Logger::Severity::LEVELS = T.let(T.unsafe(nil), Hash)
|