-
-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Michael Chirlin
committed
Feb 11, 2024
1 parent
552e7a6
commit 42b1099
Showing
56 changed files
with
3,821 additions
and
4,183 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ENV=dev |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
Binary file not shown.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Binary file not shown.
File renamed without changes.
File renamed without changes.
Binary file not shown.
Binary file not shown.
File renamed without changes.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# How fast/slow the music can go | ||
SLOW_MUSIC_SPEED = 1.0 | ||
#this was 0.5 | ||
FAST_MUSIC_SPEED = 1.3 | ||
|
||
# The min and max timeframe in seconds for | ||
# the speed change to trigger, randomly selected | ||
MIN_MUSIC_FAST_TIME = 4 | ||
MAX_MUSIC_FAST_TIME = 8 | ||
MIN_MUSIC_SLOW_TIME = 10 | ||
MAX_MUSIC_SLOW_TIME = 23 | ||
|
||
END_MIN_MUSIC_FAST_TIME = 6 | ||
END_MAX_MUSIC_FAST_TIME = 10 | ||
END_MIN_MUSIC_SLOW_TIME = 8 | ||
END_MAX_MUSIC_SLOW_TIME = 12 | ||
|
||
#How long the speed change takes | ||
INTERVAL_CHANGE = 1.5 | ||
|
||
#How long the winning moves shall sparkle | ||
END_GAME_PAUSE = 8 | ||
KILL_GAME_PAUSE = 4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import logging | ||
from logging import RotatingFileHandler | ||
|
||
#TODO - Read logging level from file) | ||
|
||
# Configure logging | ||
log_formatter = logging.Formatter('%(asctime)s - %(levelname)s - %(message)s', datefmt='%Y-%m-%d %H:%M:%S') | ||
log_file = 'piparty.log' | ||
|
||
# Create a rotating file handler with a maximum file size of 1 MB and keep 3 backup copies | ||
rotating_handler = RotatingFileHandler(log_file, maxBytes=1e6, backupCount=3) | ||
rotating_handler.setFormatter(log_formatter) | ||
|
||
logging.basicConfig( | ||
level=logging.DEBUG, # Set the global logging level | ||
format='%(asctime)s - %(levelname)s - %(message)s', # Specify the log message format | ||
handlers=[ | ||
logging.StreamHandler(), # Output logs to the console | ||
rotating_handler # Output logs to a rotating log file | ||
] | ||
) | ||
|
||
logger = logging |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
[loggers] | ||
keys=root,file | ||
|
||
[handlers] | ||
keys=console,file | ||
|
||
[formatters] | ||
keys=console,file | ||
|
||
[logger_root] | ||
level=DEBUG | ||
handlers=console,file | ||
|
||
[logger_file] | ||
level=DEBUG | ||
handlers=file | ||
qualname=file | ||
|
||
[handler_console] | ||
class=StreamHandler | ||
level=DEBUG | ||
formatter=console | ||
args=(sys.stdout,) | ||
|
||
[handler_file] | ||
class=FileHandler | ||
level=DEBUG | ||
formatter=file | ||
args=('%(logfilename)s','w',) | ||
|
||
[formatter_console] | ||
format=%(asctime)s - %(levelname)s - %(name)s - %(message)s | ||
|
||
[formatter_file] | ||
format=%(asctime)s - %(levelname)s - %(name)s - %(funcName)s:%(lineno)d - %(message)s |
Oops, something went wrong.