Hype_the_Time
JCHJava Community | Help. Code. Learn.
•Created by Hype_the_Time on 1/18/2025 in #java-help
Hotswap file not found error. Running works fine.
My Project runs just fine. Even the "missing" code works. But when I want to hotswap it fails with errors like this one with a lot of files.
/home/spieler/IdeaProjects/BBsentials-Server/main/src/main/java/de/hype/bbsentials/server/discord/events/staticimplementations/commands/commands/development/TestDiscordCommand.java:17: Fehler: Failed to parse source file: src/main/java/de/hype/bbsentials/server/discord/events/staticimplementations/commands/commands/development/TestDiscordCommand.java (Datei oder Verzeichnis nicht gefunden)
public class TestDiscordCommand extends AbstractSingleCommand {
^
→ Reason found: different working directoreis between tasks set in run config
312 replies
JCHJava Community | Help. Code. Learn.
•Created by Hype_the_Time on 12/12/2024 in #java-help
In Project Annotation Proccessor
very short: Some classes are required by my annotation proccessor which when run first compiles the whole project to run which fails because of the classes that its generating missing in some other classes because they are loaded at the same time causing a chikcen egg problem. Running in different sub projects causes either a dependency loop or missing dependencies for some classes with dependencies.
full explenation:
I recently stumbled across annotation Proccessing and wrote one that works for my purposes as long as its in a different gradle project. However If I want to add something that utilises Classes from my main Code I need to change the location to that other class including that classes dependencies which is quite annoying. However I cant put it in the same project since parts of my code are generated using that annotation Proccessor. That means that the compilation which is needed before the processing fails since the imports to those auto generated classes fail since they are deleted on regeneration. meaning a chicken and egg problem. However the classes that use that generated code are not required by my processor. Meaning I basically would have to only compile the annotation processor first and then the classes as it needs them. After that the rest can be compiled. Question is how could I do that? any other way is also fine by me.
270 replies
JCHJava Community | Help. Code. Learn.
•Created by Hype_the_Time on 9/17/2024 in #java-help
attribute not being set.
when opening the page I get:
ID: ${id}
Insetad of
ID: 6be5ede5-2393-40a0-9cab-48364af0d541
html:
<h1>ID: ${id}</h1>
9 replies
JCHJava Community | Help. Code. Learn.
•Created by Hype_the_Time on 8/17/2024 in #java-help
spring logging error
I just get an Error when enabling Spring. Just by deactiviating the launch of spring using
// SpringApplication.run(WebsiteController.class);
The Programm runs fine. If enabled it crashes with the attached Error.
I attached each File that seems relvant for my eyes. I wasnt able to fix it while tring a lot.
8 replies
JCHJava Community | Help. Code. Learn.
•Created by Hype_the_Time on 4/22/2024 in #java-help
(Possibly solved) Automatic Config Saver parameterized gson cast problem
I have the problem that once I restart MC it can no longer be casted. After indexing its the type Linkedtreemap even though the object is in a List of the type TrustedPartyMember. I had a look around however I was not able to come up with a solution.
Object is created with new row in trustedpartmemberconfig screen using addrow method in there. Saving is with Configmanager .save.
Affected List is List<TrustedPartyMember> in Party Config
It works on init but fails casting after loading using gson later.
code is attached in the Messages below. The Full Code is also available throught the following links.
Full Code links:
TrustedPartyMember.java https://github.com/HacktheTime/BBsentials/blob/hypeswap/common/src/main/java/de/hype/bbsentials/client/common/client/objects/TrustedPartyMember.java
SelectionScreen<T>.java https://github.com/HacktheTime/BBsentials/blob/hypeswap/fabric/src/main/java/de/hype/bbsentials/fabric/screens/SelectionScreen.java
TrustedPartyMemberConfigScreen.java https://github.com/HacktheTime/BBsentials/blob/hypeswap/fabric/src/main/java/de/hype/bbsentials/fabric/screens/TrustedPartyMembersConfigScreen.java
ConfigManager.java https://github.com/HacktheTime/BBsentials/blob/hypeswap/common/src/main/java/de/hype/bbsentials/client/common/config/ConfigManager.java
PartyConfig https://github.com/HacktheTime/BBsentials/blob/hypeswap/common/src/main/java/de/hype/bbsentials/client/common/config/PartyConfig.java
20 replies
JCHJava Community | Help. Code. Learn.
•Created by Hype_the_Time on 3/18/2024 in #java-help
dettaching process from parent
Im running multiple applications with an updater. however I dont want the childs to be killed nor stopped when the updater itself needs an update. I create the childs using Runtime command execution.
Environment: Debian Linux Server.
68 replies
JCHJava Community | Help. Code. Learn.
•Created by Hype_the_Time on 3/18/2024 in #java-help
missing command output
For some Reason the output that i get from executing a command via Runtime.getRuntime().exec("command") is incomplete.
In this case I only get "Reading packet List... " isntead of also getting things likke "All packets are up to date." etc even though i get those when executing it manually in sheel. It ried stuff with debugger but wasnt able to find a work around for the problemm.
Environment Linux Debian Server
I am am aware that running java as root would be a great security risk. I circumvented it by using a dummy user which does not have sudo permission and allowing him to execute apt update and apt list --upgradeable.
46 replies