poshbotio / PoshBot

Powershell-based bot framework
MIT License
540 stars 108 forks source link

Schedules.psd1 not found #190

Closed mvanders closed 4 years ago

mvanders commented 4 years ago

Expected Behavior

Current Behavior

When I start PoshBot, I get the following messages:

WARNING: {"DataTime":"2019-11-18 14:10:46Z","Class":"StorageProvider","Method":"GetConfig","Severity":"Warning","LogLevel":"Info","Message":"Configuration file [C:\Users\MV\.poshbot\plugins.psd1] not found","Data":{}} WARNING: {"DataTime":"2019-11-18 14:10:46Z","Class":"StorageProvider","Method":"GetConfig","Severity":"Warning","LogLevel":"Info","Message":"Configuration file [C:\Users\MV\.poshbot\plugins.psd1] not found","Data":{}} WARNING: {"DataTime":"2019-11-18 14:10:47Z","Class":"PluginManager","Method":"GetPluginConfig","Severity":"Warning","LogLevel":"Debug","Message":"No plugin configuration defined in storage","Data":{}} WARNING: {"DataTime":"2019-11-18 14:10:47Z","Class":"RoleManager","Method":"AddPermission","Severity":"Warning","LogLevel":"Info","Message":"Permission [manage-plugins] is already loaded","Data":{}} WARNING: {"DataTime":"2019-11-18 14:10:47Z","Class":"RoleManager","Method":"AddPermission","Severity":"Warning","LogLevel":"Info","Message":"Permission [view-role] is already loaded","Data":{}} WARNING: {"DataTime":"2019-11-18 14:10:47Z","Class":"RoleManager","Method":"AddPermission","Severity":"Warning","LogLevel":"Info","Message":"Permission [manage-permissions] is already loaded","Data":{}} WARNING: {"DataTime":"2019-11-18 14:10:47Z","Class":"RoleManager","Method":"AddPermission","Severity":"Warning","LogLevel":"Info","Message":"Permission [view] is already loaded","Data":{}} WARNING: {"DataTime":"2019-11-18 14:10:47Z","Class":"RoleManager","Method":"AddPermission","Severity":"Warning","LogLevel":"Info","Message":"Permission [view-group] is already loaded","Data":{}} WARNING: {"DataTime":"2019-11-18 14:10:47Z","Class":"RoleManager","Method":"AddPermission","Severity":"Warning","LogLevel":"Info","Message":"Permissionon [manage-groups] is already loaded","Data":{}} WARNING: {"DataTime":"2019-11-18 14:10:47Z","Class":"RoleManager","Method":"AddPermission","Severity":"Warning","LogLevel":"Info","Message":"Permissionon [manage-roles] is already loaded","Data":{}} WARNING: {"DataTime":"2019-11-18 14:10:47Z","Class":"RoleManager","Method":"AddPermission","Severity":"Warning","LogLevel":"Info","Message":"Permissionon [manage-schedules] is already loaded","Data":{}} WARNING: {"DataTime":"2019-11-18 14:10:47Z","Class":"RoleManager","Method":"AddPermission","Severity":"Warning","LogLevel":"Info","Message":"Permissionon [show-help] is already loaded","Data":{}} WARNING: {"DataTime":"2019-11-18 14:10:48Z","Class":"StorageProvider","Method":"GetConfig","Severity":"Warning","LogLevel":"Info","Message":"Configuratation file [C:\Users\MV\.poshbot\schedules.psd1] not found","Data":{}}

Possible Solution

Steps to Reproduce (for bugs)

Context

Your Environment

devblackops commented 4 years ago

Hey @mvanders,

Schedules.psd1 will only exist if you've scheduled a command to run via the builtin command New-PoshBotScheduledCommand. If you do that, then an entry will be created in the file. This is so previously scheduled commands are registered again if the bot is restarted.

It's perfectly fine for it to issue this warning if no scheduled commands exist. Maybe we should change to this an Info message to avoid any confusion.

stale[bot] commented 4 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.