Commit Graph

18 Commits

Author SHA1 Message Date
nevimer
356efbfb3e Public Logging Update (#1545)
Use Regex to be smarter.

<!-- Write **BELOW** The Headers and **ABOVE** The comments else it may
not be viewable. -->
<!-- You can view Contributing.MD for a detailed description of the pull
request process. -->

## About The Pull Request

Public logging finds ckeys via regex to remove them from lines now. Not
used for player say, at the moment. Not needed there either, as ckeys
are only used by key_name() and thats passed down as a string. rather
than just edit every instance of the proc, ill just regex them out by
adding identifiers into the ckey blocks in logs and snip them that way.

<!-- Please make sure to actually test your PRs. If you have not tested
your PR mention it. -->

## Why It's Good For The Game

Public logs are little more private. We want them only to have
characters, no keys.

## Proof Of Testing

<!-- Compile and run your code locally. Make sure it works. This is the
place to show off your changes! We are not responsible for testing your
features. -->

## Changelog

<!-- If your PR modifies aspects of the game that can be concretely
observed by players or admins you should add a changelog. If your change
does NOT meet this description, remove this section. Be sure to properly
mark your PRs to prevent unnecessary GBP loss. You can read up on GBP
and it's effects on PRs in the tgstation guides for contributors. Please
note that maintainers freely reserve the right to remove and add tags
should they deem it appropriate. You can attempt to finagle the system
all you want, but it's best to shoot for clear communication right off
the bat. -->

🆑
refactor: public logging uses regex for cases of mechanics now. 
/🆑

<!-- Both 🆑's are required for the changelog to work! You can put
your name to the right of the first 🆑 if you want to overwrite your
GitHub username as author ingame. -->
<!-- You can use multiple of the same prefix (they're only used for the
icon ingame) and delete the unneeded ones. Despite some of the tags,
changelogs should generally represent how a player might be affected by
the changes rather than a summary of the PR's contents. -->

<!-- By opening a pull request. You have read and understood the
repository rules located on the main README.md on this project. -->

Co-authored-by: Waterpig <49160555+Majkl-J@users.noreply.github.com>
2024-11-25 18:54:51 -05:00
Waterpig
5da11912cb Merge branch 'master' of https://github.com/Skyrat-SS13/Skyrat-tg into upstream-2406a 2024-06-02 10:40:19 +02:00
SkyratBot
8e17d80198 [MIRROR] Moves as many db related date/time operations to the db side to avoid byond bugs with dates and times. (#27694)
* Moves as many db related date/time operations to the db side to avoid byond bugs with dates and times.

* Update blackbox.dm

* SQLtime to ISOtime

---------

Co-authored-by: Kyle Spier-Swenson <kyleshome@gmail.com>
Co-authored-by: SpaceLoveSs13 <68121607+SpaceLoveSs13@users.noreply.github.com>
2024-05-23 03:09:51 +02:00
Waterpig
7a8fe64633 Merge branch 'master' of https://github.com/Skyrat-SS13/Skyrat-tg into skyrat-upstream-04 2024-04-30 13:57:15 +02:00
SkyratBot
93b00b51d6 [MIRROR] Adds handy define that enables the most common configuration of reftracking (#27461)
* Adds handy define that enables the most common configuration of reftracking (#82860)

## About The Pull Request

This shit has confused people too many times, let's give them an easy
pathway to use reftracking

Also split the separate logging bit into its own thing

* Adds handy define that enables the most common configuration of reftracking

---------

Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
2024-04-29 23:48:03 +01:00
nevimer
4e081a1d9d Public Logging (#1203)
<!-- Write **BELOW** The Headers and **ABOVE** The comments else it may
not be viewable. -->
<!-- You can view Contributing.MD for a detailed description of the pull
request process. -->

## About The Pull Request

Gives the players a redacted version of the logs, ckeys filtered out for
public logging purposes.

<!-- Please make sure to actually test your PRs. If you have not tested
your PR mention it. -->

## Why It's Good For The Game

You can prove your cases in ahelps and appeals, reports, easier. 

## Proof Of Testing


![notepad_SbY9NX8Shd](https://github.com/Bubberstation/Bubberstation/assets/77420409/88c310dc-350e-4da8-b4c1-f93efff5a560)


## Changelog

<!-- If your PR modifies aspects of the game that can be concretely
observed by players or admins you should add a changelog. If your change
does NOT meet this description, remove this section. Be sure to properly
mark your PRs to prevent unnecessary GBP loss. You can read up on GBP
and it's effects on PRs in the tgstation guides for contributors. Please
note that maintainers freely reserve the right to remove and add tags
should they deem it appropriate. You can attempt to finagle the system
all you want, but it's best to shoot for clear communication right off
the bat. -->

🆑
admin: added public log folder, and logging. 
/🆑

<!-- Both 🆑's are required for the changelog to work! You can put
your name to the right of the first 🆑 if you want to overwrite your
GitHub username as author ingame. -->
<!-- You can use multiple of the same prefix (they're only used for the
icon ingame) and delete the unneeded ones. Despite some of the tags,
changelogs should generally represent how a player might be affected by
the changes rather than a summary of the PR's contents. -->

<!-- By opening a pull request. You have read and understood the
repository rules located on the main README.md on this project. -->

---------

Co-authored-by: projectkepler-RU <99981766+projectkepler-ru@users.noreply.github.com>
Co-authored-by: Waterpig <49160555+Majkl-J@users.noreply.github.com>
2024-04-06 18:58:02 -04:00
SkyratBot
738c5772f3 [MIRROR] Records Blackbox Feedback on Items used to Suicide [MDB IGNORE] (#25590)
* Records Blackbox Feedback on Items used to Suicide

* Update _logging.dm

---------

Co-authored-by: san7890 <the@san7890.com>
Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com>
2023-12-13 13:57:43 +00:00
SkyratBot
1885856425 [MIRROR] Adds Mob Tag data to log messages + player panel [MDB IGNORE] (#25366)
* Adds Mob Tag data to log messages + player panel

* Update _logging.dm

---------

Co-authored-by: san7890 <the@san7890.com>
Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com>
2023-12-03 02:07:16 -05:00
SkyratBot
7cf7be4b7b [MIRROR] Tram v6/Transport Subsystem [MDB IGNORE] (#24399)
* Tram v6/Transport Subsystem

* Update icon_smoothing.dm

* Update utility.dm

* defines/icon

* Update airlock.dm

* Update door.dm

* Update airlock.dm

* Update airlock.dm

---------

Co-authored-by: lessthanthree <83487515+lessthnthree@users.noreply.github.com>
2023-10-17 15:16:46 -07:00
SkyratBot
649c250702 [MIRROR] JSON Logging Take Two [MDB IGNORE] (#21329)
* JSON Logging Take Two

* Fixes the conflicts and makes our logs all comply with the new logging framework, hopefully.

---------

Co-authored-by: Zephyr <12817816+ZephyrTFA@users.noreply.github.com>
Co-authored-by: GoldenAlpharex <jerego1234@hotmail.com>
2023-05-28 18:10:07 -04:00
Tom
6435018ba7 Add logging for manually changing your targeted zone (#72814) (#20787)
* Add logging for manually changing your targeted zone (#72814)

See title.
Surgery hud is exempt from this.

Requested by @Mothblocks

Signed-off-by: GitHub <noreply@github.com>
Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
Co-authored-by: dragomagol <66640614+dragomagol@users.noreply.github.com>

* Delete 

---------

Signed-off-by: GitHub <noreply@github.com>
Co-authored-by: Zephyr <12817816+ZephyrTFA@users.noreply.github.com>
Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
Co-authored-by: dragomagol <66640614+dragomagol@users.noreply.github.com>
2023-04-26 10:44:01 -07:00
SkyratBot
bf784520b8 [MIRROR] Handles Log_Globally Being True When Log Type is LOG_VICTIM [MDB IGNORE] (#18663)
* Handles Log_Globally Being True When Log Type is LOG_VICTIM (#72643)

## About The Pull Request

Victim procs would cause a [runtime, click on me for a link to the
runtimebus
entry](https://runtimes.moth.fans/runtime/Invalid%20individual%20logging%20type%3A%20524288.%20Defaulting%20to%204096%20(LOG_GAME).%20(code%2F__HELPERS%2Flogging%2F_logging.dm%3A120)_______%2Fproc%2F_stack_trace)
when you tried to put a victim log in globally. This was the runtime
error for future reference, via
https://tgstation13.download/parsed-logs/manuel/data/logs/2023/01/06/round-197717/runtime.condensed.txt
-

```
The following runtime has occurred 3155 time(s).
runtime error: Invalid individual logging type: 524288. Defaulting to 4096 (LOG_GAME). (code/__HELPERS/logging/_logging.dm:120)
proc name:  stack trace (/proc/_stack_trace)
  source file: stack_trace.dm,4
  usr: 0
  src: null
```

`524288` is the bitflag for `LOG_VICTIM`.

I added in a custom error message for passing in LOG_VICTIM without
adding log_globally just so that we can pick up on it faster without
having to look up the bitflags. I think I prefer it failing loudly as
opposed to just returning, so that people can much more easily pick up
on this behavior being a wrong one. The pattern across the codebase
prior to this PR was pass in log_globally as false along with LOG_VICTIM
in the args to `log_message()`, so I decided to enforce doing that in
this PR. Alternative fix could be to just early return on LOG_VICTIM,
but that would leave a larger footprint and might be better suited for a
different PR, preferably after this one at least gets all of our ducks
in a row.
## Why It's Good For The Game

runtimes bad, actual logging of important stuff good.

apologies if i screwed up how LOG_VICTIM is meant to be used, but
something is definitely wrong and should be addressed. i'm pretty sure
victim logs are only done in addition to a proper log that gets sent
globally, and this is good just for visibility?
## Changelog
Nothing that players would notice.

* Handles Log_Globally Being True When Log Type is LOG_VICTIM

Co-authored-by: san7890 <the@san7890.com>
2023-01-12 12:15:49 -08:00
SkyratBot
a8c10d1659 [MIRROR] Converts a shitload of istypes to their more concise macros [MDB IGNORE] (#15702)
Converts a shitload of istypes to their more concise macros

Co-authored-by: Seth Scherer <supernovaa41@gmx.com>
Co-authored-by: GoldenAlpharex <jerego1234@hotmail.com>
2022-08-27 16:23:44 -04:00
GoldenAlpharex
4447eb122f Fixes SQL game logs throwing a bunch of SQL errors (#15773)
* Increases the list nesting by one on log entries for the mass insert log

* Updates the name of the time column because of course I had to get it wrong :)
2022-08-25 07:12:37 +02:00
SkyratBot
def879e5b4 [MIRROR] Refactors admin PMs to be hopefully more resilient [MDB IGNORE] (#15348)
* Refactors admin PMs to be hopefully more resilient

* autoconflict resolution

Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
Co-authored-by: Gandalf <9026500+Gandalf2k15@users.noreply.github.com>
2022-08-04 15:47:52 +01:00
GoldenAlpharex
bbbe0682d8 Optimizes SQL logging and adds missing related default config entries (#15330)
* Adds a new config entry for SQL game log bundle query size

Also adds documentation to existing config entries that don't currently appear in any default entry files on the repo.

* Adds a new config file for database-related configs for Skyrat

* Adds a `add_log_to_mass_insert_queue` proc to handle bundling insert queries into bigger, less frequent queries

* Modifies log_message() to utilise the new add_log_to_mass_insert_queue() proc

* Actually makes the MassInsert() call asynchronous, to completely remove the freezes

* Adds code to handle sending all unsent logs to the database before the subsystem is shutdown, to reduce the loss of logs at the end of a round
2022-08-02 18:04:18 -04:00
SkyratBot
7a653adfbb [MIRROR] TGUI Say: Upgrades chat input with modern features [MDB IGNORE] (#14375)
* TGUI Say: Upgrades chat input with modern features

* yes

Co-authored-by: Jeremiah <42397676+jlsnow301@users.noreply.github.com>
Co-authored-by: Gandalf <9026500+Gandalf2k15@users.noreply.github.com>
2022-06-17 02:12:42 +01:00
SkyratBot
2da69ce304 [MIRROR] Split and Document Logging Procs [MDB IGNORE] (#13707)
* Split and Document Logging Procs

* Update _logging.dm

* Update atoms.dm

* Update mob_helpers.dm

* Update mob.dm

Co-authored-by: dragomagol <66640614+dragomagol@users.noreply.github.com>
Co-authored-by: Tom <8881105+tf-4@users.noreply.github.com>
2022-05-19 01:18:40 +01:00