Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1.x: Remove pool support, add env-variable configuration, upgrade peewee, uvloop #1152

Draft
wants to merge 6 commits into
base: future/1.x
Choose a base branch
from

Conversation

tomvlk
Copy link
Member

@tomvlk tomvlk commented Mar 12, 2022

Doesn't reflect in documentation yet!

Fixes #1094
Fixes #1093
Fixes #1153
Fixes #1154

Minimum Python Version: 3.10!

@tomvlk tomvlk added this to the Version 1.0.0 milestone Mar 12, 2022
@tomvlk tomvlk requested a review from TheMaximum March 12, 2022 17:39
@tomvlk tomvlk self-assigned this Mar 12, 2022
@tomvlk tomvlk changed the base branch from master to future/1.x March 12, 2022 17:40

# Owner, will be granted highest level of admin at initial start and connect.
PYPLANET_OWNER = None
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this mean that there can only be one owner?
For the Smurfs we currently have two owners: Haagse and me...

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The owner is just there to grant the initial admin rights to, then this person can give the rights to the other players in-game. @TheMaximum

# FIX for #331. Replace utf8 by utf8mb4 in the mysql driver encoding.
if conf['ENGINE'] == 'peewee_async.MySQLDatabase' and 'charset' in db_options and db_options['charset'] == 'utf8':
logging.info('Forcing to use \'utf8mb4\' instead of \'utf8\' for the MySQL charset option! (Fix #331).')
db_options['charset'] = 'utf8mb4'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The charset no longer needs to be forced?

Copy link
Member Author

@tomvlk tomvlk Mar 13, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I set the default to be this. This used to be misconfigured default on very old servers.

@@ -30,7 +30,7 @@ def get_client(cls):
if not cls.CLIENT:
cls.CLIENT = Client(
dsn='https://bcbafd2d81234d53b32c66077ae0a008:[email protected]/2',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is Sentry running again? Otherwise we might as well remove it.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's not for now, do you think it's worth it to start it again? I will upgrade it, clean it and start it if you think so.

@gitguardian
Copy link

gitguardian bot commented Mar 13, 2022

⚠️ GitGuardian has uncovered 3 secrets following the scan of your pull request.

Please consider investigating the findings and remediating the incidents. Failure to do so may lead to compromising the associated services or software components.

🔎 Detected hardcoded secrets in your pull request
GitGuardian id Secret Commit Filename
- Basic Auth String a4d688d pyplanet/utils/log.py View secret
2880307 Basic Auth String b3a1d48 pyplanet/utils/log.py View secret
2880307 Basic Auth String b3a1d48 pyplanet/utils/log.py View secret
🛠 Guidelines to remediate hardcoded secrets
  1. Understand the implications of revoking this secret by investigating where it is used in your code.
  2. Replace and store your secrets safely. Learn here the best practices.
  3. Revoke and rotate these secrets.
  4. If possible, rewrite git history. Rewriting git history is not a trivial act. You might completely break other contributing developers' workflow and you risk accidentally deleting legitimate data.

To avoid such incidents in the future consider


🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.

Our GitHub checks need improvements? Share your feedbacks!

@tomvlk tomvlk changed the title Feature/1094: Remove pool support, add env-variable configuration Feature/1094: Remove pool support, add env-variable configuration, upgrade peewee Mar 13, 2022
@tomvlk tomvlk changed the title Feature/1094: Remove pool support, add env-variable configuration, upgrade peewee 1.x: Remove pool support, add env-variable configuration, upgrade peewee Mar 13, 2022
@tomvlk tomvlk changed the title 1.x: Remove pool support, add env-variable configuration, upgrade peewee 1.x: Remove pool support, add env-variable configuration, upgrade peewee, uvloop Mar 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants