kate!
kate!
CC#
Created by kate! on 4/7/2024 in #help
Unable to use Hot Reloading
Ever since updating my project to use .NET 8.0, I haven't been able to use Hot Reloading for Views with ASP.NET Core. Initially I thought that the issue was caused by T4, but I've disabled all of that and it still doesn't work. I've attached the exception that's thrown, and I've been trying to fix this for the past couple of days. I've linked the repo below, and the project is XeniaBot.WebPanel. https://github.com/ktwrd/XeniaBot/tree/develop Weird this is that when I make changes to code, the error isn't thrown and it works perfectly fine.
1 replies
CC#
Created by kate! on 3/29/2024 in #help
✅ Unreferenced classes not being included
How I have my codebase setup for reflection is to get all types that have a specific attribute (XeniaControllerAttribute) and extend a specific class (BaseService), it then creates an instance of all of those types found and calls a method on it. When I do that, it seems like classes that aren't referenced don't get called, and aren't even included in the main project (XeniaBot.Core) when compiling. Even the breakpoint doesn't work. Currently I have the debugger broken on the method that's called on one of those classes XeniaVersionService.InitializeAsync() and it never gets called. Hell, the breakpoint doesn't even work. https://res.kate.pet/upload/dda1477d3f2e/rider64_fz1KLaArzx.png When I add a breakpoint into my function that fetches all the services to load, it doesn't show XeniaVersionService at all when fetching all the types for the assembly that XeniaVersionService is in. https://res.kate.pet/upload/0471946350b5/eQHcs2gxgy.png I've disassembled the XeniaBot.Data library by itself and it includes the XeniaVersionService. https://res.kate.pet/upload/d45c9de1d711/dotPeek-232.0.20231101.171432_GRKD9P5Alc.png But the XeniaBot.Data.dll that is in the XeniaBot.Core bin folder, doesn't have XeniaVersionService. https://res.kate.pet/upload/f18fa620b99d/dotPeek-232.0.20231101.171432_VAkXvaFiZC.png
28 replies
CC#
Created by kate! on 2/4/2024 in #help
Class Naming Conventions
I'm currently renaming all the classes in my Discord Bot project but I'm stumped to decide what the suffix should be for a class that the wrapper for a collection in a database. Context wouldn't make sense, since I am not using Entity Framework. Currently I have; - Services for classes that just do things (like handling guild logging events) - Modules for the interaction modules that are used by Discord.NET (handling slash commands) - Models Whatever is the type for the collection - Controller ASP.NET controllers, duh.
12 replies