Bot
bot
¤
Modules:
Name | Description |
---|---|
base |
|
channels |
|
converters |
|
errors |
|
plots |
|
utils |
|
Functions:
Name | Description |
---|---|
on_ready |
|
on_guild_join |
|
on_command_error |
|
start |
|
Attributes:
Name | Type | Description |
---|---|---|
intents |
|
|
bot |
|
bot
module-attribute
¤
base
¤
channels
¤
Attributes:
Name | Type | Description |
---|---|---|
channels |
|
_Channels
¤
Methods:
Name | Description |
---|---|
init |
|
Attributes:
Name | Type | Description |
---|---|---|
debug |
TextChannel
|
|
price_alert |
TextChannel
|
|
converters
¤
Classes:
Name | Description |
---|---|
AirportCvtr |
|
MultiAirportCvtr |
|
AircraftCvtr |
|
SettingValueCvtr |
|
TPDCvtr |
|
CfgAlgCvtr |
|
ConstraintCvtr |
|
PriceCvtr |
|
Functions:
Name | Description |
---|---|
acro_cast |
|
AirportCvtr
¤
MultiAirportCvtr
¤
AircraftCvtr
¤
_ACROptions
¤
Bases: BaseModel
Attributes:
Name | Type | Description |
---|---|---|
algorithm_pax |
PyConfigAlgorithmPax
|
|
algorithm_cargo |
PyConfigAlgorithmCargo
|
|
max_distance |
PyACROptionsMaxDistance
|
|
max_flight_time |
timedelta
|
|
trips_per_day_per_ac |
PyACROptionsTripsPerDayPerAC
|
|
_SettingKeyCustom
¤
SettingValueCvtr
¤
TPDCvtr
¤
CfgAlgCvtr
¤
ConstraintCvtr
¤
_Price
¤
PriceCvtr
¤
errors
¤
Classes:
Attributes:
Name | Type | Description |
---|---|---|
COLOUR_ERROR |
|
|
Suggestions |
|
AircraftNotFoundError
¤
AircraftNotFoundError(acsr: SearchResult)
AirportNotFoundError
¤
AirportNotFoundError(apsr: SearchResult)
TooManyAirportsError
¤
ValidationErrorBase
¤
ValidationErrorBase(
err: ValidationError | PydanticCustomError,
)
SettingValueValidationError
¤
SettingValueValidationError(
err: ValidationError | PydanticCustomError,
)
TPDValidationError
¤
TPDValidationError(
err: ValidationError | PydanticCustomError,
)
CfgAlgValidationError
¤
CfgAlgValidationError(
err: ValidationError | PydanticCustomError,
)
ConstraintValidationError
¤
ConstraintValidationError(
err: ValidationError | PydanticCustomError,
)
PriceValidationError
¤
PriceValidationError(
err: ValidationError | PydanticCustomError,
)
UserBannedError
¤
Bases: BadArgument
OutsideMainServerError
¤
Bases: CheckFailure
CustomErrHandler
¤
CustomErrHandler(
ctx: Context,
error: CommandError = CommandError(),
cmd: str | None = None,
)
Methods:
Attributes:
Name | Type | Description |
---|---|---|
ctx |
|
|
error |
|
|
cmd |
|
|
handled |
|
|
err_tb |
str
|
|
plots
¤
Classes:
Name | Description |
---|---|
MPLMap |
|
Attributes:
Name | Type | Description |
---|---|---|
mpl_map |
|
MPLMap
¤
MPLMap()
Methods:
Name | Description |
---|---|
plot_destinations |
|
Attributes:
Name | Type | Description |
---|---|---|
transformer |
|
|
cmap |
|
|
cmap2 |
|
transformer
instance-attribute
¤
transformer = from_crs(
4326,
from_string("+proj=peirce_q +lon_0=25 +shape=square"),
)
utils
¤
Functions:
Name | Description |
---|---|
fetch_user_info |
|
get_user_colour |
|
format_flight_time |
|
format_ap_short |
|
format_demand |
|
format_config |
|
format_ticket |
|
format_modifiers |
|
format_warning |
|
format_num |
|
main_server_only |
|
Attributes:
HELP_TPD
module-attribute
¤
HELP_TPD = "**Number of departures per day, per aircraft**\n- if not provided or set to `AUTO`, the bot will attempt to maximise it.\n- if you provide a number, the bot will try to assign more aircraft to the same route to avoid wasting demand.\n - to disable the cramming, append a `!` at the end (not recommended)."
HELP_CFG_ALG
module-attribute
¤
HELP_CFG_ALG = f'**Configuration Algorithm**
- {join(f''`'{c}'`'' for c in __members__)} (pax)
- {join(f''`'{c}'`'' for c in __members__)} (cargo)
The best algorithm is picked automatically depending on the route distance.
`YJF` here denotes the order of priority when filling seats.'
HELP_SETTING_KEY
module-attribute
¤
HELP_SETTING_KEY = f'**The setting key** - some important ones are:
- `fourx`: {HELP_U_FOURX}
- `income_loss_tol`: {HELP_U_INCOME_LOSS_TOL}
- `load` and `cargo_load`: {HELP_U_LOAD}
'