#paper
1 messages ยท Page 15 of 1
Tested with paper brig API commands via test plugin and legacy commands via WE:
LGTM.
dd6d184 Remove redundant fillUsableCommands call (#11425) - Machine-Maker
Do you have a specific use-case for adding API getters/setters?
We'd rather hold off on adding more methods until we have a strong API specific usecase, given this seems rather admin specific with the config values.
The API should already be able to deal void damage via the damage cause API if needed and these methods add to the general clutter that is the World interface already.
Beyond that, we can combine enabled and damage into a FloatOr.Disabled (needs to be created)
Shouldn't use nms.ItemStack#remove which will create a patch to remove the implicit enchantments component on all items.
f33611c fix ItemStack#removeEnchantments creating non-s... - Machine-Maker
8f56db8 Add enchantWithLevels with tag specification (#... - masmc05
b7ab22d Fix console completions on invalid commands (#7... - Machine-Maker
Stack trace
https://paste.gg/p/anonymous/50c82e07764046039b1e4a7a037a8dc8
Plugin and Datapack List
None installed.
Actions to reproduce (if known)
Download Paper JAR. can one 121.1 build 104 or build 105 - same result from either one. Java 23 is installed but tested it all the way back to Java 17 with identical results. macOS 15 Sequoia is installed. This is occurring on an Apple Silicon M1 Mac Mini with 8 GB of RAM. (Same issue tested and occurs also on an Apple Silicon M1 MacBook Air with 16 GB of RAM though as well). Run:
Paper version
121.1 build 104 or 121.1 build 105 - both have same result.
Other
Java 23 is installed but tested it all the way back to Java 17 with identical results. macOS 15 Sequoia is installed. This is occurring on an Apple Silicon M1 Mac Mini with 8 GB of RAM. (Same issue tested and occurs also on an Apple Silicon M1 MacBook Air with 16 GB of RAM though as w...
What is the output of running file $(which java) from terminal
What is the output of running
file $(which java)from terminal
which java)
/usr/bin/java: Mach-O universal binary with 2 architectures: [x86_64:Mach-O 64-bit executable x86_64] [arm64e:Mach-O 64-bit executable arm64e]
/usr/bin/java (for architecture x86_64): Mach-O 64-bit executable x86_64
/usr/bin/java (for architecture arm64e): Mach-O 64-bit executable arm64e
Could you try with the macos aarch64 build from https://docs.aws.amazon.com/corretto/latest/corretto-21-ug/downloads-list.html?
Could you try with the macos aarch64 build from https://docs.aws.amazon.com/corretto/latest/corretto-21-ug/downloads-list.html?
It works well with that Amazon Corretto version of Java, thank you! Not sure why it didn't work with Oracle's Java, strange.
I would guess the universal binary is somehow confusing Java when it tries to load native libraries, but regardless I'm glad that the aarch64 Corretto builds work properly. JVM crashes are mostly out of our control as a Java application, so I'll mark this issue as resolved.
@lynxplay so out of my own curiosity, what has been chanced in support of the PR? Some other files/patches where modified as well.
The diff was moved to a different patch, a patch that added the support in the first place.
Hey @PedroMPagani, I'm closing this due to you not providing actual logs (a screenshot isn't helpful), and the report being incomplete which makes it more difficult for the people that spend their free time working on Paper.
Please feel free to create another issue with actual logs, code examples to reach your issue, and a more complete report. Cheers!
@PedroMPagani This is why you should use an anonymous account not tied to your server for issue reports, certain individuals will treat you differently for being successful.
Bundle packet seriously needs added to vanilla MC, I have noticed this issue aswell, sending 1 bundle packet per tick instead of thousands of particle/block update packets per second would be way more efficient in terms of network performance and bandwidth usage and not create any delays due to the client waiting for next tick anyways.
Discussion Category: Ideas
Yes, dynamically loading/building worlds with WorldCreator from region files on disk, mainly for minigames.
Currently you can generate a custom world at runtime with a custom generator, biomeProvider, etc... but obviously void kill height can not be set when creating the world, much less at runtime.
An alternative may be to modify WorldCreator.java to support passing in a custom world.yaml config settings (and potentially reloading those settings at runtime in World.java), but this is obviously much simpler and I would very much enjoy not having to take on such a task.
Eh sounds fair, I guess.
I'll chat it over with the rest of the team.
You can deal void damage perfectly fine via https://jd.papermc.io/paper/1.21.1/org/bukkit/entity/Damageable.html#damage(double,org.bukkit.damage.DamageSource) and https://jd.papermc.io/paper/1.21.1/org/bukkit/damage/DamageType.html#OUT_OF_WORLD respectively tho.
Maybe it is worth consolidating the void damage configuration into a single interface type, e.g.
World#getVoidDamageConfiguration()
World#setVoidDamageConfiguration(WorldVoidDamageConfiguration)
interface WorldVoidDamageConfiguration {
boolean isVoidDamageEnabled();
double getVoidDamagePerTick();
float getMinWorldHeightOffset();
static WorldVoidDamageConfiguration vanilla() { }
static WorldVoidDamageConfiguration enabled(double damage, float minWorldHeightOffset) { }
static WorldVoidDamageConfiguration disabled() { }
}
but I'll get back to concrete next steps once we have more team input on this.
For now, could yo...
PR Session log:
- Changed to
setRecipeBrewingTicksas our best attempt at naming whatever this concept is. - Experimental annotations for this naming. While it is our best attempt and will be merged, I am not comfortable in guaranteeing people won't have issues with it. If we receive large amounts of negative feedback and confusion, this allows us to revisit.
- No longer bump
recipeBrewingTimeto setbrewingTime. Spigot users calling this method and trying to get this weird behaviour would see a behaviour change. Additionally, if you want to configure this value (like you'd do in the event) we want you to also call thesetRecipeBrewingTicksmethod if you end up overshooting the 400 ticks.
355b1cb Add API for explosions to damage the explosion ... - EsotericEnderman
I've made it an offset from the build height as requested, defaulting to -64 blocks from the minBuildHeight.
After some more time and feedback from the team, I'll be closing this as a wont-merge.
Still thank you for your time and the objectively great work on the PR, even if the concept is something we do not feel comfortable merging.
The main reason for closing this is the potential reliance of this from third-party tools or plugins.
They may invoke these commands and simply rely on the fact that it happens instantly.
Given that third party plugins can 100% implement this PR in custom commands that would allow server owners to enjoy a lag-free whitelist/ban call without interfering with the vanilla behaviour here adds to the above reason.
I hope this makes sense to you, and again, thank you for the work, it is greatly appreciated even if we decided to not go forward with it. If you do end up developing this as a plugin or the likes, feel 100% free to link it here for others in need to find.
After some more feedback, we ended up closing the related PR linked above.
See that PR for the reasons we do not believe vanilla commands editing important data like that should have behaviour changes as drastic as their completion.
Thanks for merging!
I noticed you used my old username (Slqmy) instead of my new username (EsotericEnderman) when you added Co-authored-by, I don't mind too much, but at the same time why?
[PaperMC/Paper] New branch created: mainCapabilityAttribute
54f05e4 Specify mainCapabilityAttribute for paper-api - jpenilla
Fixes the api being bundled into com.destroystokyo.paper as paper-mojangapi
Ah sorry, that was the one uses in the patch files you originally submitted. I'll change it up tonight if you can quickly give me your preferred name and email.
Sure thing, my preferred name is Esoteric Enderman and my preferred email is 90862990+EsotericEnderman@users.noreply.github.com.
If you could change it to these in both of the patch files, that would be great! Thanks in advance.
Hi, any update on this?
I'm currently running roughly the same logic as in this PR in my code to compute the number of crafted items, but having to implement it myself can lead to errors (I already had to fix my code twice...), and I would love to see it implemented officially by Paper instead!
Thx
Rebased.
For now, removed BlockState clone from API and inserted itemstack defensive clones.
Expected behavior
no npe when completing a profile
Observed/Actual behavior
npe when completing a profile
Steps/models to reproduce
- create a profile with only a name
- complete the profile
Plugin and Datapack List
irrelevant
Paper version
[16:45:45 INFO]: Checking version, please wait...
[16:45:45 INFO]: This server is running Paper version 1.21.1-110-master@6d7a438 (2024-09-28T22:14:12Z) (Implementing API version 1.21.1-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.1-85-c5a1066 (MC: 1.21.1)
Other
CraftPlayerProfile#getId returns null when the profile id equals NIL_UUID which is correct
The complete method uses this.getId() instead of profile.getId()
MinecraftSessionService#fetchProfile requires a not-null profileId
...
If I can still contribute to this issue, I'd love to solve the problem!
I was thinking of adding โServerChunkCache#isPositionEntityTickingโ and using it in โEntity#isTickingโ. Can I try this?
If I can still contribute to this issue, I'd love to solve the problem! I was thinking of adding โServerChunkCache#isPositionEntityTickingโ and using it in โEntity#isTickingโ. Can I try this?
Sure! But it looks like the Paper EntityCommand also needs to be updated, and the changes here span multiple patches (MC-Utils, Moonrise, Paper command, Entity#isTicking). So this might not be the best change for a first-time contributor unless you're already very familiar with the patching process. Let me know if you still want to have a try, otherwise I can handle this.
Adjusts the annotation test to check if the class as the NullMarked annotation, and if it does, to skip the whole class.
This will probably be several PRs so it's not just one HUGE pr.
No longer needed because there are subinterfaces for each view type (like EnchantmentView, BrewingStandView, etc.).
Closing as not really applicable to inventory type (translation key for GENERIC3x9 is different for chest vs barrel.
Translatable also isn't as great anymore with more and more things potentially defining their display components as non-translatables once data driven.
f9c7f2a Begin switching to JSpecify annotations (#11448) - Machine-Maker
b410fe8 Configurable per-world void damage offset/damag... - Axionize
[PaperMC/Paper] New branch created: bugfix/npe-in-profile-resolution
52bff3d Do not NPE on uuid resolution in player profile - lynxplay
Band-aid fix for the player profile api resolution for a profile with
name but without uuid. The real solution is a proper refactoring of the
completeFromCache and complete method internally, however this needs
further consideration regarding existing faulty behaviour around name
lookups from uuid-only profiles.
Resolves: #11447
ea00be3 Do not NPE on uuid resolution in player profile... - lynxplay
[PaperMC/Paper] branch deleted: bugfix/npe-in-profile-resolution
@jpenilla Thank you for your reply.
Due to my lack of understanding of the project, I didn't understand why we need an extension like โEntityCommandโ, could you please explain it in a simple way? I thought I just needed to write the code like this so I could use 'NewChunkHolder#isEntityTickingReady'.
public boolean isTicking() {
// ServerChunk#isPositionEntityTicking uses NewChunkHolder#isEntityTickingReady
return ((net.minecraft.server.level.ServerChunkCache) level.getChunkSource()).isPositionEntityTicking(this);
}
EntityCommand is a class inside of paper, he's saying that if we patch this here, then that class, and potentially various others, should also be updated with that change
Stack trace
There is unfortunately no stack trace, this is a memory leak server crash that appears to be related to paper.
I was informed in the PaperMC discord that moonrise seems to be a part of Paper. An acquaintance seems to be experiencing constant out of memory server crashes which upon further inspection seem to all be caused by a "ca.spottedleaf.moonrise" package.
To do this analysis, I made several heap dumps and compared them using /spark heapdump
and JProfiler, where the object analysis shows that the ca.spottedleaf.moonrise class seems to have an ever-increasing concurrent long array that keeps getting bigger and bigger until the server crashes.
Here is what these heap dumps look like in the profiler, which shows the size increasing relative to everything else.
Plugin ...
can you show the output of /paper holderinfo when having this issue?
Minecraft does not support this, and so we cannot either.
Minecraft does support it
If you look at the Protocol of Update score
You can send text component
_Originally posted by @kashike in https://github.com/PaperMC/Paper/issues/5685#issuecomment-844226483_
Minecraft does not support this, and so we cannot either.
but as for today Minecraft does support
here is a test I created to see that it work
If you look at the Protocol of Update score
You can send text component
Is your feature request related to a problem?
not enough info in the javadocs
Describe the solution you'd like.
Adding more information in the javadocs like @ApiStatus.AvailableSince("1.20-R0.1-SNAPSHOT")
Describe alternatives you've considered.
none
Other
Yes it may be useless because you should only look on your current version of paper api but I think it will be much nicer to know since which version of the api the feature as been created at
Discussion Category: Ideas
It seems this patch introduce a new dupe for arrow. Crossbow doesn't consume the arrow when the item is used in survival but the player can still launched the projectile.
And some diff around EntityShootBowEvent#setConsumeItem deprecation has been removed during the rebase.
Usually, if nms/bukkit files are modified FQN should be used instead of imports to reduce the diff. Also, every line that is added needs to be marked with a comment. For more information refer to the CONTRIBUTING.md :)
Don't manually change patch files, you need to make changes, amend it to the latest commit in paper-server and then rebuild patches
[12:14:41] [Server thread/INFO]: Total: 841 Unloadable: 0 Null: 784 ReadOnly: 0 Proto: 0 Full: 57
[12:14:41] [Server thread/INFO]: Chunks in world_nether:
[12:14:41] [Server thread/INFO]: Total: 841 Unloadable: 0 Null: 792 ReadOnly: 0 Proto: 0 Full: 49
[12:14:41] [Server thread/INFO]: Chunks in world_the_end:
[12:14:41] [Server thread/INFO]: Total: 841 Unloadable: 0 Null: 792 ReadOnly: 0 Proto: 0 Full: 49
[12:14:41] [Server thread/INFO]: Chunks in Resource_Nov:
[12:14:41] [Server thread/INFO]: Total: 841 Unloadable: 0 Null: 792 ReadOnly: 0 Proto: 0 Full: 49
[12:14:41] [Server thread/INFO]: Chunks in shop:
[12:14:41] [Server thread/INFO]: Total: 1802 Unloadable: 0 Null: 1672 ReadOnly: 0 Proto: 0 Full: 130
[12:14:41] [Server thread/INFO]: Chunks in resource_nether:
[12:14:41] [Server thread/INFO]: Total: 841 Unloadable: 0 Null: 792 ReadOnly: 0 Proto: 0 Full: 49
[12:14:41] [Server thread/INFO]: Chunks in resource:
[12:14:41] [Server thread/INFO]: Total: 841 Unloadable: 0 Nu...
12:14:41] [Server thread/INFO]: Chunks in em_the_pirate_ship:
[12:14:41] [Server thread/INFO]: Total: 191394 Unloadable: 191394 Null: 1277 ReadOnly: 76 Proto: 189674 Full: 367
You definitely have a plugin which stoped the chunk unloading in this world, follow this guide to find out which plugin does this https://docs.papermc.io/paper/basic-troubleshooting#finding-the-culprit
If you'll check the configs of that plugin, check for "chunk unloading", "world saving" etc
If it doesn't have such a config, go report the memory leak to the plugin author, as this memory leak is not caused neither by paper or moonrise
Since https://github.com/PaperMC/Paper/pull/11309, paper officially deprecated upstreams method (see the PR and this PR for reasaons)
I'll be closing this as we don't need to introduce adventure methods for deprecated upstream API.
Ah sorry, that was the one uses in the patch files you originally submitted. I'll change it up tonight if you can quickly give me your preferred name and email.
@lynxplay any update on this...?
The new method allows overriding the title on the menu which is being opened without the necessity to listen to InventoryOpenEvent and setting InventoryOpenEvent#titleOverride(Component)
When creating this new api discovered an issue with the current method which has a very small fix, the issue being that currently when running
@EventHandler
public void onInventoryOpen(org.bukkit.event.inventory.InventoryOpenEvent event) {
if (event.getInventory() instanceof HorseInventory) {
event.getPlayer().getScheduler().runDelayed(this, task -> {
event.getPlayer().openInventory(event.getPlayer().getOpenInventory());
}, () -> {}, 40L);
}
}
You will get this error https://pastes.dev/yAFvj1yF6I
Should I instead of current behavior, pass the title override as the...
e7e1ab5 Finish converting most of the undeprecated api ... - Machine-Maker
The server implementation of the event was still doing a legacy conversion. While the input to the event currently has to use the legacy serializer (cause the message source is the spigot config), after the event is fired, we should just use the component set directly.
You can already create views with any title via the MenuType API. Is there a point to adding this with the MenuType API already in?
Use @NullMarked on the type and remove any NotNull/NonNull annotations.
Lets put this in some util package or smth. Instead of entity. Also, just call it like SizeLimitedSet, Paper doesn't really apply to it.
Why? what is wrong with jetbrains annotations?
Because JSpecify is the new annotation library developed by a commit, including JetBrains, google, etc., in order to create one true framework. it being new means that it's not going to have as many users yet.
Because JSpecify is the new annotation library developed by a commit, including JetBrains, google, etc., in order to create one true framework. it being new means that it's not going to have as many users yet.
If jetbrains developed this standard, then why doesn't it show as the first result when typing @Nullable, which is what everyone will pick in future? It doesn't even show on the list.
Once again, it's new; it's not going to show up high on the lists, they don't blindly show preference to their own library
It doesn't even show on the list.
It obviously won't show up in the list if you haven't added it to your project. https://i.imgur.com/wixYnGI.png
It doesn't even show on the list.
It obviously won't show up in the list if you haven't added it to your project. https://i.imgur.com/wixYnGI.png
Until it comes shipped in intellij by default and is the top result, it will continue to be unused. ๐คทโโ๏ธ
There is no "default" included nullness annotations beyond javax', jetbrains annotations are their own library you have to explicitly depend on like any other. If you need help updating your dependencies or understanding the purpose of these libraries, you can ask in our Discord
Is your feature request related to a problem?
This feature request is related to the problem that it is -- as plugin developer -- unnecessarily difficult to set the texture of a player head to a signed texture, often I solve this using some reflection (which became more difficult in the later versions due to ResolvableProfile), but I think it'd be beneficial to all plugin to implement an more straight forward way to achieve this.
Describe the solution you'd like.
I'd introduce this in either one of the following ways, I'd be happy to hear some feedback if there're other ideas to achieve this!
- Introduce a 'setUrl' method on SkullMeta, under the hood this method works as follows:
- It creates a property value of proper format from this URL for example a taco skull
"textures": {
"SKIN": {
"url": "http://textures.minecraft.net/texture/98ced74a22021a535f6bce21c8c632b273dc2d9552b71a38d57269b3538cf"
}
}
eyJ0ZXh0dXJlcyI6eyJTS0lOIjp...
Discussion Category: Ideas
For current opened view, this method goes trough the proper whole open inventory process without closing it, maintaining the most similar state to the pre open state
Use either one
SkullMeta meta;
URI uri; // In the example is http://textures.minecraft.net/texture/98ced74a22021a535f6bce21c8c632b273dc2d9552b71a38d57269b3538cf
// Set both to actual values here
var profile = Bukkit.createProfile(new UUID(0, 0), "");
var textures = profile.getTextures();
textures.setSkin(uri.toURL());
profile.setTextures(textures);
meta.setPlayerProfile(profile);
or
SkullMeta meta;
String base64; // In the example is eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOThjZWQ3NGEyMjAyMWE1MzVmNmJjZTIxYzhjNjMyYjI3M2RjMmQ5NTUyYjcxYTM4ZDU3MjY5YjM1MzhjZiJ9fX0=
// Set both to actual values here
var profile = Bukkit.createProfile(new UUID(0, 0), "");
var property = new ProfileProperty("textures", base64);
// var property = new ProfileProperty("textures", base64, signature);
profile.setProperty(property);
meta.setPlayerProfile(profile);
Discussion Category: Ideas
I did not know that bukkit.createprofile exists, thank you :D
Discussion Category: Ideas
Without currentSize, this can be simplified to edited |= this.add(tag).
Did you mean super.add(tag)? Otherwise, seems like a recursive loop to me
The currentSize field seems redundant? We already have the size() method, which is automatically increased anyway
Is your feature request related to a problem?
how to download
Describe the solution you'd like.
how to download
Describe alternatives you've considered.
how to download
Other
how to download
Discussion Category: Ideas
how to download
Discussion Category: Ideas
Discussion Category: Ideas
Is your feature request related to a problem?
N/A
Describe the solution you'd like.
Add in the CONTRIBUTING.md a section for mention about how PR related to Paper classes need the use of jspecify rather than jetbrains-annotation
Describe alternatives you've considered.
N/A
Other
No response
Discussion Category: Ideas
Using return here would interrupt the annotation tests. I could have opened a pull request myself, but I thought it would be better for the Paper team to resolve this issue.
Ah yeah, shouldโve been a continue. Oh well, itโs just a test. You can do a PR, itโs not a big deal.
Also, the issue of failing tests in nested classes has been resolved.
cc137d0 Add section on nullability annotations - kennytv
[PaperMC/Paper] New branch created: contrib-annotations
Not sure if nullmarked actually applies to inner classes, those might be valid fails
Maybe can add a reference for the JSpecify docs?
like: https://jspecify.dev/docs/user-guide/
Ok so i finally got time to have a look at the PR again.
Looking at the code i realized that it's kind of impossible to call the Pre(pare)TeleportEvent for PortalEvent at a time where it makes sense since it requires a DimensionTransition object for both the destination coordinates and the teleport cause. Unfortunately, until we actually get that object it will not just call PreparePortalEvent and PortalEvent but it will also create a portal in the process. And since the PortalEvent is cancellable it would not make sense to create the portal.
Now i could add boolean parameters that handle whether to call the events or create the portal, but I don't know if we want this. Maybe i am overseeing something and there is another way to do this, but I don't see any other way.
Maybe it is actually better to create a TeleportFailEvent. But I would like to have different opinions on this if that is possible.
This issue still exists in the latest version. The build version provided by 9949 may still become invalid in some cases (which I cannot accurately explain)
which I cannot accurately explain
Can you try at least? Or show it via screenshots/video?
If we missed something in the latest build of the PR we'd obviously like to fix that before merging this.
709f0f2 Use components properly in ProfileWhitelistVeri... - Machine-Maker
Resolved your comments lulu, now with a cuter looking entity load crossbow event impl.
This will always return Entity.class, so the generated content is almost useless and all the metadata are skipped.
Generally i don't think the new module is really needed and this can be done with regular reflection like https://pastes.dev/FNvwYGnwgS
Expected behavior
Players in spectator mode should NOT drop a loot table on death, just like in vanilla or Paper.
Observed/Actual behavior
Players in spectator mode drop the minecraft:entities/player loot table on death.
Steps/models to reproduce
- Install this minimal reproduction data pack by copying it into the server's
world > datapacksfolder. This adds a player head to the player's loot table unconditionally. - Op yourself in the server console.
- Join the server, and enter
/gamemode spectator. - Enter
/kill @s. - Observe that a player head dropped. In vanilla or Paper, nothing drops.
Plugin and Datapack List
Just the minimal reproduction data pack.
Paper version
> version
[16:38:13 INFO]: This server is running Paper version 1.21.1-118-master@fb76840 (2024-10-02T12:49:56Z) (Implementing API version 1.21.1-R0.1-SNAPSHOT)
You are running the latest version
P...
I think there's also an issue with spectators and xp dropping, but I can't test that out right now. Until I check that, this can be a draft.
Expected behavior
When printing out the result of event.getClick() during the InventoryClickEvent, I was expecting ClickType.MIDDLE to get printed upon clicking with the mousewheel on an item.
Observed/Actual behavior
Instead, what I've found out is that no matter what one tries doing, ClickType.MIDDLE can never be detected.
Upon middle clicking an item in an inventory (could be any inventory from what I saw), the only click being detected is ClickType.UNKNOWN.
On discord I was initially told that detecting middle clicks isn't supported, though I find it really strange that the only way to get an UNKNOWN click type is through middle-clicking an item in Survival Mode.
Steps/models to reproduce
- Create a barebones plugin, one which simply listens to the InventoryClickEvent
- Print out event.getClick()
- In survival mode, try all types of clicks that are meant to be available (Left, right, shift-left, shift-right, double left, switch hand, number key, drop,...
There is no "maintaining the old functionality". Maintaining the old functionality is impossible to do. Adding
meta.setAttributeModifiers(MultimapBuilder.hashKeys().hashSetValues().build())is not always the correct solution. That will remove any implicit modifiers on non-armor items. That will then change functionality of the non-armor item. That is what upstream is currently doing to try and "fix" the issue, which then just breaks lots of items in the mean time removing the default/implicit modifiers for that item type.There are 2 possible cases for each 5-year old plugin with this "issue":
- They don't care about the actual modifiers (if in like a GUI inventory or smth). In this case, setting an empty map when the HIDE_ATTRIBUTES flag is present is a valid solution.
- They do care about the actual modifiers, but only want to hide them in the tooltip. In this case, setting an empty map will remove the implicit modifiers on the itemstack. One might think a solu...
Just wanted to add both use cases are extremely valuable, most players know the default values
most players are generally not the ones creating these items (and where they are, they'll be subjected to the new behavior directly through the command, not as a side-effect of something that for the better part of a decade just set a flag that hides something in the UI), it's plugins which have existed for a decade with a presumed set of behavior that they can hide attributes on their items to mitigate the space taken up by fluffing up item lore, etc.
In cases where plugins are creating GUI items, it's easy to mitigate as they can just add any attribute they want in order to cause the component to save, but implicitly removing all item attributes when you pick to hide attributes just did not feel like the correct solution here as a default practice.
Expected behavior
command selector eg @s will right colored when player have minecraft.command.selector permisssion
Observed/Actual behavior
command executed, but in chat have wrong colored
Steps/models to reproduce
/minecraft:tp @a @s
Plugin and Datapack List
paper only
Paper version
[12:15:55 INFO]: Checking version, please wait...
[12:15:57 INFO]: This server is running Paper version 1.21.1-118-master@fb76840 (2024-10-02T12:49:56Z) (Implementing API version 1.21.1-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.1-116-e7e1ab5 (MC: 1.21.1)
Other
No response
I test and experience its not dropped in spectator mode but this is because the "keepLevel" behaviour use the same logic for keep is the keep inventory is true or the player is in spectator. also the "logic" for get how many exp need to be dropped is 0 for spectator but not sure from where comes that.. i just found a call for EnchantmentHelper.processMobExperience but not sure.
Update: Turns out that the behavior breaks when rebinding the middle mouse button to another button (As I have, since I develop on my macbook and there is no middle mouse button to use).
It seems that rebinding the middle mouse button to a keyboard key (in my case, R) breaks the way that the middle button is detected to behave like I described above.
Was able to reproduce this. Remapping MMB (to M on keyboard in my case) leads to invalid(?) actions being sent from the client:
- Having air on cursor and pressing remapped
MMBover an item in inventory sendsCLONEaction with0 (LMB)button num. - And having any item on the cursor will lead to
PICKUPaction with3 (MMB).
Both of these are unmapped/unknown actions, so it falls back to UNKNOWN.
Expected behavior
- the player have an attribute ( like this one for exemple : /attribute @p minecraft:generic.max_health modifier add 1 10 add_value
- the player died
- the attribute is reset because in this case, the attribute is not the Base attribute
here an exemple of vanilla 1.21.1
Observed/Actual behavior
- the player have an attribute ( like this one for exemple : /attribute @p minecraft:generic.max_health modifier add 1 10 add_value
- the player died
- the attribute still active ( and somes plugins are affected by that )
Steps/models to reproduce
how to make the bug:
- do that command: /attribute @p minecraft:generic.max_health modifier add 1 10 add_value
- play in gamemode survival and do some /kill @p
- the generic.max_health modifier is not reset and that is the bug
Plugin and Datapack List
no plugins
Paper version
This server is running Paper version 1.21.1-119-master@7cd4f2c (2024-10-03T15:19:34Z) (...
Worth mentioning, 24w20a fixed base values not being copied, attribute modifiers should still be reset on death to be like in vanilla
https://minecraft.wiki/w/Java_Edition_24w33a 1.21.2 snapshot, also changes this further...
Add this. before field access
you can use the constant MAX_ENTITY_TAG_COUNT
I feel the name is too generic for what this does unless you add a generic to it and remove tag reference.
Expected behavior
I am creating an item to display in a GUI and this worked fine prior to my 1.21 update. But now, it displays with the armor trim in the GUI despite the item having the HIDE_ARMOR_TRIM flag and the item has a trim visible in the GUI
Observed/Actual behavior
The armor trim is still shown on the item
Steps/models to reproduce
Make an item with an armor trim. Set the flag to hide armor trims. It should still have it
Plugin and Datapack List
[22:19:32 INFO]: Server Plugins (76):
[22:19:32 INFO]: Bukkit Plugins:
[22:19:32 INFO]: - AdvancedAchievements, AdvancedArmorStands, AdvancedEnchantments, Brewery, BuycraftX, ChestShop, ChestShop-LegacyIds, Chunky, Citizens, *Commander
[22:19:32 INFO]: CoreProtect, CrazyAuctions, DecentHolograms, DeluxeMenus, DespawnSpy, DetrimUtils, EnchantGui, Essentials, EssentialsAntiBuild, EssentialsGeoIP
[22:19:32 INFO]: EssentialsProtect, EssentialsSpawn, ExploitFixer, FarmLimiter, FeatherBoard, floodgate, GriefPreve...
Adds a new method which returns the name of an itemstack which the player sees in their inventory. Takes into account any data components exactly as vanilla.
Unlike ItemStack#displayName, does not add additional brackets etc
Hmm, the javadocs for
ClickType.MIDDLEkinda specifically state that it's the middle mouse button being used, not "whatever action the middle mouse button does by default". I think, because of that, we have to add another enum value and then maybe a helper method to check if it's either MIDDLE or whatever the new one is, like isCloneAction() or something.
That's fair enough. Either way though, I think it's important to be able to pick up whether a user rebound the key or not as especially those on laptops may have, and plugins which rely on middle click functionality would break completely.
Also, while I'm at it, from what I can tell there might be a possibility to detect a player's middle-mouse click (or whatever the button was rebound to) while they are on survival, with no item on cursor yet an item in the slot beneath it. As it servers no functionality in survival it might be a handy way to provide plugin makers with a way to implement functionality in InventoryClickEvents.
Expected behavior
Have recently switched from spigot to paper server. Everything works except chat formatting. Have tried both CMI's chat and EssentialsXChat.
In the console the message is partially formatted properly, based on formatting settings within the desired chat plugin, except the prefix is being shown twice. Within the client it only shows the non-formatted message in White text.
Everything works perfectly when I use the Spigot JAR.
Observed/Actual behavior
Chat from players is not being displayed in the client properly.
Steps/models to reproduce
switched from Spigot to Paper server.
Plugin and Datapack List
PLUGINS:
[02:39:45 INFO]: Server Plugins (11):
[02:39:45 INFO]: Bukkit Plugins:
[02:39:45 INFO]: - CMI, CMILib, Essentials, EssentialsChat, EssentialsSpawn, FastLeafDecay, Jobs, LuckPerms, Vault, VeinMiner
[02:39:45 INFO]: voicechat
DATAPACKS:
[02:40:...
Paper has expanded the chat API in a manner that allows plugins to do fancier chat things and it's 100% on plugins on how they interact with that. having two plugins installed which handle that is asking for issues, essentials for example has a config option which is enabled by default last I knew which will put the players pre/suffix into the display name of the player, and so if you're using another chat plugin, you'd want to disable that.
For support, please use the discord.
No. Only EssentialsChat is enabled. I was using CMI to test if it was a plugin issue.
The formatting gets applied in the console. Hence the screenshot.
Does not get applied in the Client.
Furthermore, thanks for closing an issue that wasnt resolved.
Paper has expanded the chat API in a manner that allows plugins to do fancier chat things and it's 100% on plugins on how they interact with that. having two plugins installed which handle that is asking for issues, essentials for example has a config option which is enabled by default last I knew which will put the players pre/suffix into the display name of the player, and so if you're using another chat plugin, you'd want to disable that.
For support, please use the discord.
Originally posted by @electronicboy in #11470
I don't know what this issue aims to accomplish.
Cat already explained to you that third party software (the plugins you run) are responsible for correctly inter-operating. Beyond that, I'd suggest opening issue with the respective plugins used to construct these prefixes. If this ends up actually being an issue in papers API implementation, the developers of the respective plugins know their code and potential caveats a lot better than we do and should be able to open a proper issue on our tracker with actual reproduction steps.
Our discord was suggested as long lasting discussions/support is generally something we do not want on our github issue tracker, as it is reserved for bugs, not the process of figuring out if the issue comes from us, incorrect configuration, faulty plugin interop or even third party bugs.
Again, I'd urge you to open these issues with the developers of the plugin that serve these prefixes.
For what it is worth, a super simple setup with EssentialsCh...
Needs a despawn reason, I'd argue for org.bukkit.event.entity.EntityRemoveEvent.Cause.DESPAWN but it may be worth introducing a new cause for this instead too.
Its easier to just go back to spigot.
Currently if you try to use an anvil with a enchantment book using levels over the max defined then the anvil just ignore level in book and override with the max level defined in registry, this PR allow by config disable this for allow using that enchantment books.
PS: Talking about why this... in my case is just wanna give books with things like sharpness 7 and dont wanna listen the PrepareAnvilEvent and make a whole thing for check compatibility and manually set all in code... and also dont wanna override the max level in bootstrap because this make players can get this levels in vanilla ways.
Hi @lynxplay , I am new around here and would like to have a look into this issue if it is still open. It would be great if some more detail is provided around this issue. Thanks!
I feel like an event for this is better. Some event for books combining would provide more control.
I feel like an event for this is better. Some event for books combining would provide more control.
Like AnvilEnchantItemResult? Im not sure how handle that or what can this event do in that place
I think a PreEnchantCombinationEvent or PreAnvilCombinationEvent where you can override different things like what the base item will be used (so for example you could do pumpkin + enchantment book = enchanted diamond), ignore some limits etc
I think a PreEnchantCombinationEvent or PreAnvilCombinationEvent where you can override different things like what the base item will be used (so for example you could do pumpkin + enchantment book = enchanted diamond), ignore some limits etc
but the thing with items is this already being handle in the PrepareAnvil (but called in multiple things and for that i dont wanna mess with this)
or just add a value in the AnvilView for that and make the AnvilMenu handle from this for make like in the OpenInventory event override the behaviour...
Yeah, a property in AnvilView would also be great
Description:
This pull request implements the EntityRemoveFromWorldEvent, which enhances tracking of entity removal in the game. This new event allows better monitoring of entity removal processes, providing more flexibility for plugin developers.
Key Changes:
- Created
EntityRemoveFromWorldEventclass to represent the removal of entities from the world. - Added various causes for entity removal such as
DEATH,DESPAWN,DROP, etc. - Introduced an event listener system to trigger actions when an entity is removed.
JIRA Ticket:
- Resolves SPIGOT-10280: Link to the JIRA Ticket (if applicable)
Description:
This pull request implements the EntityRemoveFromWorldEvent, which enhances tracking of entity removal in the game. This new event allows better monitoring of entity removal processes, providing more flexibility for plugin developers.
Key Changes:
Created EntityRemoveFromWorldEvent class to represent the removal of entities from the world.
Added various causes for entity removal such as DEATH, DESPAWN, DROP, etc.
Introduced an event listener system to trigger actions when an entity is removed.
JIRA Ticket:
Resolves SPIGOT-10280: Link to the JIRA Ticket (if applicable)
- Usually the upstream is updated by paper team
- Most probably this event needs to be deprecated in favour of already established api https://jd.papermc.io/paper/1.21.1/com/destroystokyo/paper/event/entity/EntityRemoveFromWorldEvent.html
This PR allow change the behaviour in anvils where enchantments applied are limited to the max level registered.
Code to test a case where only books can override the max level limit.
@EventHandler
public void onAnvilPrepare(PrepareAnvilEvent event) {
final AnvilView anvilView = event.getView();
final ItemStack itemStackIngredient = anvilView.getItem(1);
if (itemStackIngredient == null || itemStackIngredient.isEmpty()) {
return;
}
if (itemStackIngredient.getType() == Material.ENCHANTED_BOOK) {
event.getView().setCanApplyEnchantmentsOverMaxLevel(true);
} else {
event.getView().setCanApplyEnchantmentsOverMaxLevel(false);
}
}
PS: This PR is an alternative from https://github.com/PaperMC/Paper/pull/11472
Based in comments i create this https://github.com/PaperMC/Paper/pull/11475 where allow change the bevahiour per Anvil View.
Yeah Paper recommed use the EntityRemoveFromWorldEvent, the only "issue" is how you cannot know why the entity was removed.. for this exists https://github.com/PaperMC/Paper/pull/10149
setCanApplyEnchantmentsOverMaxLevel
the name is too long....
Maybe ignoresEnchantmentMaxLevel() and ignoresEnchantmentMaxLevel(value)?
setCanApplyEnchantmentsOverMaxLevel
the name is too long....
Maybe
ignoresEnchantmentMaxLevel()andignoresEnchantmentMaxLevel(value)?
i wanna the method being a little explain about what can do (or maybe just a thing for docs) because ignoresEnchantmentMaxLevel sounds like a ignore the level not the "limit" or clamp... but still not sure about the names...
As stated, upstream update as reserved for the team.
Expected behavior
intended behaviour:
When a player is red they can only recive damage from one source, however if a greater source of damage hits, the damage from both sources is combined.|
Observed/Actual behavior
expected behaviour:
When a player is red they are fully inveunerable instead of taking damage from the greater source
Steps/models to reproduce
(Vanilla behaviour)
Plugin and Datapack List
no plugins / datapacks
Paper version
This server is running Paper version 1.21.1-119-master@7cd4f2c (2024-10-03T15:19:34Z) (Implementing API version 1.21.1-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.1-18-63ce67d (MC: 1.21.1)
Other
this bug has been detrimental to the vanilla PvP community and has caused a lo...
I cannot replicate this.
With a minimal reproduction setup of a command block chain, the first one running /damage @p 2 minecraft:explosion, the second one running /damage @p 10 minecraft:explosion I end up with exactly 5 hearts of damage, es expected.
Do you have more specific replication steps?
Am I missing something here?
is the 2nd damage source happening during the red tick (damage tick) from the first source or at the same time? as it has to be during the red inveunerability period for the 2nd source to overlap
the clip i sent is the vanilla behaviour but if you do the excact thing i did on latest paper the 2nd crystal does 0 damage, its a large issue for modern vanilla pvp.
Okay yea, I got it.
The issue isn't as much an issue with the invl ticks, the problem is (as per usual lol) the damage modifier API which to allow plugins to change damage values but fails at doing so.
This is a terribly complex and buggy systems, with people relying on nearly every quick, so fixing this is not gonna be fun or fast.
I'll try to write up a more indepth walk through for this issue tomorrow, but yea, confirmed.
@NithinSravan Paper adds non-snapshot BlockState (or really TileState)s. Changes made can then avoid unneeded copies improving performance. But the TileSpawnerConfiguration implementation doesnโt respect this.
I think this is not fixable. The client has it's own logic for checking if selectors can be used, and in vanilla, you have to have an op level of 2. You can try to fake that op level with the sendOpLevel API. In vanilla you have to have at least the 2 level. These arguments are parsed and validated purely on the client. The server-side logic for executing them already has the correct fixes (as evidenced by you being able to run the command).
Is your feature request related to a problem?
Chunkpopulateevent I need to access the height but world.gethighestblockyat isn't ready yet sometimes triggering sync load, would be nice to get the heightmap from chunk directly.
Describe the solution you'd like.
Height map apis for chunk
Describe alternatives you've considered.
not using chunkpopulateevent
Other
No response
Discussion Category: Ideas
Expected behavior
Cancelling ProjectileHitEvent for entity collisions should not prevent block collisions.
Observed/Actual behavior
Cancelling a ProjectileHitEvent fired for hitting an entity can cause arrows to phase through blocks.
Steps/models to reproduce
Shoot an arrow at an entity on the edge of its bounding box, towards the ground. If positioned correctly, the arrow will phase into a block. If the ground is thin enough, it will continue travelling after phasing into the block. Otherwise, it will be lodged within the ground.
Example image of lining up a shot:
Plugin and Datapack List
Only a test plugin, with the following listener to cancel ProjectileHitEvent:
public class TestListener implements Listener {
@EventHandler
public void onHit(ProjectileHitEvent event) {
if (event.getHitEntity() != null) event.setCancelled(true);
}
}
...
This event fires when the tick rate is changed, either by a command or by a plugin.
Useful if you have code dependent on the tickRate (my use case is simulating and predicting possible player movements) and you don't want to have to poll the tickRate all the time.
Isn't the api/event itself missing?
Thank you for noticing that. Not used to the paper build system. Let me fix that real quick.
Also check https://github.com/PaperMC/Paper/blob/master/CONTRIBUTING.md#pr-policy, you're both missing comments on changed lines and you have imports instead of using fully qualified name
Pushed the actual event code
Expected behavior
Reducing the damage in EntityDamageByEntityEvent has no side effects and just reduces the damage.
Observed/Actual behavior
If the damage is reduced in EntityDamageByEntityEvent, the invulnerability timer for an entity is bypassed for subsequent attacks, due to a mismatch in how Paper calculates the most recent attack damage (lastHurt)
Steps/models to reproduce
Add a listener to EntityDamageByEntityEvent to multiply the damage by 0.9.
Place a breakpoint at LivingEntity.java#1470 (at return false):
if (amount <= this.lastHurt) {
return false;
}
If you spam click an entity, verify that this the breakpoint at 1470 is never hit with the listener, but is hit without.
Plugin and Datapack List
N/A
Paper version
This server is running Paper version 1.21.1-119-master@7cd4f2c (2024-10-03T15:19:34Z) (Implementing API version 1.21.1-R0.1-SNAPSHOT)
You are running the latest version...
@lynxplay Just run into this issue myself, perhaps a PreEntityDamageEvent could be added to mean an event where damage can be modified, but it's not guaranteed to be actually applied?
@masmc05 I addressed all the changes you requested. Added comments starting where my patch modifies code, switched to using event.callEvent() and the patch now uses the FQDN instead of imports for changes in Paper-Server.
@Senken12
I have the exact same problem.
I have opened port 25565/tcp and the problem has not gone away.
What else did you do to solve your problem?
My sincere thanks for merging this.
Having item's serialized out as a standardized human readable and editable format is great, and I don't think it matters all that much about the versioning worries people had above.
The main reason why backwards compatibility is critical with Minecraft Plugins, is that they often go unmaintained, and having them be valid for as long as possible helps the ecosystem immensely.
By outputting the items in the 'raw' format, you pass on the responsibility for keeping it up to date to both the dataconverters if it's got versioning information and the user.
Informed users can readily find the latest format to update configs, but rarely is it convenient to fork and upgrade plugins.
Having this, means that a plugin can exist that just loads items into minecraft from text, players can use whatever means they like to edit them, then serialize them back out for configs.
It means that a shop plugin using this, won't need to create it's own...
bypassEnchantmentLevelRestriction(boolean) ?
I 100% agree with masjson tho, that name is not something I'd be interesting in merging as it is giving some strong spigot vibes xD
bypassEnchantmentLevelRestriction(boolean)? I 100% agree with masjson tho, that name is not something I'd be interesting in merging as it is giving some strong spigot vibes xD
im not good for names :c
but bypassEnchantmentLevelRestriction sounds a good method name and the docs talks more about how this means to the max level then i think can work (and can allow users again use that custom books)
Expected behavior
when max-level": 1,it shold return Enchancement-name
Observed/Actual behavior
So its nothing bad but "max-level": 1, when enchancement put on item returns Enchancement-name 1
Steps/models to reproduce
in vanilla it works
Plugin and Datapack List
only one datapack with only one feature - 1 Enchancement
plugins: Server Plugins (31): Bukkit Plugins: - ArmorStandTools, AuctionHouse, AutoCraft, ChestShop, DecentHolograms, DimensionPause, Essentials, EssentialsChat, EssentialsDiscord, EssentialsDiscordLink, EssentialsSpawn, ExcellentCrates, floodgate, FreedomChat, Geyser-Spigot, GriefPrevention, *HopperPipes, LockettePro, LuckPerms, nightcore, ProtocolLib, SuperVanish, TAB, TextDisplay, UltimateAutoRestart, Vault, ViaBackwards, ViaVersion, voicechat, WorldEdit, WorldGuard
Paper version
latest
Other
No response
Please provide a link to the datapack so we can try to replicate this issue.
Some more information I got provided when I tried to take a look at it:
- The general expectation is that any form of mutation should mutate the real object in the world
- The following can be used for "replication steps". It should modify the in-game block entity, but that is currently not the case:
final BlockState state = block.getState(false);
if (state instanceof final TrialSpawner trialSpawner) {
trialSpawner.getNormalConfiguration().setBaseSpawnsBeforeCooldown(100);
}
Also the TrialSpawnerConfig mentioned by lynx refers to net.minecraft.world.level.block.entity.trialspawner.TrialSpawnerConfig.
Hope this helps at least a tiny bit @NithinSravan
I cannot replicate this issue. Are you using the vanilla client?
oh im using via version(backwards) in my serv and client 1.20.4 fabric(mods: allbright, optifine, simplevoicechat), can it be bcuz of viaversion?(backwards)
It probably is because of that. No idea how via handles translating custom enchantments to other versions that don't have custom enchantments. Test without any of those plugins and with a vanilla client (to be sure). I'm guessing that will fix your issue. We can re-open if it doesn't for some reason.
Hello, first time contributor. If this issue is still open can I take a swing at it?
Hello, first time contributor. If this issue is still open can I take a swing at it?
Or maybe looks like a PR already covered this?
[PaperMC/Paper] New comment on pull request: #10149 Add removal reason to EntityRemoveFromWorldEvent
Rebased. Also removed some unneeded diff.
Expected behavior
Shouldn't water animals and ambient creatures stay loaded for longer just like animals and monsters?
Observed/Actual behavior
Is it normal that ambient , water_creature , water_ambient and underground_water_creature all instantly despawn when a players leaves far away? That doesnt happen with monsters and creatures, I tested it with default configs and no plugins with latest software 1.21.1-2324-e12a4de (MC: 1.21.1)
if it is normal then and not a bug then is there a way to stop it from happening?
Steps/models to reproduce
Spawn a squid then fly away until the squid is no longer visible and immediately return.
Plugin and Datapack List
No plugins or datapacks.
Paper version
1.21.1-2324-e12a4de (MC: 1.21.1)
Other
No response
Stack trace
Server Log containing the errors:
https://paste.gg/p/anonymous/fb749d8c53cb422ea335f69a2ef75fac
Plugin and Datapack List
Actions to reproduce (if known)
- Run the command
/to-configas a player - On the console, run either
startConfigorunconfigcommand
Paper version
[21:49:30 INFO]: This server is running Paper version 1.21.1-120-master@57c75a4 (2024-10-09T21:11:07Z) (Implementing API version 1.21.1-R0.1-SNAPSHOT)
You are running the latest version
Other
Here's the full testplugin code:
package com.zedphi.testplugin;
import com.mojang.brigadier.Command;
import io.papermc.paper.command.brigadier.Commands;
import io.papermc.paper.plugin.lifecycle.event.types.LifecycleEvents;
import net.minecraft.server.MinecraftServer;
import net.minecraft.server.network.ServerConfigurationPacketListenerImpl;
import net.minecraft.server.network.Se...
[PaperMC/Paper] Issue opened: #11487 Unable to Clear All Patterns from a Placed Banner using Plugins
Expected behavior
You should be able to use the org.bukkit.block.Banner class to freely change the patterns on a placed banner, including removing all patterns if you wish.
Observed/Actual behavior
You can freely edit patterns in this manner, as long as the end state is that the banner still has some sort of pattern. If you try removing all patterns so the banner is empty, the banner remains unchanged (it keeps its previous patterns). This seems to only occur if the rest of the banner's state (banner type and rotation) is also unchanged.
Steps/models to reproduce
Here's the code from my plugin that highlights the issue. "bannerBlock" is an instance of org.bukkit.Block that points to the banner in the world, and the banner starts out with a pattern on it.
Banner bannerState=(Banner)bannerBlock.getState(); while(bannerState.numberOfPatterns()>0) bannerState.removePattern(0); bannerState.update(true);
If you run this code, the banner remains unchanged. HOWEVER, ...
Is your feature request related to a problem?
not sure if its removed or bugged
but i thought middle mouse button used to be enable for survival players
Describe the solution you'd like.
middle mouse button on inventory click
Describe alternatives you've considered.
middle mouse button on inventory click
Other
No response
Discussion Category: Ideas
I thought this was a thing until Mojang broke it a few versions ago
On Fri, 11 Oct 2024 at 06:12, Achy @.***> wrote:
Is your feature request related to a problem?
not sure if its removed or bugged
but i thought middle mouse button used to be enable for survival players
Describe the solution you'd like.middle mouse button on inventory click
Describe alternatives you've considered.middle mouse button on inventory click
OtherNo response
โ
Reply to this email directly, view it on GitHub
https://github.com/PaperMC/Paper/discussions/11488, or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJMAZFQXRRV5UBGN77VNWTZ25M5LAVCNFSM6AAAAABPYFA372VHI2DSMVQWIX3LMV43ERDJONRXK43TNFXW4OZXGMYDGNBYHE
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>
Discussion Category: Ideas
In my opinion, this is a wont-fix, at least for now. We actively did not expose any API for this yet as it is known to be rather broken on spigot and hence paper given the fact the ServerPlayer instance is re-used and is initialized early on the server side for the respective events.
Messing with internals like this is unsupported for a reason and, until someone finds the time to correctly implement this (which would be a rather large effort from my first glance) I don't think it is worth considering this a bug on our issue tracker. At best a feature request in our discussion section for proper API support during the configuration stage.
So more input on my opinion would be great tho, maybe this is an easy fix I am simply not seeing.
I think that this is generally just hard fork territory. We could maybe forcefully re-init stuff and stray further away from vanilla handling here, but that just sounds like an investment into code debt, which is better off spent elsewhere, such as fixing the actual underlying cause of this once we hard fork
This diff can be minimized by moving the override down and doing an early return instead of an if(notCancelled).
callEvent yields back a boolean indicating cancellation state.
Is your feature request related to a problem?
No mobs naturally spawn within a 24-block radius around a player, so setting the mob-spawn-range to less than 3 is ineffective.
Describe the solution you'd like.
I believe we should have the option to lower the minimum mob spawn range (currently 3, or 24 blocks) to smaller values. This could also allow for reducing the simulation distance below 3. While some mobs, such as ghasts and phantoms, need a larger spawn range, making the spawn distance adjustable per entity would be an ideal solution. This change would help optimize performance and enhance player experience by allowing more entities to appear in confined spaces, while still giving server administrators the flexibility to maintain a vanilla-like experience if desired.
Describe alternatives you've considered.
Just this :shrug:
Other
No response
Discussion Category: Ideas
The game is generally written with the expectation that there is a 24-block dead zone; that way, a creeper or a Zoomie mini zombie doesn't instantly target you when it spawns behind you with a surprise hug. We also do not know the type of mob that is going to spawn, and so getting that information earlier would require dipping into the very logic people reduce their mob count limits to avoid when it comes to the hyper-active spawning logic.
I'm not sure that the side effects for this make sense; the simulation distance cannot be set below 3, and at that point, you're already having side effects on the game due to the short range that can impede vanilla playability. The game was not designed to be played at such low settings, and Mojang rarely ever seemingly actually takes that into consideration.
Discussion Category: Ideas
Ah, I hadn't realized that we don't actually know the type of mob that spawns. I should have caught that from Paper's EntityPreSpawnEvent. Not sure what the solution would be for that. Altough I believe people reduce entities because of stuff like AiStep, adding more complexity to the already finicky type-based spawn logic might only make things worse.
When it comes to hostile mobs like zombies and creepers, I agree it makes sense for them not to target players immediately upon spawning, though some players might enjoy the added challenge. For passive mobs like sheep and cows, that caution isnโt really necessary.
What you mentioned also made me think of something else--though I havenโt looked into it on the discussions yet--what about configuring entity target ranges? Reducing the target range could help optimize performance by cutting down on things like pathfinding and zombie reinforcement logic, which can be quite resource-heavy.
As for the simulation distance side effe...
Discussion Category: Ideas
Stack trace
The output in the console:
Exception in thread "AWT-EventQueue-0" [09:24:38 INFO]: [STDERR]: java.lang.NullPointerException: Cannot invoke "org.bukkit.Server.getTPS()" because "org.bukkit.Bukkit.server" is null
[09:24:38 INFO]: [STDERR]: at org.bukkit.Bukkit.getTPS(Bukkit.java:2385)
[09:24:38 INFO]: [STDERR]: at com.destroystokyo.paper.gui.RAMDetails.update(RAMDetails.java:62)
[09:24:38 INFO]: [STDERR]: at com.destroystokyo.paper.gui.GuiStatsComponent.lambda$new$0(GuiStatsComponent.java:27)
[09:24:38 INFO]: [STDERR]: at java.desktop/javax.swing.Timer.fireActionPerformed(Timer.java:311)
[09:24:38 INFO]: [STDERR]: at java.desktop/javax.swing.Timer$DoPostEvent.run(Timer.java:243)
[09:24:38 INFO]: [STDERR]: at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:318)
[09:24:38 INFO]: [STDERR]: at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:773)
[09:24:38 INFO]: [STDERR]: at java.desktop/java.awt.EventQueue$4.run(Ev...
This is likely a bug in the GUI calling into getTPS before the server is initialized.
If the GUI isn't important to you, and you prefer to use console or log files, then adding the flag --nogui will work around this issue for now, but it should still be fixed.
I've looked into it a little more, the API of Bukkit.getServer, which getTPS uses, is annotated not-null, so presumably the GUI is getting started earlier then it should.
I tried to add a defensive check to the GUI, as it doesn't seem to interact with many other Bukkit API's, but since the API is labelled not-null, it forced me to rethink whether the API should ever return null, even early.
But if it's assumed that the main consumers of the API are Spigot plugins, then I can understand labelling it not-null.
But with the introduction of Paper Plugins, I'm forced to wonder if the early bootstrapping of paper plugins give other opportunities for the server to be null, and that it's the annotation that's incorrect.
This isn't the low hanging fruit PR bugfix I thought it was.
The async profiler does not support java 23, either use j21/22, or disable
the async profiler in sparks settings (or, disable spark)
On Sat, 12 Oct 2024 at 09:03, LinuxMilanGithub @.***>
wrote:
Stack trace
The output in the console:
Exception in thread "AWT-EventQueue-0" [09:24:38 INFO]: [STDERR]: java.lang.NullPointerException: Cannot invoke "org.bukkit.Server.getTPS()" because "org.bukkit.Bukkit.server" is null
[09:24:38 INFO]: [STDERR]: at org.bukkit.Bukkit.getTPS(Bukkit.java:2385)
[09:24:38 INFO]: [STDERR]: at com.destroystokyo.paper.gui.RAMDetails.update(RAMDetails.java:62)
[09:24:38 INFO]: [STDERR]: at com.destroystokyo.paper.gui.GuiStatsComponent.lambda$new$0(GuiStatsComponent.java:27)
[09:24:38 INFO]: [STDERR]: at java.desktop/javax.swing.Timer.fireActionPerformed(Timer.java:311)
[09:24:38 INFO]: [STDERR]: at java.desktop/javax.swing.Timer$DoPostEvent.run(Timer.java:243)
[09:24:38 INFO]: [STDERR]: at java.desktop/java.awt.e...
I tried using OpenJDK 22.0.3 but got the same issue again, so it didn't fix the error.
Sorry, my comment was regarding the GUI NPE, not the sigsev that the title mentions.
Provide the full log from 22
On Sat, 12 Oct 2024 at 10:28, Milan Bauer @.***> wrote:
I tried using OpenJDK 22.0.3 but got the same issue again, so it didn't
fix the error.โ
Reply to this email directly, view it on GitHub
https://github.com/PaperMC/Paper/issues/11490#issuecomment-2408474502,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJMAZAJ43PZ6X4Q22BQCB3Z3DTULAVCNFSM6AAAAABP2FZNZ6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIMBYGQ3TINJQGI
.
You are receiving this because you commented.Message ID:
@.***>
If I use OpenJDK 22.0.3 it wont instantly crash like in OpenJDK 23, so it will take some time to get the full crash report of OpenJDK 22.0.3
Expected behavior
No error
Observed/Actual behavior
This is a snippet of the code of the Axiom plugin by Moulberry.
It seems to currently lead to errors in the console that read like this: [19:49:46 ERROR]: Tried to load invalid item: 'Item must not be minecraft:air'
In the developer's own words:
This code here uses parse and falls back to ItemStack.EMPTY, but it does not prevent the ItemStack.LOGGER.error call in parse
So if parseOptional is given a (valid) empty ItemStack, an error message will be erronously printed
I hope that's enough of an explanation of the bug, otherwise feel free to ask.
Steps/models to reproduce
I hope I explained it above?
Plugin and Datapack List
I hope this isn't really required as we already narrowed it down to Axiom
Paper version
[Sat 09:42:06 INFO ] Checking version, please wait...
[Sat 09:42:06 INFO ] This ser...
The logfile of OpenJDK 22.0.3 is here:
https://paste.gg/p/anonymous/9507b1bf7eb24fbaaab35ee5730313cb
It was just going out this is a vanilla error message so I'll close this issue again.
The validity of empty itemstacks in the context of a CompoundTag representation is kind of up in the air.
Additionally, using internals isn't really on us? The exposed byte[] serialization methods in paper do not accept empty item stacks as input so, axiom is already doing something scuffed to get that compound tag in the first place.
The log message there is useful for other potentially malformed items, we cannot just remove it.
Given axiom already makes heavy use of NMS for this, and the CODEC on ItemStack is public, I'd suggest a simplistic fix of
- net.minecraft.world.item.ItemStack nmsStack = net.minecraft.world.item.ItemStack.parseOptional(MinecraftServer.getServer().registryAccess(), tag);
+ net.minecraft.world.item.ItemStack nmsStack = net.minecraft.world.item.ItemStack.CODEC.pars...
The validity of empty itemstacks in the context of a CompoundTag representation is kind of up in the air.
Additionally, using internals isn't really on us? The exposed byte[] serialization methods in paper do not accept empty item stacks as input so, axiom is already doing something scuffed to get that compound tag in the first place. The log message there is useful for other potentially malformed items, we cannot just remove it.
Given axiom already makes heavy use of NMS for this, and the CODEC on ItemStack is public, I'd suggest a simplistic fix of
net.minecraft.world.item.ItemStack nmsStack = net.minecraft.world.item.ItemStack.parseOptional(MinecraftServer.getServer().registryAccess(), tag);
net.minecraft.world.item.ItemStack nmsStack = net.minecraft.world.item.ItemStack.COD...
Provide the full log from 22
โฆ
On Sat, 12 Oct 2024 at 10:28, Milan Bauer @.> wrote: I tried using OpenJDK 22.0.3 but got the same issue again, so it didn't fix the error. โ Reply to this email directly, view it on GitHub <#11490 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJMAZAJ43PZ6X4Q22BQCB3Z3DTULAVCNFSM6AAAAABP2FZNZ6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIMBYGQ3TINJQGI . You are receiving this because you commented.Message ID: @.>
https://paste.gg/p/anonymous/9507b1bf7eb24fbaaab35ee5730313cb
Going back and adding this is something that we will generally not do, however, somebody externally iirc did put the effort in, it's just not tenable to maintain such a patch in the current repo state
Discussion Category: Ideas
That crash report from 22 didn't even get to the part of loading paper, the process was seemingly intentionally killed by itself, potentially from libc. this would generally be an environmental issue, the GUI crash is weird, but, without full logs, all I can maybe do is assume that something in your environment caused it to blow up in an unexpected manner .
I mean the alternative would be to go to spigot and convince them to do it, then paper would only have to do it on API they added which would be much more maintainable. Generally I think (lynx talked about it someday) they might add it - once the repo restructure happened - to paper-added API classes.
Discussion Category: Ideas
Generally, LGTM.
Moved the impl of getOrDefault back to the impl, as that is where it lives in upstreams impl.
Only thing left to discuss pre-merge imo is a potential javadocs warning about how the impl works, given the pdc getter itself does not do IO but every query to it does, which might throw people off compared to the usual behaviour of OfflinePlayer, which does all its IO on the method itself and then returns a snapshot (e.g. location or metadata lists)
With timings disabled by default now and deprecated for future removal in #11128, I'll close this PR, sorry cat </3
[PaperMC/Paper] branch deleted: timings/use-internals
Expected behavior
Wither Explosion in a Wither Rose Farm should damage and kill an Enderman dropping a Wither Rose.
Observed/Actual behavior
Wither Explosion does not damage Enderman at all, Enderman entity cram to death and drop pearls, despite Wither shooting Explosions next to them.
Steps/models to reproduce
- Be on a Paper/Purpur Server
- Build Shulkercrafts Wither Rose Farm
- Watch as Wither doesnt damage Enderman with explosions.
Plugin and Datapack List
Paper Plugins: (2):
FancyNpcs, HuskHomes
Bukkit Plugins: (63):**
ajLeaderboards, ArcadeGames, AutoMessage, BattlePass, BentoBox, BentoBox-AOneBlock, BentoBox-BSkyBlock, BentoBox-Challenges, BentoBox-Level, BentoBox-MagicCobblestoneGenerator, BentoBox-TopBlock, BlueBridgeCore, BlueBridgeGP, BlueBridgeWB, BlueBridgeWG, BlueMap, BlueMapDeathMarkers, BonesToBoneBlocks, BoundlessForging, ChatGames, CoreProtect, CoreProtectTNT, DecentHolograms, DiscordSRV...
Presumably a plugin issue?
Running this on a plugin-less paper server has the farm correctly produce wither roses.
Do you have any other replication steps? Otherwise I'll consider this as cannot-reproduce.
Is your feature request related to a problem?
It's kind of related to a problem. I know you can set the command properties in plugin.yml, but since you can also set description within the code, I think it would be a great Idea to make the "Usage" property, which can beprinted via "/help command", also adjustable within the code.
For example I want to make a plugin with a simple /spawn command, that doesn't take any arguments. But in the "/help spawn" text it reads: "Usage: spawn [<args>]" and as far as I can see it there is no way except the plugin.yml to override this. (but maybe I'm just beeing dumb)
I also think there should be a "/" before the "spawn", because all the other commands have that.
Describe the solution you'd like.
The "Commands" interface has a function with several overloads to match the appropiate command registration, so add another overload to configure th...
Discussion Category: Ideas
4430e96 Add AnvilView#bypassEnchantmentLevelRestriction... - Doc94
While technically useless nitpick, this would fail if the annotation was present on the inner class but not on the outer one?
E.g. this may instead have to be something like
private static boolean isClassNullMarked(@NotNull ClassNode clazz, @NotNull Map<String, ClassNode> allClasses) {
if (isClassNullMarked0(clazz)) return true;
String parentClass = clazz.nestHostClass;
while (parentClass != null) {
final ClassNode parentClassNode = allClasses.get(parentClass);
if (parentClassNode == null) return false;
if (isClassNullMarked0(parentClassNode)) return true;
parentClass = parentClassNode.nestHostClass;
}
return false;
}
if we truely care about supporting inner types correctly in this. Not that that is really important lol
Ther eis programatically no use case for modifying the Usage of a command outside of to other plugins accessing this stuff, at the point at which this occurs, this is far too late. if you want to setup stuff programmatically, define your commands programmatically and set the usage message there, that should apply to the help map, otherwise, you'd need to see if you can mess with the HelpMap, which wasn't really well designed for mutating stuff in there, and there is little interest from me in toying with the help map, it really should just go.
Discussion Category: Ideas
Well I guess assuming you were running the server on the same Purpur Version without Plugins, it very well could be a plugin issue.. which means "Yayyyy hours of testing!" lol.. but if thats the case then yeah i guess you can close this. Strange though. Havent added any new plugins, or updated in a while, seems to just have stopped working suddenly.
Would you have any insight on where I can begin if its plugin related. Id first assume World Guard, or Coreprotect.. but like i said havent touched/updated those in a bit so idk why it would break suddenly.
Obviously I tested this on paper, not purpur, as this is the paper GitHub issue tracker. I'd suggest just binary searching your plugins/maybe doing a quick sanity check if it does work for you using stock paper on a new server with the linked map and default settings, but beyond that, binary search.
See https://docs.papermc.io/paper/basic-troubleshooting#binary-search
welp okay
Discussion Category: Ideas
i had the same issue recently, it only works for me with disabled spark.
i'm running the server on android with termux though so my guess is that this is similar to the issues i've had with getting docker to run, where programs don't have access to PIDs and some other low level functions in the kernel which might be required for spark.
Stack trace
https://paste.gg/p/anonymous/5bff65bd350645aeb45bcafc11a07598
Plugin and Datapack List
No plugin
Actions to reproduce (if known)
cause: lg 32gn600-b monitor. it turns off ittself at iddle and make mouse dissapear. this cause the server sometimes crash, but now i got the message
Paper version
This server is running Paper version 1.21-130-master@b1b5d4c (2024-08-10T10:02:42Z) (Implementing API version 1.21-R0.1-SNAPSHOT)
You are running the latest version
Other
No response
If you are having issues in Docker, a lot of the OS container images are super stripped down, and using a different one might work.
For now, test with spark disabled, and see if it still crashes on Java 22: https://docs.papermc.io/paper/reference/global-configuration#spark_enabled
Sorry for the wrong lead, I'm not running it in docker. I'm just straight up running the paper.jar file.
(Docker doesn't work on android in general, unless i compile the kernel with certain features enabled. but that's not paper's fault.)
I do not have any chat spam/filtering system
I have multiple services that I have dockerized, including the vanilla Minecraft server that I've built off a very basic OpenJDK image from dockerhub, I'd post a link to the base image, but I don't know your rules on external links. I use a dockerized nginx as a reverse proxy to access them all, and handle SSL, though TCP streams don't use SSL certs. my reverse proxy also handles connections to the minecraft container. It's very basic:
# /etc/nginx/stream.d/default.conf server { listen 25565; proxy_pass minecraft:25565; }Further up the chain, if you want to see where streams are declared on the same level as http, I have this:
# #/etc/nginx/nginx.conf stream { include /etc/nginx/stream.d/*.conf; }You can actually see in the logs that everyone has the same IP, I was guessing that might be due to the reverse proxy, and it hadn't caused problems before, and it's...
There is an open issue on OpenJDK regarding this JDK-6840067 which is unresolved and unconfirmed
Yea, We can probably catch it or something, 'tis an annoying one
Add run configurations to intellij that run the gradle server tasks. More can be added.
It's just convenient to not have to add them yourself when debugging or building repeatedly.
I don't know how useful I find such a change, at least not for my workflow.
It removes the need for three to four clicks but instead adds "random" run configurations for people that might have a different naming schema. I'll leave it open for some other team members to chime in, I don't have a strong opinion on this either way.
should be fixed in #10804 incase you want to test it (would be nice if a team member could slap an build-pr label on that)
Todo: look at removing piercingEntityIds since that seems to be in use somewhere else (too lazy rn)
The collection returned from getEntityHitResults is immutable, causing this to throw an exception.
Indentation should be 4 spaces wide, javadoc description and nullable annotations are missing (and should be jspecify ones)
Missing ApiStatus$Internal annotation on the constructor
Single line comment should be enough here
Constant should be uppercased and before the fields
Must have not had the right angle when testing. thanks
Well get around to fully testing it later, for now it compiles and starts.
This is just adding certain Gradle tasks as runs to the IDE, which can be done manually for the tasks someone cares about by running them once from the IJ Gradle menu (after which they will stay in the run menu). I don't see any utility here. Actual IntelliJ run configs that don't invoke Gradle could be interesting but we would likely need to generate the XML directly as the intellij-ext plugin is quite limiting.
I think having isItemNameTooltipEstimatedToBeVisible is too unpredictable because of the already mentioned fact that it is entirely controller by the client and the server doesn't know the tooltip visibility at all
I would suggest only exposing the time in ticks like vanilla already has and plugins can use it like they want
Isn't this vanilla behavior? Perhaps you should try it out in single-player mode first.
https://www.paper-chan.moe/paper-optimization/#mobspawn
it is a single line what are you talking about
I've addressed all issues that have been brought up. Is there anything else left to do before this is merged?
it is a single line what are you talking about
the line is wrapped in // Paper start and // Paper end - just put // Paper - Fire and handle cancellable TickRateChangeEvent at the end of the line ๐
Expected behavior
To not get some wierd entities. To be precise I want nothing to happen with my "minecraft:interaction" so it will stay as it spawned, like this:
Observed/Actual behavior
It does this:
In normal game its impossible to spawn this kind of interaction, and in my case it really matters as the eye line(or whatever this blue line is) is where passengers sit, and after this wierd rotation they go up.
Steps/models to reproduce
- setup server and any plugin that cancels the PlayerInteractAtEntityEvent , for example this plugin:
package com.example.bug;
import org.bukkit.event.EventHandler;
import org.bukkit.event.Listener;
import org.bukkit.event.player.PlayerInteractAtEntityEvent;
import org.bukkit.plugin.java.JavaPlugin;
public final class Bug extends JavaPlugin implements Lis...
This is kind of just a very funny minecraft bug that is exposed by us resending all entity data to correctly sync entities.
TDLR is that the "correct" state you are describing is completely incorrect.
The eye height being 0 on the client is only the case because the pose data is never sent by the server as the default is never changed.
The interaction entities dimension is never recomputed on the client from its default of 0/0, even if the width and height are changed.
I think this is still a worthwhile fix/compliance with mojang logic (mostly because it should be easy) but be aware that the existing code does not actively define the eyeheight of interaction entities to be 0, hence you are relying on a bug.
Brought up during some chatting regarding this PR, but it would probably be worth exposing the entire io.papermc.paper.command.brigadier.CommandSourceStack. Exposes more context over what is essentially a "Someone ran the tick command" event.
aebbdc9 Add proper async player disconnections - Spottedleaf
Is there a way to set eyeheight to 0/0? Or can I manually send client data on how to display it? I don't really care too much where the eyeheight will be. All I really need is to make it consistent after spawning and after clicking it, is there something that might help?
Done
Was the chatting about this PR in a public channel I can see?
The event mix jetbrains and jspecify nullable annotations. And it's a bit iffy when a plugin change the tick rate cause the command executor doesn't receive the right tick rate in the feedback message (unlike the WorldGameRuleChangeEvent for example)
Thanks for the quick fix, no that was just a fleeting discussion in internal channels.
I'll try to make time for merging it this weekend, which usually happens in one of our discord VCs.
Small nitpick: Collectors#toList has undefined mutability. I believe it's almost always implemented to return a mutable list, but maybe use Colllectors#toColllection instead?
Arrows with the intangible_projectile component launched in survival are not consumed.
The client computes the eyeheight as 85% of the height when it refreshes its dimension.
So no, you'd have to resend the entity data with a height/width of 0 and re-resend the correct width/height afterwards.
Alternatively, a quick hack fix might be
diff --git a/patches/server/1013-Properly-resend-entities.patch b/patches/server/1013-Properly-resend-entities.patch
index 148750ed5..671b436cb 100644
--- a/patches/server/1013-Properly-resend-entities.patch
+++ b/patches/server/1013-Properly-resend-entities.patch
@@ -102,7 +102,7 @@ index 0034483685ba626e5883b857de96ffd36e57e150..4c04eb531b6989f7e618d201ecaa8429
}
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
-index 3a90dd1289d393426151d4457edaf99731cc34db..ec058eb6a10500831f173dcb47576c32c7516318 100644
+index 65f2cad4b5df6a89373fb69edfc7d488d0fdcbed..613e66e1abb2cddb9f39f8ac255b1eb493915beb 100644
--- a/s...
This likely is vanilla behaviour.
However, you are using Purpur anyways as your build number gives away. Please do not open issues on the Paper issue tracker for software that isn't ours.
do you have an ETA on when this should be implemented, you also said you would write a walkthrough for the issue and someone else has reported a possible fix I believe mentioning this issue report
We don't have an ETA for this, yea I did not get to my walk through.
I'll try to look at it this weekend, but I am unsure if there is a solution that is easy without breaking a shit ton of plugins.
thanks for the reply i appreciate you taking a look at it as its caused mass issues for vanilla pvp lol
I'll fix the notations but I don't understand your second concern, what exactly is the problem? That the message returned to the player won't reflect the new tick rate?
malware? what is this huge gibberish patch?
That is a binary patch for the server icon that was changed because leafs git setup is funny.
Will be reverted once someone with a normal git setup merges things ๐
Paper events go in the paper package
That the message returned to the player won't reflect the new tick rate?
Yes, the server prints the output of the tick rate, and yet, if a plugin mutates it, this value will be wrong; if we want to support mutation, the logic should be adjusted to get the new rate so that the message is displayed properly, rather than having invisible side-effects to end users
Timings or Profile link
N/A
Description of issue
Discussed internally- no timings link or plugin list. This is an issue created so I can reference it in a near-future PR.
Commit 0ed4b91 reverts ThreadPoolExecutor to
Executors#newCachedThreadPoolwhich was changed to solve an issue of hanging logins. The problem with both, as discussed, is that both have the unfortunate side-effect of using one thread in the pool when combined with an unbounded queue. In the case of ServerLoginPacketListenerImpl this means that ALL logins are sent to the same thread regardless of how many threads the pool has available.Discussions lead to a few different solutions, but after looking at the benefits and drawbacks of each solution the easiest fix is to use a fixed thread pool (a new ThreadExecutor where the core pool size is equal to the maximum pool size).
Other resolutions di...
The exception comes from the FutureChain, the new future that is appended is already running in the chat thread, and the thenAcceptAsync tries to schedule a new task on the same executor that is currently busy.
The chat executor is a ThreadPoolExecutor using a SynchronousQueue, that means it can only schedule tasks if there is a thread waiting for one, and given the max pool size is 1 and that thread is currently busy, it rejects the task.
Not entirely sure how this busts the chain
Again, I try to promote this to the masses as much as possible. For blocking I/O, it is easier and best to use virtual threads! An OS thread is an expensive resource, there is a big fight for it in the scheduler. This solution will solve A LOT of problems. First, we will not need to manually configure the pool size, since it will often be the size of real hardware threads, on the JVM. At the moment, virtual threads work on ForkJoinPool, which is also very good. a) FJP itself is tuned for virtual th...
This isn't blocking IO, utilising vthreads will fix nothing here, this is not the place for your soap box
This isn't blocking IO, utilising vthreads will fix nothing here, this is not the place for your soap box
as far as i know, the problem is related to the fact that 1 threads in the pool can't be woken up by anyone. This is exactly what i'm talking about. creating such threads for every sneeze. for insurance - is a bad solution. This is illiterate planning, which is broken by such configurations
For blocking I/O
This has nothing to do with blocking operations, VTs will not help here, if
anything they would hinder the FJP that schedules VTs and with something
like chat it's very easily DDoSable for CPU bound tasks as opposed to a
task queue on its own platform thread.
Third, simpler and more understandable code, without react
CompletableFuture
You still need a form of continuations given the linked/queued demand of
the chat chain, CF offer such mechanism, even with VTs you need to ensure
that one message gets processed after the other, not in some arbitrary.
On Thu, 17 Oct 2024, 19:10 Sunmisc Unsafe, @.***> wrote:
The exception comes from the FutureChain, the new future that is appended
is already running in the chat thread, and the thenAcceptAsync tries to
schedule a new task on the same executor that is currently busy.
The chat executor is a ThreadPoolExecutor using a SynchronousQueue, that
means it can only schedule tasks if th...
The issue is that the only thread that takes care of things in that pool
cannot take any more tasks because of the kind of queue it uses under the
hood. The thread is awake and is currently busy, so it can't enqueue to
itself a new task for later.
On Thu, 17 Oct 2024, 19:21 Sunmisc Unsafe, @.***> wrote:
This isn't blocking IO, utilising vthreads will fix nothing here, this is
not the place for your soap boxas far as i know, the problem is related to the fact that 1 threads in the
pool can't be woken up by anyone. This is exactly what i'm talking about.
creating such threads for every sneeze. for insurance - is a bad solution.
This is illiterate planning, which is broken by such configurationsโ
Reply to this email directly, view it on GitHub
https://github.com/PaperMC/Paper/issues/10813#issuecomment-2420719952,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AIPXWBCHOPU7B7JCWTQFOLLZ4AZ43AVCNFSM6AAAAABIOAUTS6VH...
if that's the case, then this PR is inherently blocked as it makes little sense for us to finalise the review and such of this into a state we're happy to merge it if we're going to potentially have to deal with breaking ABI changes from upstream
Which will inherently be the case as spigot does not expose the CommandSourceStack this event now provides.
Would be great if you can come to a decision whether or not you want to have this event in spigot-api soonish then. As cat mentioned, if this is going upstream, there is 0 point in this PR receiving reviews on paper and we can close it instead.
For blocking I/O
This has nothing to do with blocking operations, VTs will not help here, if anything they would hinder the FJP that schedules VTs and with something like chat it's very easily DDoSable for CPU bound tasks as opposed to a task queue on its own platform thread. And you are taking up threads that blocking operations can actually take advantage on by sharing the thread amongst them.
Third, simpler and more understandable code, without react CompletableFuture
You still need a form of continuations given the linked/queued demand of the chat chain, CF offer such mechanism, even with VTs you need to ensure that one message gets processed after the other, not in some arbitrary.
โฆ
On Thu, 17 Oct 2024, 19:10 Sunmisc Unsafe, @.***> wrote: The exception comes from the FutureChain, the new future that is appended is already running in the chat thread, and the thenAcceptAsync tries to schedule a new task on the same executor that is currently busy. The chat ...
We are not rewriting mojangs chat system
On Fri, 18 Oct 2024 at 09:47, Sunmisc Unsafe @.***>
wrote:
For blocking I/O
This has nothing to do with blocking operations, VTs will not help here,
if anything they would hinder the FJP that schedules VTs and with something
like chat it's very easily DDoSable for CPU bound tasks as opposed to a
task queue on its own platform thread. And you are taking up threads that
blocking operations can actually take advantage on by sharing the thread
amongst them.
Third, simpler and more understandable code, without react
CompletableFuture
You still need a form of continuations given the linked/queued demand of
the chat chain, CF offer such mechanism, even with VTs you need to ensure
that one message gets processed after the other, not in some arbitrary.
โฆ <#m_-5447267336639540058_>
On Thu, 17 Oct 2024, 19:10 Sunmisc Unsafe, @.*> wrote: The exception
comes from the FutureChain, the new future th...
We are not rewriting mojangs chat system On Fri, 18 Oct 2024 at 09:47, Sunmisc Unsafe @.**> wrote:
โฆ
For blocking I/O This has nothing to do with blocking operations, VTs will not help here, if anything they would hinder the FJP that schedules VTs and with something like chat it's very easily DDoSable for CPU bound tasks as opposed to a task queue on its own platform thread. And you are taking up threads that blocking operations can actually take advantage on by sharing the thread amongst them. Third, simpler and more understandable code, without react CompletableFuture You still need a form of continuations given the linked/queued demand of the chat chain, CF offer such mechanism, even with VTs you need to ensure that one message gets processed after the other, not in some arbitrary. โฆ <#m_-5447267336639540058_> On Thu, 17 Oct 2024, 19:10 Sunmisc Unsafe, @.> wrote: The exception comes from the FutureChain, the new future that is appended is already running in t...
Vthreads are not a magical solution; bounding everything to a shared thread
pool makes no sense for work that does not take advantage of the ability to
pause efficiently; outside of those use cases, vthreads offer practically
no real advantage to what is computational work, which does not utilise the
triggers that Vthreads exist to take advantage of.
People will continue to use their own pools for the lifecycle advantage
that they offer. They aren't going to blindly rush out to utilise a feature
that doesn't offer any distinct advantage to them, especially when it comes
with a whole host of untested caveats, especially in an ecosystem they do
not have full control over.
On Fri, 18 Oct 2024 at 09:56, Sunmisc Unsafe @.***>
wrote:
We are not rewriting mojangs chat system On Fri, 18 Oct 2024 at 09:47,
Sunmisc Unsafe @.*> wrote: โฆ <#m_2704420606008294549_> For blocking I/O This has nothing to
do with blocking operations, VTs will not help here, if...
Expected behavior
When teleporting a player with RETAIN_VEHICLE it should teleport the player with the vehicle
Observed/Actual behavior
When teleporting the player, it desyncs and does not teleport player or Minecart
As clip shows when then you dismount the vehicle, it moves the player to the given location, but vehicle is left behind
On dismount it also calls the PlayerTeleportEvent again as shown by console log
Removing the RETAIN_VEHICLE flag correctly teleports player, but leaves vehicle behind
https://github.com/user-attachments/assets/6785722a-e849-479a-b78e-a4e9f9dbed58
Steps/models to reproduce
- Listen to VehicleMoveEvent
- Filter passengers to players and teleport to XYZ with RETAIN_VEHICLE flag
Plugin and Datapack List
[11:10:28 INFO]: Server Plugins (1):
[11:10:28 INFO]: Bukkit Plugins:
[11:10:28 INFO]: - TeleportAsyncTest
Paper version
[11:10:17 INFO]: Checking version, please wait...
[11:10:17 INFO]: This server is running ...
In my tests (1 player, high render distance) it lowered heap dump size from 928MB to 872M.
Considering that like 400MB of that was Folia itself, empty IBlockDataList structures are probably nearly 10% of RAM usage of many servers.
This would likely want to be PR'd to moonrise and then ported over, too
In my tests (1 player, high render distance) it lowered heap dump size from 928MB to 872M.
Considering that like 400MB of that was Folia itself, empty IBlockDataList structures are probably nearly 10% of RAM usage of many servers.
As cat stated on your initial PR, this should probably be PRed to https://github.com/Tuinity/Moonrise and then ported to paper once accepted there.
I didn't even know moonrise was a thing. ๐ All I really did was to follow the convention.
Since I'm definitely not gonna learn how to Mixin and stuff, I guess I'll just remove all incorrect associations with moonrise. After all, it's not their code.
In my tests (1 player, high render distance) it lowered heap dump size from 928MB to 872M.
Considering that like 400MB of that was Folia itself, empty IBlockDataList structures are probably nearly 10% of RAM usage of many servers.
Any update on this? I'd really like to either merge or close this depending on your decision regarding moving this to upstream.
Vthreads are not a magical solution; bounding everything to a shared thread
pool makes no sense for work that does not take advantage of the ability to
pause efficiently; outside of those use cases, vthreads offer practically
no real advantage to what is computational work, which does not utilise the
triggers that Vthreads exist to take advantage of.People will continue to use their own pools for the lifecycle advantage
that they offer. They aren't going to blindly rush out to utilise a feature
that doesn't offer any distinct advantage to them, especially when it comes
with a whole host of untested caveats, especially in an ecosystem they do
not have full control over.On Fri, 18 Oct 2024 at 09:56, Sunmisc Unsafe @.***>
wrote:We are not rewriting mojangs chat system On Fri, 18 Oct 2024 at 09:47,
Sunmisc Unsafe @.*> wrote: โฆ <#m_2704420606008294549_> For blocking I/O This has nothing to
do with blocking operations, VTs w...
why create list when just trying to remove an entry?
why create that list here? why not check for null at the caller?
Because if this.tickingBlocks is null, a call to this.tickingBlocks.remove() would crash immediately.
In theory there shouldn't really be any calls to remove when there are no tickingBlocks... But I decided to create the structure, just to not modify the original behavior.
It could be changed to if (this.tickingBlocks != null) this.tickingBlocks.add(x, y, z, state);, but I decided just creating it is simpler (1 loc vs 3 loc).
Because I wanted to leave the functionality intact.
The function expects to return an IBlockDataList, so I made it return IBlockDataList.
"Sometimes" returning null here would be bad practice and could introduce unknown bugs if someone ever uses it from some unexpected place.
In practice the only call to getTickingBlockList() never executes because if(anyTickingBlocks() == false) continue; is executed before it.
I've restructured this PR so that mutations will be reflected in return values.
I've decided to leave it in paper. Are there any other changes you'd like me to make?
Well as cat stated, the event should be in the paper event package
It has nothing to do with tags, consider renaming to maxSize instead.
Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing
Bukkit Changes:
bb4e97c6 Add support for Java 23
bc6874dd Bump asm to 9.7.1
50e8a00b PR-1064: Add specific getTopInventory methods for InventoryView derivatives
758b0a0f SPIGOT-7911: Fix Location#isWorldLoaded() for re-loaded worlds
133a64a7 Improve Registry#getOrThrow messages
be0f5957 PR-1058: Add tests for Minecraft registry <-> Bukkit fields
d1b31df2 PR-1062: Clarify BeaconView documentation
3fab4384 PR-1060: Cache Material to BlockType and ItemType conversion
967a7301 SPIGOT-7906: Increase YAML nesting limit to 100
6ecf033d SPIGOT-7899: Smithing recipes don't require inputs
CraftBukkit Changes:
0a7bd6c81 PR-1493: Improve reroute performance and add some tests
54941524c Add support for Java 23
f4d957fff SPIGOT-7915: Fix World#getKeepSpawnInMemory() using Spawn Radius rather than Spawn Chunk Radius
ded183674 Fix ...
Update spark-paper to v1.10.110.
Update spark-paper to v1.10.110.
Expected behavior
it should loaded correctly (by skip remapping task or we can add a value in plugin.yml to disable plugin remapping)
Observed/Actual behavior
plugin doesn't load by the server unless I add -Dpaper.disablePluginRemapping=true to JVM flags
[12:18:58 INFO]: [PluginRemapper] Remapping plugin 'plugins\Wind-1.30.3.jar'...
[12:18:58 ERROR]: [PluginRemapper] Encountered exception remapping plugins
java.util.concurrent.CompletionException: java.lang.RuntimeException: Failed to remap plugin jar 'plugins\Wind-1.30.3.jar'
at java.base/java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:315) ~[?:?]
at java.base/java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:320) ~[?:?]
at java.base/java.util.concurrent.CompletableFuture$UniApply.tryFire(CompletableFuture.java:649) ~[?:?]
at java.base/java.util.concurrent.CompletableFuture$Completion.run(CompletableFuture.java:482) ~[?:?]
...
Duplicate of #11005, see the recommendations in the comment there
I have recommendation instead of just a post the issue.
Why don't we just add an option to disable-remapping in plugin.yml?
You can mark your plugin as being mojmap compatible to skip the remapper, but, you really should fix your jar file being improperly packaged
I don't have the source code.
if you can modify the plugin.yml you can modify/add the META-INF/MANIFEST.MF file manually to add that metadata manually
if you can modify the plugin.yml you can modify/add the
META-INF/MANIFEST.MFfile manually to add that metadata manually
We are adding paperweight-mappings-namespace: spigot to MANIFEST.MF but it does not change anything.
spigot is the assumed default, given that we use mojmap, we'd need to remap anything that is spigot mapped; utilise the mojang one to say that it's already mapped in a supported manner for your server
spigot is the assumed default, given that we use mojmap, we'd need to remap anything that is spigot mapped; utilise the mojang one to say that it's already mapped in a supported manner for your server
Even when its paperweight-mappings-namespace: mojang+yarn, Paper tries to remap it.
14ad1b8 Some small touchups to the GUI - electronicboy
[PaperMC/Paper] New branch created: fix/gui-booms
Fixes #11494 - As noted on the issue, the method here can blow up in certain cases, the GUI logic already handles "the mouse is missing", and so, we'll just catch this and move on.
Misc fix - There is probably an issue report for this somewhere, but, the details section utilised the bukkit singleton to try to get the TPS from the server. We already have the MinecraftServer instance passed into us, and so we'll just get the information directly from there instead.
I have created a PR which solves the GUI error, but we don't support running the server in such environments as Android. The userspace images and packages provided by these redistributions are often broken in various and interesting ways; given that we're not an Android team, we do not have the capability or desire to dedicate time and resources to diagnosing issues in these environments, especially when in the case of 22, you didn't even get to the point where the JVM has loaded the paper jar.
does the banner update if you relog? I think that this is a client bug
13efdd5 Always send Banner patterns to the client (Fixe... - electronicboy
[PaperMC/Paper] New branch created: fix/banner-be-patterns
[PaperMC/Paper] Pull request opened: #11506 Always send Banner patterns to the client (Fixes #11487)
The mojang client will not remove patterns from a Banner when none
are sent inside of an update packet, given that this is not an expected
flow for them, this is not all too surprising. So, we shall resort to always
sending the patterns over the network for update packets.
the only thing i wish would happen is for the profiler to be deactivated automatically if it breaks, maybe some other potential cases might benefit from that too, not limited to running on android
The JVM blew up, outside of trying to use flag files on the disk we have little ways of detecting when that fails
3b9db2b Updated Upstream (Bukkit/CraftBukkit) (#11501) - lynxplay
c13f9fd Fix potential annotation testing interruption (... - LemonCaramel
Thanks for the PR but we reserve dependency updates (especially ones as non-impactful as this one) to the team.
Additionally, the version does not seem to be deployed rn.
260c3bb Always send Banner patterns to the client (#11506) - electronicboy
[PaperMC/Paper] branch deleted: fix/banner-be-patterns
After some chatter with the team, I are not going to pull a PR that modifies moonrise-only logic.
Patching over moonrise in this matter means additional upkeep during moonrise updates, which are already a pain to begin with.
We'll expand the contribution documentation to make this clear, but this diff belongs into moonrise.
If you do not feel comfortable with contributing it to moonrise yourself due to the mixins usage over patches, I can offer to pick up that work and open the respective PR on the project some time next week, with you as the author :+1:
Obviously does not mean this change is something 100% accepted into moonrise, but yea.
Hope you understand my reasons for closing this and thank you for the generally smart contribution, even if it was the wrong project :sweat_smile:
14a48cd Some small touchups to the GUI (#11505) - electronicboy
[PaperMC/Paper] branch deleted: fix/gui-booms
I do ponder if we should move the set over to mc-util, but, otherwise, this lgtm
If you do not feel comfortable with contributing it to moonrise yourself due to the mixins usage over patches, I can offer to pick up that work and open the respective PR on the project some time next week, with you as the author ๐
It makes perfect sense to go Moonrise -> Paper in this case.
Unfortunately learning Forge and Mixins and yet another software is something I don't really have time for. Perfectly happy for someone else to implement it - it's a very simple patch anyway. โค๏ธ
Prevent trident to be counted as valid for CraftBlockProjectileSource#launchProjectile and be launched as arrow instead.
what are the advantages of using a delegate in this case?
it's a reusable generic container wrapper class
The fact that we can reuse this type for different set implementations. The previous implementation would lock the type into the speed/contracts of hashset.
Is your feature request related to a problem?
when a player(or Console) execute command, Record the output and provide a method to get the message, I think sometimes this will be useful especially when this command is related to DataPacks, /execute, /trigger or /function etc.
Describe the solution you'd like.
In Class ExecuteCommandEvent, add a mathod like getResult()(or one more setting method setResult())
Describe alternatives you've considered.
Using NMS, but i think this usually not recommended.
Other
No response
Discussion Category: Ideas
I mean, doesn't the AsyncChatCommandDecorateEvent serve this purpose?
Discussion Category: Ideas
Well, there is such a way,I never thought about it.Thank you.
Discussion Category: Ideas
I will try it after that.
Discussion Category: Ideas
Is your feature request related to a problem?
Update Paper to 1.21.2.Keep up with the Spigot and add the pouch at the same time.
Describe the solution you'd like.
Update Paper to 1.21.2.
Describe alternatives you've considered.
Use Spigot.
Other
No response
Discussion Category: Ideas
Other alternatives: Hardfork
Discussion Category: Ideas
[PaperMC/Paper] New branch created: dev/1.21.2
e080b20 Bundles are no longer experimental (thanks lynx) - NoahvdAa
to keep server performance high it's very important to remove unneeded whitespace
- [ ] Check in on EntityZapEvent implementation, heavy overload usage in Mob#convertTo
Expected behavior
[03:26:51 INFO]: [TestPlugin] Key: 0.1 Val: 5
[03:26:51 INFO]: [TestPlugin] Key: 0.2 Val: 10
[03:26:51 INFO]: [TestPlugin] Key: 1 Val: 20
Observed/Actual behavior
[03:26:51 INFO]: [TestPlugin] Key: 0Val: MemorySection[path='0', root='YamlConfiguration']
[03:26:51 INFO]: [TestPlugin] Key: 1Val: 20
Steps/models to reproduce
1. Load up a test plugin with the following code
public final class TestPlugin extends JavaPlugin implements Listener {
@Override
public void onEnable() {
getServer().getPluginManager().registerEvents(this, this);
saveDefaultConfig();
reloadConfig();
getConfig().getValues(false).forEach((key, val) -> getLogger().info("Key: " + key + " Val: " + val));
}
@Override
public void onDisable() {
// Plugin shutdown logic
}
}
2. Use the following config.yml:
"0.1": 5
"0.2": 10
"1": 20
**3. Start the server and observe the...
The issue here is that your keys have .'s in them, and so it's going to treat those in some form of manner as subkeys, you can change the character for the operator on the options configuration object from what I recall
The issue here is that your keys have .'s in them, and so it's going to treat those in some form of manner as subkeys, you can change the character for the operator on the options configuration object from what I recall
But if the key is wrapped in quotes shouldn't the desired behavior be to treat it as one string and avoid doing anything beyond that?
every single call to the get methods are going to split on that key, even if it parsed them raw as-is, you'd never be able to read them
There isn't any real way to fix this from our side. Even if we did fight with the thing to properly parse the keys, you wouldn't be able to access those values without fighting the thing or changing the separator anyway. You'd probably want to consider utilising a configuration library that properly deals with a node tree rather than relying on string manipulation for its accessing methods.
Is your feature request related to a problem?
.
Describe the solution you'd like.
update the version
Describe alternatives you've considered.
.
Other
No response
Discussion Category: Ideas
Is there a way to produce a ClickType MIDDLE with a vanilla client though? as far as i can tell the vanilla client doesn't even send a packet when using a middle click in survival, because of that i think this is actually a vanilla bug that the client sends a packet for the rebound middle click at all
Vanilla bug or not, it would be dangerously fragile API to tie the 'middle click' action to only the middle click press, despite how its currently named.
In fact, the current naming scheme is kinda bad, given the ability to rebind other controls, but I don't think it's necessarily appropriate to change that now, 10 years in, what I don't want to see though, is a mix of "the name reflects the default controls so people understand the action easier" and "the name reflects the actual button being used" side by side.
yeah in my opinion a mojira issue should be created and for the time being the event should either not be called at all for this or the button check from the CLONE case should be removed
Does there need to be an entire new implementation of TrialSpawnerConfiguration? Or should the existing CraftTrialSpawnerConfiguration be modified and check isSnapshot on every setter call instead?
I'm experiencing the same error too.
[05:22:53 ERROR]: [ca.spottedleaf.moonrise.patches.chunk_system.scheduling.NewChunkHolder] Failed to save entity data (10,-995) in world 'survival'
net.minecraft.ReportedException: Saving entity NBT
at net.minecraft.world.entity.Entity.saveWithoutId(Entity.java:2594) ~[purpur-1.21.jar:1.21-2284-4e55e26]
at net.minecraft.world.entity.Entity.saveAsPassenger(Entity.java:2407) ~[purpur-1.21.jar:1.21-2284-4e55e26]
at net.minecraft.world.entity.Entity.saveAsPassenger(Entity.java:2393) ~[purpur-1.21.jar:1.21-2284-4e55e26]
at net.minecraft.world.entity.Entity.save(Entity.java:2423) ~[purpur-1.21.jar:1.21-2284-4e55e26]
at ca.spottedleaf.moonrise.patches.chunk_system.level.entity.ChunkEntitySlices.saveEntityChunk0(ChunkEntitySlices.java:116) ~[purpur-1.21.jar:1.21-2284-4e55e26]
at ca.spottedleaf.moonrise.patches.chunk_system.level.entity.ChunkEntitySlices.saveEntityChunk(ChunkEntitySlices.java:94) ~[purpur-...
I guess those shouldn't be there but fully qualified names should be used instead?
Yea ๐ already fixed locally, but nice spot :)
this has been here since forever, that's how rod and bow crits were possible in 1.7-1.8
Is your feature request related to a problem?
N/A
Describe the solution you'd like.
Add support for the && operator in commands, allowing players to chain multiple arguments in a single command. This would simplify commands such as /title and enable users to combine multiple commands, like:
Example
/title @a title {"text":"hello"} && title @a subtitle {"text":"hello"}
Describe alternatives you've considered.
N/A
Other
N/A
Discussion Category: Ideas
We are not going to modify vanilla command syntax on a platform that already has extensive modding support via plugins.
Discussion Category: Ideas
6df21e6 Start Moonrise update - Spottedleaf
47258a7 Move common diffs to MCUtils - Spottedleaf
ecf4d97 Begin fixing issues - Spottedleaf
8e569ba Merge patches - Spottedleaf
3b31621 Implement config hooks in PaperHooks - Spottedleaf
e9c58f5 Implement chunk tick iteration optimisations - Spottedleaf
2a95ad1 Implement explosion optimisations - Spottedleaf
16d2c9d Implement Starlight - Spottedleaf
3d7b570 Implement chunk system - Spottedleaf
1d341df Fix some compile errors from patches - Spottedleaf
6daedd7 Prepare rebase - Spottedleaf
2e76d3f Specify mainCapabilityAttribute for paper-api - jpenilla
Merged in 1.21.2 dev branch
[PaperMC/Paper] branch deleted: mainCapabilityAttribute
Expected behavior
experiencing the same error too. (https://github.com/PaperMC/Paper/issues/11136)
No errors in console.
[05:27:15 INFO]: Checking version, please wait...
[05:27:15 INFO]: Current Purpur Version: 1.21-2284-4e55e26 (MC: 1.21)*
You are running the latest version
Observed/Actual behavior
n/A
Steps/models to reproduce
[05:22:53 ERROR]: [ca.spottedleaf.moonrise.patches.chunk_system.scheduling.NewChunkHolder] Failed to save entity data (10,-995) in world 'survival'
net.minecraft.ReportedException: Saving entity NBT
at net.minecraft.world.entity.Entity.saveWithoutId(Entity.java:2594) ~[purpur-1.21.jar:1.21-2284-4e55e26]
at net.minecraft.world.entity.Entity.saveAsPassenger(Entity.java:2407) ~[purpur-1.21.jar:1.21-2284-4e55e26]
at net.minecraft.world.entity.Entity.saveAsPassenger(Entity.java:2393) ~[purpur-1.21.jar:1.21-2284-4e55e26]
at net.minecraft.world.entity.Entity.save(Entity.java:2423) ~[purpur-1.21.jar:1.21-2284-4e55e26]
at ca.spottedleaf.moonris...
You're running an unsupported version of not Paper. Reproduce on Paper 1.21.1.
61136fe Add max minecarft speed gamerule config - Spottedleaf
ba1ee87 Revert "Add max minecarft speed gamerule config" - Spottedleaf
cf03bed Add startup flag to disable gamerule limits - Spottedleaf
be2edea Fix boats/minecarts not dropping when destroyed - Spottedleaf
As with the other issue, there is nothing we can do here beyond instructing you to find out what plugin/datapack emitted an oversized itemstack.
Also affects teleporting Vehicle with RETAIN_PASSENGERS fairly consistently
https://github.com/user-attachments/assets/f79c8d6f-5e29-44c5-84bb-8c6eaee2f9bf
Shows it consistently breaking one way until i move a second player into the target-location
Assuming to keep chunk loaded, thus teleport goes from breaking consitently to not breaking
https://github.com/user-attachments/assets/fa7680d5-218b-4d66-b670-f7cdf3a18af1
2946dbb Update WorldServer#serverlevelData mapping - electronicboy
After adding a getChunkAsync before the teleportAsync, it completely seems to fix this and other issues I had here
Expected behavior
Paper 1.8.8 will be identified as a paper version
Observed/Actual behavior
Steps/models to reproduce
create a paper 1.8.8 server and add plugin portal to the /plugin directory
Plugin and Datapack List
CratesPlus, ChatPings, SkinsRestorer, LastLoginAPI, PluginPortal, Parties, ArmorStand-Limiter, Discord-Linker, TabTPS, Votifier, Essentials, EssentialsGeoIP, EssentialsAntiBuild, BetterRTP, EssentialsSpawn, EssentialsProtect,
Paper version
[16:53:27 INFO]: This server is running CraftBukkit version git-PaperSpigot-445 (MC: 1.8.8) (Implementing API version 1.8.8-R0.1-SNAPSHOT)
[16:53:27 INFO]: Checking version, please wait...
[16:53:32 INFO]: Error obtaining version information
Other
No response
Paper 1.8.8 is no longer supported.
Hasn't been tested yet obviously. But this is the general shape this has to take.
Expected behavior
PlayerDeathEvent custom drops are not mutated in any way by the server after the event is handled.
Observed/Actual behavior
PlayerDeathEvent custom drops are mutated into AIR by the server after the event is handled.
Steps/models to reproduce
Given the following (somewhat contrived) example code:
package org.example.plugin;
import org.bukkit.Material;
import org.bukkit.event.EventHandler;
import org.bukkit.event.Listener;
import org.bukkit.event.entity.PlayerDeathEvent;
import org.bukkit.inventory.ItemStack;
import org.bukkit.plugin.java.JavaPlugin;
public class ExamplePlugin extends JavaPlugin implements Listener {
@Override
public void onEnable() {
getServer().getPluginManager().registerEvents(this, this);
}
@EventHandler
public void onPlayerDeath(PlayerDeathEvent e) {
final ItemStack itemStack = new ItemStack(Material.DIAMOND);
// Any custom drops added are affected by this issue
e.getDrops().add(itemStack);
...
additionally this is a plugin portal issue, not a paper one.
Unfortunately not, this bug only appeared after 1.20.6 and is causing a lot of issues regarding damage and the Vanilla/Crystal PvP mechanics
[PaperMC/Paper] New branch created: dev/timings
Just to make it reviewable with a userscript, will merge manually after self-review
[PaperMC/Paper] branch deleted: dev/timings
4d87302 Fix NPE and StackOverflowError for dispensers - Lulu13022002
Expected behavior
Projectiles should pass through the portal (in vanilla since 1.21.2)
Observed/Actual behavior
Projectiles disappear when touching the portal
Steps/models to reproduce
Example video when shooting an arrow through a nether portal
https://github.com/user-attachments/assets/d2a64cd1-216e-4f79-b12b-75413cba3f0f
Plugin and Datapack List
[19:55:17 INFO]: There are 3 data pack(s) enabled: [vanilla (built-in)], [file/bukkit (world)], [paper (built-in)]
[19:55:17 INFO]: There are no more data packs available
[19:55:33 INFO]: Server Plugins (0):
Paper version
[19:52:32 INFO]: This server is running Paper version 1.21.3-DEV-dev/1.21.2@f8f230a (2024-10-27T18:45:43Z) (Implementing API version 1.21.3-R0.1-SNAPSHOT)
You are running the latest version
Previous version: 1.21.3-DEV-4d87302 (MC: 1.21.3)
Other
Upstream (Spigot) is not affected
29bf7be Fix unused parameter in PlayerList#remove - jpenilla
[PaperMC/Paper] New branch created: 1.21.3-legacy-ender-pearls
db9d127 Allow using old ender pearl behavior & apply en... - jpenilla
When enabled, ender pearls will not load chunks and will save to the world instead of the player.
Also changes the exploit config to be default false, as it only makes sense when legacy behavior is enabled.
96cd6a2 Execute spark tasks during tick sleep - jpenilla
[PaperMC/Paper] New branch created: 1.21.3-spark-tasks
Fixes timeout log messages appearing after server goes to sleep
9e35192 Execute spark tasks during tick sleep (#11525) - jpenilla
[PaperMC/Paper] branch deleted: 1.21.3-spark-tasks
Someone else should test it:tm:, but the changes look fine
Bonus points for a telling config name
Config name for what? legacyEnderPearlBehaviour? disableEnderpearlLoadChunks or something like that (I think that's the new behaviour or did I miss something?).
[PaperMC/Paper] New branch created: 1.21.3-sleep-tasks
a2d6c26 Avoid issues with certain tasks not processing ... - jpenilla
Execute processQueue tasks during sleep & unload chunks during sleep
We probably want to tick the global region scheduler too, but not the fallback region scheduler
I chose legacyEnderPearlBehaviour rather than enderPearlsTickChunks as it encompasses more than that, it also affects how pearls are saved and whether they get removed on logout, for example. I think the current name is fine and it should be addressed by docs.
Maybe we could have seperate config options for controlling if they are serialized with the player and tick chunks then?
doing that properly would require much more extensive changes, the behaviors are tightly coupled
I chose
legacyEnderPearlBehaviourrather thanenderPearlsTickChunksas it encompasses more than that, it also affects how pearls are saved and whether they get removed on logout, for example. I think the current name is fine and it should be addressed by docs.
Ok yeah then i don't have another name either.
Naming disablePlayerTickedEnderpearls ? encompasses the fact that enderpearls are loaded and ticked, and player owned by default.
legacyEnderPearlBehaviour is fine IMO. It indicates there has been a change, and people can find more info about it on the docs.
legacyEnderPearlBehavioris fine IMO. It indicates there has been a change, and people can find more info about it on the docs.
As long as enderpearls are never changed again, otherwise you might need a legacyLegacyEnderPearlBehavior.
Personally, anything named 'legacy' or 'old' is a code smell in any coding project, unless it clarifies which legacy behaviour it is almost immediately.
Hi, is there anything left for me to do before this can be merged?
When updating Purpur to the latest dev/1.21.2 commit, there was still some leftover timings calls that were not removed. This PR removes them.
shouldn't the import also be removed?
All unused imports in the BukkitCommandNode class are now removed.
6288adb Remove leftover missed timings calls (#11527) - granny
This is still an issue on latest Paper, I think it was introduced by Aikar's Hopper patch...
here: https://github.com/PaperMC/Paper/blob/master/patches/server/0999-Optimize-Hoppers.patch#L227
This was done for performance reasons? Since it's only changing stack amount I kinda doubt it can impact performance...
changing the stack amount is how he prevents cloning the entire stack, this is no longer a huge concern given that components can be lazy/shallow copied
So in terms of performance this likely wouldn't be an issue anymore?
Strong draft, need to review if that breaks any form of API.
Here mostly for a runnable jar so people can test things.
Based on the 1.21.3 dev branch, do NOT run this anywhere that isn't a throw away environment to check if the bug fix worked.
Expected behavior
before paper remap:
Observed/Actual behavior
after paper remap:
Steps/models to reproduce
((CraftWorld) world).getHandle().getChunkSource().chunkMap
.chunkMap will be destroyed by paper
Plugin and Datapack List
plugins
[23:17:07 INFO]: Server Plugins (1):
[23:17:07 INFO]: Bukkit Plugins:
[23:17:07 INFO]: - NeigeItems
Paper version
1.21.1-128
Other
No response
From my understanding this is an issue with the mappings caused by spigots names conflicting with mojangs names in a weird manner
While this might be a behavioral change that should be addressed, I would generally note that cloning items before you toss them into other places is a good idea, as there are 0 promises in the long term of how these items are handled
From my understanding this is an issue with the mappings caused by spigots names conflicting with mojangs names in a weird manner
obviously, but i don't know how to fix it, so i open a issue, instead of pr
I am confused how you are running into this bug tho?
This is a known issue when remapping reflective calls, but your "pre remapped" jar is mojang mapped?
Specify that your plugin is mojang mapped and just skip the remapper instead.
I am confused how you are running into this bug tho? This is a known issue when remapping reflective calls, but your "pre remapped" jar is mojang mapped? Specify that your plugin is mojang mapped and just skip the remapper instead.
I use paperweight
See https://docs.papermc.io/paper/dev/userdev#compiling-to-mojang-mappings
I already configure like that
99b1bf9 Use new ClientboundPlayerRotationPacket for set... - Owen1212055
If you are, the jar would not be remapped.
Seems more like you are not using paperweight correctly.
If you are, the jar would not be remapped. Seems more like you are not using paperweight correctly.
because I haven't use "dependsOn(tasks.reobfJar)"
Is your feature request related to a problem?
github doesn't support more than 1000 patches in same folder, paper has over 1000
Describe the solution you'd like.
move patches into folders like /patches/server/0-500 /patches/server/500-1000 ?
Describe alternatives you've considered.
Not sure
Other
No response
Discussion Category: Ideas
Not worth it, we won't have patches like this post hardfork anyway.
Discussion Category: Ideas
Is that repository public?
If those paperweight usages are in a submodule you need to also respect their manifest files when shading them in.
I'll close this issue as this is just a configuration issue given the remapper would not even remap your jar if you correctly marked it.
The deeper issue of our mapping logic getting tripped up when spigot and mojang mappings collide is known, but only applies to reflective access.
If you need more help with configuring your project to correctly define the mojang namespace in the manifest file, check by our discord.
Is that repository public? If those paperweight usages are in a submodule you need to also respect their manifest files when shading them in. I'll close this issue as this is just a configuration issue given the remapper would not even remap your jar if you correctly marked it. The deeper issue of our mapping logic getting tripped up when spigot and mojang mappings collide is known, but only applies to reflective access.
If you need more help with configuring your project to correctly define the mojang namespace in the manifest file, check by our discord.
Yes, this repository is public: https://github.com/ankhorg/NeigeItems-Kotlin
The submodule ":hooker:nms:v1_21+" uses paperweight.
I resolved this issue in a somewhat unconventional way.
Yeah sounds fair, that's why I was not sure if this should be considered a Paper bug or API user error.
there are 0 promises in the long term of how these items are handled
So in the general case, whenever you pass an ItemStack to the API that does something with the ItemStack "later", such as adding ItemStacks to PlayerDeathEvent#getDrops(), you should expect that the server will "clobber" it, i.e. you, the caller, needs to save (clone) it if you don't want it to change? Even if the thing you're passing it to seems "harmless"? Like, in the PlayerDeathEvent drops case, my naive expectation would be that the server just has to read the ItemStack in order to drop it, not write to it (i.e. set the count to 0).
I'm not that familiar with the server internals but I understand if "0 promises" has to be the case for one reason or another. Still, I can't help but feel that it's a bit unintuitive, and a potential pitfall for newcomers to the API. Do you have any long-term plans to a...
the server just has to read the ItemStack in order to drop it
There are 0 promises that the server will blindly clone an ItemStack you put into the world for you, a lot of the old behavior here was somewhat a mixture of happenchance or the fact that ItemStacks often API driven which is no longer the case; The behavioral change should probably be fixed, but, long run, you should be cloning any stack you don't want to be modified outside of your control when you're putting it into the world
The only thing we could ever do here is start blindly cloning ItemStack instances all around the API, but there is no real great consistency in the internals or the API here in terms of how this sort of thing is handled, and there is a lot of reliance on the fact that ItemStacks are not blindly cloned all over the place to prevent these issues
sp basically, we are working on it
Discussion Category: Ideas
Yeah this is starting to click in my head now, thanks for the input. I think part of my confusion comes from these API inconsistencies and "hidden" happenchance behaviors around ItemStack. Even though it seems obvious in hindsight, I hadn't really considered that a consequence of adding the ItemStack to the drops is that it becomes "live" in the world. And I feel like it's very common for the API to hide this fact because it in fact does copy the ItemStack in many cases.
I also think it's interesting to compare ItemStack to Block and Entity. For the latter two, I think it is quite intuitive to understand that they are "live" and mutable objects in the world, so you should expect them to change. And both also have immutable snapshot variants (BlockState and EntitySnapshot) that you can use if you want just that, an immutable snapshot (which is also an intuitive concept).
But ItemStack is this weird middle ground where it can be "live" in the world, but it can also be "disconnected"...
1196ab5 Avoid issues with certain tasks not processing ... - jpenilla
[PaperMC/Paper] branch deleted: 1.21.3-sleep-tasks
They do pass through, but seem to lose velocity. So they landed in the entrance where you then picked them up
Expected behavior
Chunk generation below Y=0 to be disabled in existing chunks when a 1.12.2 world is migrated to 1.21.1 when setting below-zero-generation-in-existing-chunks: false in spigot.yml.
Observed/Actual behavior
World migrates successfully, but generates chunks below Y=0 when players move around
Steps/models to reproduce
- Start new paper-1.21.1-128 server in empty directory
- Accept EULA
- Restart server to generate default configs
- Stop server
- Change below-zero-generation-in-existing-chunks to false in spigot.yml
- Delete world/
- Copy 1.12.2 world into directory to replace world/
- Start server
- Join server and fly below Y=0 in spectator mode
Plugin and Datapack List
/plugins: None
/datapack list: There are 3 data pack(s) enabled: [vanilla (built-in)], [file/bukkit (world)], [paper (built-in)]
Paper version
This server is running Paper version 1.21.1-128-master@d348cb8 (2024-10-21T16:23:24Z) (Implementing API version 1.21.1-R0.1...
Since 1.21.2, vanilla split relative teleportation flags into position and delta/velocity flags into separate enum entries. This highlighted a design flaw in the paper api addition for teleport flags, which just simply mirrored internals while also only being able to apply the delta/velocity part of a flag, given the teleport target is always absolute in the API.
This patch proposes to simply no longer expose the non-velocity related flags to the API, instead marking the entire Relative enum as being purely velocity related, as non-velocity related flags are not useful to callers. This was done over simply exposing all internal flags, as another vanilla change to the internal enum would result in the same breakage.
The newly proposed API only promises that the passed flags prevent the loss of velocity in the specific axis/context, which should be independent enough of vanillas specific implementation of this feature.
9f1fa0b Fix item gravity on inactive items, remove dumb... - kennytv
1a1d0cf Use target pitch in teleport (generally the sam... - kennytv
When a player has an open inventoryโsuch as with a merchant or anvilโand
places items in it, or has an item on their cursor, closing the inventory typically
returns those items to the player's main inventory. However, if the player dies with
the inventory still open, the items are dropped onto the ground.
Before:
Dying with item in merchant inventory while in inventory protected area (item drops):
https://github.com/user-attachments/assets/bf14d5a0-6e20-4a7d-b240-578d98d2074e
Dying with item on cursor while in inventory protected area (item drops):
https://github.com/user-attachments/assets/f9da24f3-6128-4d32-b580-e6fd22a4f13e
Dying with item in anvil inventory while in inventory protected area (item drops):
https://github.com/user-attachments/assets/05013e61-ab6e-4831-a3a4-a4698aa18af5
After (with config option enabled)
Dying with item in merchant inventory while in inventory protected area (item returned to inventory):
https://github.com/user-attachments/assets/9d32951f-1a79-4c95-8d41-05864c89c27c
Dying with item on cursor while in inventory protected area (item returned to inventory):
https://github.com/user-attachments/assets/a692f718-9817-4c69-9c44-8b1dc9d1169e
Dying with item in anvil inventory while in inventory protected area (item returned to inventory):
https://github.com/user-attachments/assets/d453f48e-b47a-48cd-879b-c23896ef470e
Dying with item in crafting grid while in inventory protected area (item returned to inventory):
https://github.com/user-attachments/assets/25a9485a-e574-484f-9a69-bad76c7434d1
The only inventory this doesn't apply to is beacons, because they never return items to inventory and always drop (see: https://bugs.mojang.com/browse/MC-177476)
I could easily fix a fix for this to the patch and add keep inventory support, what do you think?
580a610 Allow using old ender pearl behavior & apply en... - jpenilla
[PaperMC/Paper] branch deleted: 1.21.3-legacy-ender-pearls
[PaperMC/Paper] New branch created: ver/1.21.1
Hah succeeded now (but also, you really shouldn't be on any version below 1.21.1)
Hi, I hope you're having a wonderful day.
I've added a test for org.bukkit.craftbukkit.entity.CraftMinecart#minecartEntityTypeToMaterial, as requested in #11511.
In the current approach I've hardcoded the Minecart types, as is done in the function.
Hi, I hope you're having a wonderful day.
I've added a test for org.bukkit.craftbukkit.entity.CraftMinecart#minecartEntityTypeToMaterial, as requested in https://github.com/PaperMC/Paper/issues/11511.
In the current approach I've hardcoded the Minecart types, as is done in the function.
The whole point of the test is to ensure that the hardcoded values in the function are still correct.
Testing this with another set of hardcoded function is useless.
Iterate the item registry, find MinecartItems, reflectively access their entity type, ensure the static method correctly matches that.
Alright, I will try to fix it to use the Item registry
Also merge this into the respective patch that introduces the method under test.
No need for a new patch here.
dfedf79 Correctly cancel consumption of consumable - lynxplay
The RNG used in selecting random blocks for updates, is fundamentally flawed, plotting some values sampled from this RNG clearly indicates the problem:
Modifying the algorithm to include a couple more terms yields a much nicer and random looking result:
Additionally this PR removes the deprecated threadSafeRandom object used for providing the client with seeds for sound variant selection in favor of using the improved randValue :D
Thank you for the PR.
We are not going to deviate from vanilla's logic at the whim that it "looks more random".
I've fixed it to not be hard-coded, except for EntityType.SPAWNER_MINECART, as that doesn't have a corresponding item, and the function just returns a normal minecart. I've used a string based system, as I couldn't find any other way to do it. The current approach gets the short string of the entitytype (like chest_minecart), and gets the item with the corresponding ResourceLocation
Thanks!
You'll need to annotate the class with @AllFeatures in order for the test suite to pick it up and run correctly.
I'll probably also make a PR for changing it to a switch statement, as that's a better choice then 7 if/else statements.
Thanks! You'll need to annotate the class with
@AllFeaturesin order for the test suite to pick it up and run correctly.
Will do
EntityType fields are not constants, you won't find much luck in making that a switch statement.
I've added it, so it should be good to go.
I know it's a massive nit but couldn't the diff be reduced by a bit by removing the empty lines?
Is the diff size important in new files? I thought it was important purely to prevent conflicts in future merges, which is unrelated in context of new files
I've removed the empty lines. If it's to aggressive, just let me know.
Ok, that's not what I meant lol. Just revert it and forget what I said please.
I remember some fork a while ago attempted to optimize block update RNG at some point.
@ScriptLineStudios If you can prove that this RNG pattern causes problems, you would need to raise issues with Mojang directly? Otherwise it must have been a deliberate choice, the same magic number is used here as an increment:
- https://en.wikipedia.org/wiki/Linear_congruential_generator#Parameters_in_common_use 1013904223
- and here's fun a reading on LFSR https://jacopretorius.net/2017/09/wolfeinstein-3d-fizzlefade-algorithm.html
For anybody who had this issue like I did and OP did it is caused when you install LuckPerms without Essentials Protect (at least in my case) I fixed it by installing the "optional" Essentials Protect addition to EssenetialsX you can get that here as of time of comment: https://essentialsx.net/downloads.html
in the EssentialsX config under there are settings for specifically Essentials Protect and the default should be good but you want them set to false like this: https://imgur.com/a/cdyd3eL
But why the HELL does LuckPerms just make players randomly invulnerable?
But why the HELL does LuckPerms just make players randomly invulnerable?
It doesn't.
But why the HELL does LuckPerms just make players randomly invulnerable?
It doesn't.
Well, then how did the same thing just happen on my server? Me and a friend both suddenly stopped taking damage (or mob aggro, or anything) and lo and behold, we do indeed have invulnerable set to true all of a sudden. There also aren't that many plugins on our server, but LuckPerms is one of them.
But why the HELL does LuckPerms just make players randomly invulnerable?
It doesn't.
Well, then how did the same thing just happen on my server? Me and a friend both suddenly stopped taking damage (or mob aggro, or anything) and lo and behold, we do indeed have invulnerable set to true all of a sudden. There also aren't that many plugins on our server, but LuckPerms is one of them.
Instead of commenting on a year old closed issue. Join our discord and ask for support in the #paper-help channel. I can assure you it's not LuckPerms causing it.
You're right, sorry, I jumped to the conclusion. The problem was another plugin (AutoAFK). Thank you!
147b796 get previous redstone level from the right stat... - Lulu13022002
Hi, I was just wondering, are there any specific things holding the merge back?
The fact that no developer had time to review this yet.
Give it time, someone will get it merged soon enough.
Not to be merged, just for nice tracking
2ef589c okaaay let's go - NoahvdAa
d0028b7 you saw nothing - NoahvdAa
e080b20 Bundles are no longer experimental (thanks lynx) - NoahvdAa
d280061 First batch of server patches - NoahvdAa
3585434 first 100! - NoahvdAa
6b27267 oops - NoahvdAa
152e82c Some work - lynxplay
9e92fed More work? - lynxplay
f1649d7 Work it - lynxplay
9d63c81 Work work work - lynxplay
dc5af48 Breakpoint before projectile mess - lynxplay
[PaperMC/Paper] branch deleted: dev/1.21.2
Can you reopen the PR to master please :)
I'll try to review it tonight and get that merged.
84281ce Don't count mobs twice in per-player-mob-spawns - kennytv
Expected behavior
The same behaviour prior to the 1.21.3/2 update.
Observed/Actual behavior
The explosionDensityCache is not cleared anymore after the 1.21.3/2 update which causes issues with explosions interacting with entities
Steps/models to reproduce
/fill -17 -55 -72 -17 -55 -70 minecraft:bedrock
# Observe how explosions interact with this entity
/summon minecraft:tnt -16.5 -54.00 -69.5 {fuse:10000}
/setblock -17 -54 -71 glass
/summon minecraft:tnt -16.5 -54.00 -71.5 {fuse:10}
# The entity will not move even though the obstruction has been cleared.
/summon minecraft:tnt -16.5 -54.00 -71.5 {fuse:10}
Plugin and Datapack List
n/a
Paper version
Checking version, please wait...
This server is running Paper version 1.21.3-1-master@f273e6e (2024-10-31T17:32:23Z) (Implementing API version 1.21.3-R0.1-SNAPSHOT)
You are running the latest version
Other
The optimize-explosions patch was not applied correctly during the 1.21.3/2 update. The li...
3ad819a [ci skip] Remove leftover todo file - lynxplay
[PaperMC/Paper] New branch created: enhancement/moonrise-todo
apatch strikes again
closes #11539
Description
(Sry for my Eng)
I am aware of the cause of this problem. I don't believe that the problem could be with these two plugins. Or maybe?
Track
[20:56:14 WARN]: io.netty.channel.unix.Errors$NativeIoException: recvAddress(..) failed: Connection reset by peer
[20:56:14 WARN]: io.netty.channel.StacklessClosedChannelException
[20:56:14 WARN]: at io.netty.channel.AbstractChannel.close(ChannelPromise)(Unknown Source)
[20:56:14 WARN]: io.netty.channel.StacklessClosedChannelException
[20:56:14 WARN]: at io.netty.channel.AbstractChannel.close(ChannelPromise)(Unknown Source)
[20:56:14 WARN]: io.netty.channel.StacklessClosedChannelException
[20:56:14 WARN]: at io.netty.channel.AbstractChannel.close(ChannelPromise)(Unknown Source)
[20:56:14 WARN]: io.netty.channel.StacklessClosedChannelException
[20:56:14 WARN]: at io.netty.channel.AbstractChannel.close(ChannelPromise)(Unknown Source)
[20:56:14 WARN]: io.netty.channel.StacklessClosedChannelExc...
c5c1250 [ci skip] Remove leftover todo file (#11540) - lynxplay
[PaperMC/Paper] branch deleted: enhancement/moonrise-todo
[PaperMC/Paper] New branch created: enhancement/moonrise-todo
3ad819a [ci skip] Remove leftover todo file - lynxplay
This is not a Paper issue. The Paper issue tracker is for bugs with Paper, not for issues with plugins. If you encounter a plugin issue, please use the support channels of that respective plugin.
Additionally, we do not support offline-mode setups like AuthMe.
7ee4835 Correctly clear explosion density cache(#11541) - NoahvdAa
[PaperMC/Paper] New branch created: up
Upstream has released updates that appear to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing
Bukkit Changes:
97c59261 PR-1073: Make Biome an interface
a38581aa Fix further javadoc errors
8271c490 Fix javadoc error
8a9ecf29 PR-1072: Fix bad naming for Vault State methods 6dd58108 PR-1071: Make Fluid an interface and add missing entry ed2cdfc3 PR-1070: Make Attribute an interface and align names with the new minecraft ones 63472efb PR-1069: Add missing winter drop experimental annotation to pale boats
CraftBukkit Changes:
7235ad7b0 PR-1501: Make Biome an interface
602904003 PR-1500: Rename implementation for Vault State methods 75f26f79f PR-1499: Make Fluid an interface and add missing entry 4cfd87adc PR-1498: Make Attribute an interface and align names with the new minecraft ones 6bb0db5cb SPIGOT-7928: ExactChoice acts as MaterialChoice 3eaf3a13c SPIGOT-7929: Error when setting EquippableComponent ...
Hi, I hope you're having a wonderful day.
I've added a test for org.bukkit.craftbukkit.entity.CraftMinecart#minecartEntityTypeToMaterial, as requested in https://github.com/PaperMC/Paper/issues/11511.
In the current approach I've hardcoded the Minecart types, as is done in the function.
Repost of #11536
52a0590 Updated Upstream (Bukkit/CraftBukkit) (#11543) - kennytv
[PaperMC/Paper] branch deleted: up
Expected behavior
If a player is hidden using the https://jd.papermc.io/paper/1.21.3/org/bukkit/entity/Player.html#hidePlayer(org.bukkit.plugin.Plugin,org.bukkit.entity.Player) method does hide players in all commands
Observed/Actual behavior
If a player is hidden using the https://jd.papermc.io/paper/1.21.3/org/bukkit/entity/Player.html#hidePlayer(org.bukkit.plugin.Plugin,org.bukkit.entity.Player) method does not hide players in all commands like in the /team join or /team leave command
Steps/models to reproduce
https://github.com/user-attachments/assets/0a158cc5-84a3-499c-8653-34246f598e14
w
Plugin and Datapack List
Only this plugin coded by myself https://github.com/NikeyV1/NikeySystem.git
Paper version
This server is running Paper version 1.21.1-99-master@1bc02e6 (2024-09-25T02:41:02Z) (Implementing API version 1.21.1-R0.1-SNAPSHOT)
You are 32 version(s) behind
Download the new version at: https://papermc.io/downloads/paper
Other
Im trying to m...
Tested with exact choice shapeless recipes. As always, there are a few caveats with how these work in relation to the client. If your exact choice recipe doesn't include ingredients with damaged items, enchanted items, or "custom_name" items (NOT item_name), then they should work 100%. If you have ingredients that are damaged, enchanted, or have "custom_name" (displayName) NOT "item_name" (itemName), then the recipe book will show them as uncraftable and multiple clicks on the item won't keep adding 1 "recipe" to the grid, you get one click (or shift click).
Expected behavior
SmithingTransformRecipe should allow empty ingredients, as it is also described in javadoc.
Observed/Actual behavior
[07:50:51 ERROR]: Error occurred while enabling Cithare v0.20.6 (Is it up to date?)
java.lang.UnsupportedOperationException: Ingredients can't be empty
at net.minecraft.world.item.crafting.Ingredient.lambda$new$5(Ingredient.java:67) ~[paper-1.21.3.jar:1.21.3-2-7ee4835]
at com.mojang.datafixers.util.Either$Right.ifRight(Either.java:109) ~[paper-1.21.3.jar:?]
at net.minecraft.world.item.crafting.Ingredient.<init>(Ingredient.java:65) ~[paper-1.21.3.jar:1.21.3-2-7ee4835]
at net.minecraft.world.item.crafting.Ingredient.of(Ingredient.java:130) ~[paper-1.21.3.jar:1.21.3-2-7ee4835]
at net.minecraft.world.item.crafting.Ingredient.of(Ingredient.java:126) ~[paper-1.21.3.jar:1.21.3-2-7ee4835]
at org.bukkit.craftbukkit.inventory.CraftRecipe.toIngredient(CraftRecipe.java:43) ~[paper-1.21.3.jar:1.21.3-2...
Expected behavior
Biome.name() should return the name of the biome.
Observed/Actual behavior
java.lang.IncompatibleClassChangeError: Found interface org.bukkit.block.Biome, but class was expected
Steps/models to reproduce
System.out.println(player.getLocation().getBlock().getBiome().name());
Plugin and Datapack List
none
Paper version
This server is running Paper version 1.21.3-6-master@16d7d73 (2024-11-01T03:40:19Z) (Implementing API version 1.21.3-R0.1-SNAPSHOT)
Other
No response
Are you using a paper-plugin.yml?
Paper plugins have never and will not be remapped until they are declared stable.
In the recent upstream update, we merged spigots move to an interface for Biome, Attribute and Fluid.
The paper plugin would need to be re-compiled against the newest paper-api artefact.
The previous implementation was based off of spigots logic in CraftRecipe#toIngredient, which is completely incorrect as nms.Ingredient.of() is a throwing call.
Correctly insert handling for the empty() choice in the toNMSOptional logic.
[PaperMC/Paper] branch deleted: enhancement/moonrise-todo
[PaperMC/Paper] Issue opened: #11551 Cancelling InventoryClickEvent kicks the player from the server
Expected behavior
Cancelling InventoryClickEvent shouldn't kick the player and should cancel the event correctly
Observed/Actual behavior
Cancelling InventoryClickEvent shouldn't kicks the player
Steps/models to reproduce
- have plugin with following event
@EventHandler
public void on(InventoryClickEvent e) {
e.setCancelled(true);
}
- open inventory
3.a) try to click any item in the inventory
3.b) try to take item off a filled bundle
Plugin and Datapack List
only the Test plugin
Paper version
This server is running Paper version 1.21.3-6-master@16d7d73 (2024-11-01T03:40:19Z) (Implementing API version 1.21.3-R0.1-SNAPSHOT)
You are running the latest version
Other
Expected behavior
Code
Using EntityDamageByEntityEvent:
if (attackingPlayer.getAttackCooldown() == 1.0) {
damagedPlayer.setFoodLevel(Math.max(damagedPlayer.getFoodLevel() - foodLevelReduction, 0));
}
Player draws attack cooldown attributed item from a non-attack cooldown attributed item and instantly attacks another player -> player.getAttackCooldown() != 1.0
If player.getAttackCooldown() returns 1.0 at this stage, players can use macros, or manually swap quickly from an item with no attack cooldown attribute to an item with an attack cooldown attribute. This would effectively bypass any usage of player.getAttackCooldown() checks making the method obsolete in most situations.
Expected behaviour is that client attributes and server attributes are synchronous upon swapping and do not result in a desynchronisation between expected attack cooldown values and actual attack cooldown values.
Using this specific example ...
Apart from updating to 1.21.3 I also took the liberty to remove some code that has not been necessary since 1.13. Specifically, I mean the implementation of calculateCurrentChanges in RedStoneWireBlock. The method signature alone tells me it's code from 1.12 or older that's been kept and updated, but the only optimization it brings is one that Vanilla itself introduced in 1.13: allowing wires to decrease in power level by more than 1 at a time.
Spigot uses a no longer valid ClientboundContainerSetSlotPacket with the
slot -1, which would update the carried stack in versions <=1.21.1 but
now leads to an IOOB.
1.21.2 instead introduced the ClientboundSetCursorItemPacket, which this
patch uses instead.
This seems to resolve the issue, thank you! :-)
I have just seem the changes for 1.21.3 and this PR patch will definitely need rewritten, gonna wait a couple weeks for 1.21.3 to be stable.
ItemMeta#setEnchantable is nullable but yet passing null result in an NPE on Paper.
Also fixes a bunch of leftover during the update:
migrate the generated content to jspecify, make EnchantmentKeys#create public
undeprecate some fields on Registry
We have this diff already https://github.com/PaperMC/Paper/blob/85c870e9c7c97ff9f698dc1137586ee4cd54dda7/patches/server/0988-Fix-entity-type-tags-suggestions-in-selectors.patch#L80-L92
Either we remove this or duplicate it.
Idk what else calls this method and if that is of interest to maybe not solve as deep.
its only called by argument types so i think fixing this that deep is the correct solution.
c724023 add some preconditions - Lulu13022002
Okay, thanks for the quick check :+1:
Happens for example when getting a registry in the bootstrap and the server shutdown.
d19be64 Fix NPE with spark when CraftServer is not init... - Lulu13022002
Decreases the warning back to its 1.21.1 level where only teleports of
dead/invalid entities across dimensions were logged.
92131ad Decrease dead entity teleport warning (#11559) - lynxplay
Addresses issues with newer Java versions and Mockito.
Upstream has released updates that appear to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing
Bukkit Changes:
fc496179 Fix InstrumentTest
7c0ec598 PR-1075: Make Art an interface
c389f5a4 PR-1074: Make Sound an interface
CraftBukkit Changes:
52b99158a PR-1504: Make Art an interface
e18ae35f1 PR-1502: Make Sound an interface
Expected behavior
I expected my command to be executed, but instead, there is no output in the console, and it seems that the command has not been executed. I used this snippet of code inside my plugin class to test the command execution when a player joins.
Bukkit.getPluginManager().registerEvents(new Listener() {
@EventHandler
public void onPlayerJoin(final PlayerJoinEvent event) {
final Player player = event.getPlayer();
player.performCommand("say Hello World!");
}
}, this);
(As for a different but similar issue, I used Adventure components with text that runs a command when the player presses on it, and there is nothing that happens. I'm not sure if this is the same issue or not)
Observed/Actual behavior
There is nothing sent out into console, with no output sent out to the player. No error is displayed into the console either, and the implementation fails silently.
Steps/models to reproduce
- Register a q...
Paper plugins have never and will not be remapped until they are declared stable.
Thank you, I wasn't aware of this. Sorry about the noise.
We found the problem -_- I was being lied to. One of the players had an optimization pack on the client side. It's Fabulously-Optimized. It breaks secure chat state. Hilariously, it breaks it for everyone, but only when he tries to type. Until he says something, everyone's game functions just fine, but the moment he opens his mouth, everyone gets silenced hahaha. Though, the proxy_protocol on; tip is nice to learn about, thanks! It took such a long time because the culprit got a night job and has been on so sparsely. Thanks everyone!
Is your feature request related to a problem?
EntityPlaceEvent is only called for armor stands, boats, minecarts and end crystals
item frames and paintings have its own event (HangingPlaceEvent)
but spawn eggs are not covered by any event
Describe the solution you'd like.
Fire the EntityPlaceEvent for spawn eggs as well
Describe alternatives you've considered.
Intercepting the PlayerInteractEvent
Other
No response
Discussion Category: Ideas
This break negative damage amount that is possible with enchantment component. I'm not sure if the event/api should run in this case too.
I also changed the method name in the Craft equivalent class. I don't know if it makes sense. Can also just be dropped if not needed.
If it can be kept and there is already a patch for such things lmk. I didn't find one in my quick search.
For later:
- do we want the event to be called in case of negative damage?
- should we allow setDamage and other methods which damage the itemstack to deal negative damage? as this might break some plugins that are relying on those methods not being able to deal negative damage
Expected behavior
Trampling should not call the BlockFadeEvent
Observed/Actual behavior
It does call the BlockFadeEvent
Steps/models to reproduce
- listen for and cancel the block fade event
- trample a farmland block by jumping on it
- doesnt work
Plugin and Datapack List
irrelevant
Paper version
[15:42:27 INFO]: Checking version, please wait...
[15:42:27 INFO]: This server is running Paper version 1.21.1-130-ver/1.21.1@4d2672e (2024-10-30T18:33:50Z) (Implementing API version 1.21.1-R0.1-SNAPSHOT)
You are 1 version(s) behind
Download the new version at: https://papermc.io/downloads/paper
Previous version: 1.21.1-128-d348cb8 (MC: 1.21.1)
Other
The problem with this is that if you want to prevent natural block fading for farmland but allow trampling, you would have to implement a hacky solution which involves listening for the PlayerInteractEvent to track when a player tramples it
temporarily store that information for that specific block a...
That part can be remove when pr is rebased. see https://hub.spigotmc.org/stash/projects/SPIGOT/repos/bukkit/commits/8a9ecf29405887b9e58244cd5d87e8ca0a5970d4#src%2Fmain%2Fjava%2Forg%2Fbukkit%2Fblock%2Fdata%2Ftype%2FVault.java
I would expect the past tense here.
+ LootTable getOverridenDisplayLootTable();
Expected behavior
When building a Wind Charged Cannon thingy
https://youtu.be/3fnC31VqAbg
you should get launched thousands of blocks into the air
Observed/Actual behavior
you either get launched like 10 blocks or nothing
Steps/models to reproduce
Plugin and Datapack List
None
Paper version
1.21 and 1.21.1
Other
No response
On a slightly related note... The API still allows dispatching Commands from an Entity. These commands will be executed with the NULL CommandSource, this is kind of a change? Do we care?
for this item to be available for use again
for this item to be available for use again
Do you know if this is a new issue, or has trampling farmland always called BlockFadeEvent?
I know for a fact that I encountered this issue back in 1.19, but didn't know it
I looked at the code I ran back then, and it is basically the same as now
+ * Represents a component which determines the cooldown applied when using this item before it is available for use again.
fixes #11531
i am not entirely sure what exactly is happening here. my best guess is that the chunk status "full" didn't yet exist in older versions and fully generated chunks were just left on "mobs_spawned".
How exactly did you get to mobs_spawned? The equivalent for full in pre 1.14-ish versions would be fullchunk
i generated a world in 1.12.2 made sure to wait a bit and also flew around in spectator mode in the ground to make sure everything was generated. (should note that i used single player to generate this) i also tried the same in 1.17 and when i checked there the chunks were showing up as full
Is your feature request related to a problem?
It would be better if you add this feature so we can manage our resources efficiently.
Describe the solution you'd like.
Add an option to automatically pause the server when no players are connected for over 60 seconds. This functionality would save resources, reduce CPU usage, and potentially decrease hosting costs for smaller servers or development environments.
Describe alternatives you've considered.
Using External Scripts or Tools
Iโve tried using external scripts to monitor player activity and issue a command to pause or shut down the server when itโs empty. However, this approach adds complexity and can lead to resource overhead. Since it operates outside PaperMC, thereโs also a slight delay in detecting when a player joins again, which impacts the experience.
Scheduled Restarts and Downtime
I considered setting up scheduled server restarts or downtimes, especially during late hours when player traffic is lo...
Discussion Category: Ideas
There is no real concept of pausing a running process from inside the process, best you could do is maybe reduce how much you spin wait, but, stuff still generally expects to run even when the server is empty. This is generally not worth the sunken cost of trying to implement this properly, IMHO, you're still running an entire JVM with all of the other bits of software like plugins in there which expect to be able to do things.
Discussion Category: Ideas
Even Forge that has feature i can show some screenshots.
<img width="345" alt="{1A189C2C-1533-4A46-BCE6-20AC464A7444}" src="https://github.com/user-attachments/assets/ce545d6b-4308-49a5-b4e6-61d2910a9a19">
Discussion Category: Ideas
That's a vanilla feature
Discussion Category: Ideas
Yes but why Paper isn't using it? it's better thou
Discussion Category: Ideas
Paper disables it by default since it can break plugins, you can enable it in the same place as everywhere else, in server.proprietes
Discussion Category: Ideas
You can enable it in server.properties, paper disables it by default due to some concerns over how spigot implemented this feature into their own codebase, i.e. not allowing the chunk system to unload chunks. Some of this has been mitigated, but, you'll need to test it yourself and see if it works for your setup.
Discussion Category: Ideas
Expected behavior
org.bukkit.entity.Player#loadData() loads the current location, including world info, like it does on the upstream.
Observed/Actual behavior
org.bukkit.entity.Player#loadData() loads the current location without world info, unlike it does on the upstream.
Steps/models to reproduce
Player#loadData() results in Entity#load(CompoundTag) call on that player's ServerPlayer instance, which loads the world info on Paper until 1.20.2 build 272 and on Spigot.
Paper moves the world info loading from Entity#load(CompoundTag) to PlayerList#placeNewPlayer(Connection, ServerPlayer, CommonListenerCookie) since 1.20.2 build 272: https://github.com/PaperMC/Paper/blob/d348cb88a9fe8d19e46102c8b9febe18f746d46b/patches/server/0343-Move-player-to-spawn-point-if-spa...
This generally looks like the documentation fell behind mojangs tweaks and only worked due to CB specific hacks; I'm not really sure if it's viable to properly restore this, I guess maybe we could try to rehack the behavior into the load method, but, this is all around bleh
the documentation fell behind mojangs tweaks
@electronicboy, worlds don't have UUIDs on vanilla and are identified by dimension keys, worlds UUIDs are introduced by Spigot (or Bukkit? doesn't matter). So, sincePlayer#loadData()loads world info on Spigot, it should behave the same way on Paper.
I mean, Spigot has indeed brought a lot of weird internal changes to the game, but I don't think this is one of them, and at least in the context of Player#loadData(), the API behavior shouldn't be changed in this way. Because, well, that's an API, and Spigot plugins using it don't expect forks to change it.
I'm against using reflection for that. It can hide potential bugs occuring during runtime. When generating everything during update time we can find issues way faster.
I addressed your concern regarding the base class issue by generating a mapping.
Except this is not purely API behavior, This is mojang code which is being called into, in which spigot introduced several bugs by the change here, we are not reverting that change, this will need to be solved in a different matter, however, I'm not sure if there is enough will to deal with that
The following lines ensure that a force refresh is triggered for all players that can see the entity.
why does the server icon binary keep changing over and over, can you stop? its very sus looking
the git version leaf is using does that, lynx just reverted it to the old encoding. we dont know what causes it.
if you are concerned you are welcome to apply the patch and look at the file yourself
Is your feature request related to a problem?
Currently LifecycleEvents.TAGS can only be registered inside a plugin bootstrap, even though Minecraft lets you reload tags at any time.
That means the API can't be used by any plugins using the plugin.yml system, and makes it harder to use for any plugins that only have the relevant data post bootstrap.
Describe the solution you'd like.
For LifecycleEvents.TAGS to be available during onEnable, similarly to LifecycleEvents.COMMANDS.
This will technically require an extra Minecraft data reload after plugins enable, but assuming it's possible to make that reload only happen if any plugins actually registered a handler, I don't think that should be too much of a problem? can even make that a configurable thing on the event for plugins that don't change anything immediately & only need a handler for later reloads.
Describe alternatives you've considered.
With Paper plugins it's possible to register a handler in b...
Discussion Category: Ideas
These are just events, nothing more, nothing less; forcing an entire data reload as part of the server startup lifecycle just sounds like an entire headache to push forward something Mojang only seemingly provides a loose level of support for data pack devs, it's not a mechanism intended to be used every data on actual running servers, and so, I really can't get behind this.
Part of the reality is that if you want modern features, we're going to need to adapt to how Mojang actually handles this stuff, rather than trying to fight the current to bodge around how their stuff works
Discussion Category: Ideas
Maybe just allow plugins to register tags later, but leave the reloading to them? They can just call Bukkit#reloadData. Not really a fan of automatically doing this on startup.
That wouldn't really require much hacking or go against vanilla handling - its similar to adding tag files to a datapack and doing /minecraft:reload, the only change here would be entirely on the Paper side of things.
Discussion Category: Ideas
except it's not as simple as that, because there are certain expectations from the game over how this works; reloading data is a bodged mojang mechanism which is not intended for daily use. The game is not designed to deal with people registering stuff later as part of it's normal lifecycle, while you might be able to get away with it in many cases, it's not something that we can make any promises over the fact that it's not going to break when you actually start to utilise it in datapacks, etc
Discussion Category: Ideas
Expected behavior
Normal /tp to any player
Observed/Actual behavior
The player is not going anywhere and his entire interior in the house will disappear, all the whole blocks will disappear.
In the chat it said: Chat is disabled in the client settings
Steps/models to reproduce
- Start the server with paper
- Just write /tp to any players and you will encounter this error.
(This error is not always, it appears sometimes)
Plugin and Datapack List
AntiRaidFarm, arMarks, ArmorStandEditor, BalancedVillagerTrades, BanAnnouncer, BreweryX, ChatBubbles, Chatty, Chunky, CoreProtect CoreProtectTNT, DecentHolograms, DiscordSRV, ElytraFly, emotecraft, Essentials, GSit, InventoryRollbackPlus, InvSeePlusPlus, ItemEdit LibertyBans, LuckPerms, NormalSpit, packetevents, PL-Hide, Pl3xMap, PlaceholderAPI, PlasmoVoice, PLAZMER-ENGINE, Profiler ProtocolLib, PurpurExtras, pv-addon-broadcast, pv-addon-discs, pv-addon-groups, pv-addon-lavaplayer-lib, pv-addon-priority, pv-addon-scul...
c6aa61e Updated Upstream (Bukkit/CraftBukkit/Spigot) (#... - Machine-Maker
93b435d [ci skip] better instructions for patch apply c... - Machine-Maker
Chat is disabled in the client settings
consider enabling chat in the client settings, aka your minecraft settings ^^
The error is what we care about, the chat stuff is potentially some side-effect of this mess
didn't see the second message, sorry, lol
[PaperMC/Paper] branch deleted: fix/update-data-convertor
[PaperMC/Paper] branch deleted: feature/getEntityTargetPredicate
Well, isn't this something that already exists? handlers you register in bootstrap are re-run on reload afaik, so if you have one that registers data in any dynamic way (e.g. from a file or from something that can be updated with commands or whatever) it'll still be tags getting changed via a reload - only difference is that registring via onEnable will require a reload if you want the updates right away, or if the plugin changes nothing initially and only needs to edit them later it'd be the same behavior as bootstrap essentially.
Discussion Category: Ideas
Can you send the whole log file please?
Yes, they're re-run on a reload but, the important part is that they're also run as part of the normal bootstrapping process of the server where all of this data is properly defined, nothing you added in here would be reliably utilised by datapacks, and I'm not exactly sure that we should be trying to promise any support for what will essentially be modifying the servers bootstrap lifecycle process
Discussion Category: Ideas
So you want the EntityPlaceEvent to be called for spawn eggs because you need to know which player placed the egg?
Discussion Category: Ideas
This sounds like https://github.com/PaperMC/Paper/discussions/10527 and https://github.com/PaperMC/Paper/issues/6487 ?
Discussion Category: Ideas
PlayerLaunchProjectileEvent is used for eggs, the event is fired in cases where an interaction directly spawns an entity into the world, and that's not the case here
Discussion Category: Ideas
Also: https://github.com/PaperMC/Paper/pull/7377 might be what we are looking for here.
Discussion Category: Ideas
PlayerLaunchProjectileEvent is used for eggs, the EntityPlaceEvent is fired in cases where an interaction directly spawns an entity into the world, and that's not the case here
I don't think I can follow.
Placing a spawn egg does directly spawn the corresponding entity in the world, or am I wrong?
Discussion Category: Ideas
I, er, apparently brainfarted and got the wrong egg
Discussion Category: Ideas
Expected behavior
Creating a new typed key and registering it via the registerEventHandler should allow using those keys inside all further postFlatteners of the same type.
Observed/Actual behavior
Using such typed key after registering still throws startup errors on usage, that the key does not exist.
Error: https://pastes.dev/WNd63g7agt
Steps/models to reproduce
Using the following code flow triggers the error for KEY1 on enchantment example.
final var KEY1 = TypedKey.create(RegistryKey.ENCHANTMENT, Key.key("namespace:key1"))
LifecycleEventManager<BootstrapContext> manager = context.getLifecycleManager();
manager.registerEventHandler(RegistryEvents.ENCHANTMENT.freeze().newHandler(event ->
event.registry().register(KEY1, builder -> { ... })
)));
manager.registerEventHandler(LifecycleEvents.TAGS.postFlatten(RegistryKey.ENCHANTMENT), event -> {
final PostFlattenTagRegistrar<Enchantment> registrar = event.registrar();
registrar.addToTag(En...
Fixed in c6aa61ee18f0b3db83a4ef4bb25dc6b1761f2e3b
In my opinion, since the existing API can already completely modify tags compared to the initial datapack load (I.e. the new API, as far as I can understand at least, wouldn't be changing anything on that front) & datapacks themselves can be loaded/unloaded to change tags at runtime, it wouldn't make sense to avoid adding that just because it promotes the already existing behavior (and for datapack integration it would be the same as the commands event, no? register in bootstrap for datapack support, or can use onEnable if you don't need that).
I get where you're coming from though, as I suppose it does promote that usage even if it already exists - if it won't be added as official API, would exposing a "use at your own risk" be possible, if it's basically the same handling internally? something in Unsafe maybe?
Discussion Category: Ideas
Is your feature request related to a problem?
no it only for performance maybe
Describe the solution you'd like.
to day i found mod name ("Async Mod") In Fabric
This Mod it say benchmark with 3500 Villager in Intel Core i7-10700
Purpur(Maybe it PaperFork) TPS Is 4.61 & MSPT 150++
but This Mod is TPS 20 & MSPT 40
i want to know it can patch to paper or not It might be more efficient if there is no conflict with the paper.
Thanky You
Describe alternatives you've considered.
It might be useful for large SMP servers.
Other
No response
Discussion Category: Ideas
Expected behavior
I expected to launch my server on my ubuntu VM.
Observed/Actual behavior
When I launched my paper.jar file, everything load, without plugins. when the server show "Done". It crash and show this Java error.
It append only with the 1.21.3 version of paper.
I tried on my 1.20.4 server and everything was perfect.
hs_err_pid2218781.log
Steps/models to reproduce
Launch paper on an ubuntu 22.04.4 distrib
Plugin and Datapack List
no datapack, no plugin
Paper version
paper 1.21.3-12
#11561
Other
Good luck and you do an really amazing work thank you
This is not tenable without breaking a large swath of plugins
Discussion Category: Ideas
It Ok Thanks
Discussion Category: Ideas
Caused by mojang now flattening the tags and binding them before freezing the registries as tags are part of the freezing logic in 1.21.2+.
As such the freeze event is called after the post flatten event, which leads to this explosion.
I am unsure what our move forward here is, especially for future proofing this API to avoid something like this.
Will get some more input.
We found the problem -_- I was being lied to. One of the players had an optimization pack on the client side. It's Fabulously-Optimized. It breaks secure chat state. Hilariously, it breaks it for everyone, but only when he tries to type. Until he says something, everyone's game functions just fine, but the moment he opens his mouth, everyone gets silenced hahaha. Though, the
proxy_protocol on;tip is nice to learn about, thanks! It took such a long time because the culprit got a night job and has been on so sparsely. Thanks everyone!
Hey there, not to necro the thread, but we found this to be the case as well - Thank you!
Now I just wonder what FO is doing to break chat, lol
completely modify tags compared to the initial datapack load
except it does so in a manner that is compatible with the semantics of mojangs data loading system, which will allow you to utilise these things inside of datapacks, within the bounds of the proper lifecycle of mojangs initialisation process.
it wouldn't make sense to avoid adding that just because it promotes the already existing behavior
Except it's not existing behaviour, Mojang does not double load on startup, and reload is there as util for messing with packs; it's not intended as something that should be part of every single server startup, there is little interest to have to force data to reload multiple times just so that we can fire the event multiple times so that people can interact with stuff.
and for datapack integration it would be the same as the commands event, no?
Just because the existing lifecycle modifications we've adopted from upstream cause some incompatibilities with mojangs lif...
Discussion Category: Ideas
If you're at the level to make an api at your own risk then you may just use MappedRegistry#getOrCreateTag in nms with reflection, basically this
var reg = (MappedRegistry<Block>) BuiltInRegistries.BLOCK;
var tag = reg.getOrCreateTag(TagKey.create(Registries.BLOCK, ResourceLocation.parse("test:test")));
VarHandle entriesVarHandle = MethodHandles.privateLookupIn(
HolderSet.Named.class,
MethodHandles.lookup()
).findVarHandle(HolderSet.Named.class, "contents", List.class);
// Content is not final as it's meant to be constantly replaced on each reload, when ServerResourcesReloadedEvent is called
entriesVarHandle.set(tag, List.of(reg.getHolder(ResourceLocation.parse("minecraft:stone")).orElseThrow()));
Same as with just reloading tags, you won't be able to use it in special places like enchantments etc.
It's a bad behavior, with better alternative, not properly supported by minecraft itself and with the potential to not be even supported even b...
Discussion Category: Ideas
[PaperMC/Paper] New branch created: fix/attributes-restorefrom
a6c4f1c Manually reset attribute map on restoring playe... - electronicboy
Spigots reuse of the entity instances causes the server to try to copy a players existing attributes back onto itself, which causes an error.
We'll manually clear the applicable attribute modifiers, but, in the long run, we should just revert out of the broken behavior of trying to reuse ServerPlayer instances.