2.0.0 exploration

BBadIdeasBureau7/15/2022
From Atropos in the mothership (in v10 Feedback)
Hello folks, for those of you testing V10 using the dnd5e system, we have a pre-release of dnd5e version 2.0.0, tagged version 2.0.0-alpha1 which adds V10 compatibility, cleaned file organization structure, a single built distributable JS file, and more. We'll be adding more features into 2.0.0 as we work towards V10 stable that integrate with new version 10 features.

To test this dnd5e release you can install manually with the manifest URL: https://github.com/foundryvtt/dnd5e/releases/download/release-2.0.0-alpha1/system.json.

Installing this release will put you on a testing update track that you'll need to - eventually - manually switch back off. I hope this helps your testing this weekend for those of you working on modules which are easier to test with an updated dnd5e system version. Happy weekend!
CCalego7/16/2022
🧵
Aarcanist7/16/2022
Source maps :excitedsprout:
CCalego7/16/2022
The number 2.0.0 was chosen for this release because it is going to be a clean break from v9 and before compatibility, (including any pre-v10 shims), it restructures a lot at a pretty low level, and distributes with rollup now.

So the big major number incremented to help devs and users both realize that this is a big release, not just another feature release.

Please for the love of all things do not assume this means the 5e repo is adopting semver in a rigorous way, this version number is another tool at our disposal in the communication chain, naught more.
Aarcanist7/16/2022
What can you do to salvage more-hooks-5e? It relies on importing stuff that will no longer be possible...
CCalego7/16/2022
absolutely nothing lol
Aarcanist7/16/2022
:rip:
CCalego7/16/2022
If I have any time at all to work on things before v10 drops, I'll be trying to get the hooks into the system itself as part of this big hairy new version
CCalego7/16/2022
This also means that just about every custom sheet module is going to be toasted, there's apparently a more bulletproof way to extend the sheetclasses than importing the module file:

class CustomSheet extends dnd5e.applications.actor.ActorSheet5e {


I haven't tried this but unless you're a library module, this should be available by the time your file is instanciated.
UUUnknown User7/16/2022
Message Not Public
Sign In & Join Server To View
CCalego7/16/2022
2.0.0 === 1.7.0
CCalego7/16/2022
so yeah, just know that it's not called 1.7.0 anymore
CCalego7/16/2022
And as usual, any and all testing you folks can to is immensely appreciated. The stuff raised in early v10 compat testing is excellent to have on the radar earlier than later
CCalego7/16/2022
For those intersted, this is the branch for all v10 dev work (i.e. where 2.0.0 lives atm):

https://github.com/foundryvtt/dnd5e/tree/v10-dev
CCalego7/16/2022
oh perfect it's the same as when I pinged the 5e role.
Aarcanist7/16/2022
Yeah. That seems to work great for Tidy5e Sheet! I don't know if it's possible to make it work across dnd5e 1.x.x. and 2.x.x though...
Maybe with dynamic imports
CCalego7/16/2022
the whole point of calling it 2.x.x is that things are 0% likely to be backwards compatible, and that's ok.
CCalego7/16/2022
2.x is only going to work in v10, there's very little point IMO in maintaining a codebase with switches to work in both. If you want to support v9, don't support v10 yet.
CCalego7/16/2022
I personally am probably not going to be upgrading my own games to v10 and thus dnd5e 2.0 for a while, so my stuff is probably going to sit in 1.6.x compatible for a hot minute
Aarcanist7/16/2022
Ok. I'm just preparing a small PR to get Tidy5e Sheet working to hopefully help Sdenec out
Aarcanist7/16/2022
Since they posted in #endangered-packages and all that
UUUnknown User7/16/2022
3 Messages Not Public
Sign In & Join Server To View
CCalego7/16/2022
I never was able to get this to work before because game was always undefined before init
CCalego7/16/2022
but I was always trying to directly extend the class, not patch them (more-hooks-5e is a different case, I wanted to be first in line to the patching queue for that), and directly extending like this never worked for me:
class CustomSheet extends game..... // error: game is undefined
CCalego7/16/2022
with the new dnd5e object on global though, that should be defined by the time any module that isn't a library module has its files instanciated, so 🤞 it'll not suffer the same problem
(looks like it according to arcanist above)
UUUnknown User7/16/2022
2 Messages Not Public
Sign In & Join Server To View
CCalego7/16/2022
Yeah I saw a snippet for that and was like "lol no i'm just gonna do the bad thing and not try to gaze into the eldritch mind of javascript on this"
UUUnknown User7/16/2022
2 Messages Not Public
Sign In & Join Server To View
UUUnknown User7/16/2022
Message Not Public
Sign In & Join Server To View
MMLeahy7/17/2022
A small note to the above discussing library modules. I do believe library modules load after the system and before the regular list of modules, so a library module likely still will have access to the new global dnd5e, etc.

Additionally while Rollup is being used it should be possible to provide named exports from the bundle such that it can be imported and those named exports referenced vs the necessity of adding the global dnd5e.

I don't have any skin in this game, so just spitballing.. Good luck to all working on this big upgrade!
Aarcanist7/17/2022
Yeah, there's a few named exports at the bottom of the new dnd5e.mjs bundle
MMLeahy7/17/2022
Whether it makes sense to add a global for the system is certainly up to debate w/ what looks like the pertinent exports available for import. I haven't looked into it in regard to what the other properties of the dnd5e global reference contains. My only concern is that so many follow what DnD5e does, so other systems might follow that pattern and also put the system in global namespace, etc.

No skin in game, so definitely going to duck out on discussion, but verifying if direct imports from the bundle works instead of the global for modules needing to reference the system could be worth at least exploring before promoting things to a new global reference.
BBadIdeasBureau7/17/2022
Can someone sanity check what I'm seeing here?
Editing token HP via the token HUD throws the following error, and also appears to prevent the updateActor hook from firing (though the actor does update, and this update persists on refresh)
BBadIdeasBureau7/17/2022
Mostly trying to figure out what mix of core bug/5e bug this is, as a) obviously the scrolling text shouldn't error out, but also b) the fact that there is a circumstance where an actor update can happen without updateActor firing seems like a core issue that this is exposing.
UUUnknown User7/22/2022
3 Messages Not Public
Sign In & Join Server To View
Aarbron7/22/2022
Fixed already in the latest version on GitHub
UUUnknown User7/22/2022
Message Not Public
Sign In & Join Server To View
LTLLLeo The League Lion7/22/2022
@honeybadger gave :vote: LeaguePoints™ to @arbron (#56 • 38)
UUUnknown User7/22/2022
2 Messages Not Public
Sign In & Join Server To View
CCalego7/22/2022
u wanaaa open a pr for dis?
UUUnknown User7/22/2022
2 Messages Not Public
Sign In & Join Server To View
CCalego7/22/2022
fair enough
UUUnknown User7/22/2022
Message Not Public
Sign In & Join Server To View
Aarbron7/22/2022
Where is this invalid data coming from? And is it happening on the latest version from GitHub?
UUUnknown User7/25/2022
2 Messages Not Public
Sign In & Join Server To View
CCalego7/25/2022
lol i bet i know why these do this, those are all extensions of ActorSheet, and I bet actorSheet wants to come to the front when the actor updates?
UUUnknown User8/4/2022
7 Messages Not Public
Sign In & Join Server To View
Aarcanist8/5/2022
Yeah, I reported that
UUUnknown User8/7/2022
4 Messages Not Public
Sign In & Join Server To View
Aarbron8/7/2022
Hmm, wasn't seeing that last time I opening that window on v10, let me check now
Aarbron8/7/2022
Ooo fun
UUUnknown User8/16/2022
4 Messages Not Public
Sign In & Join Server To View
Aarbron8/17/2022
We haven’t touched any vision stuff in 5e yet, so I’m going to say core bug
UUUnknown User8/17/2022
3 Messages Not Public
Sign In & Join Server To View
L[Lyra [he/him]8/18/2022
I just switched to MRE and the associated addons. I think that has more hooks as a dependency right? I hoped this was “the solution” to betterRolls5e being unmaintained. Any idea at all of when those modules are likely to get an update once v10 releases? Months? Weeks? V11?
Aarcanist8/18/2022
The hooks from More Hooks 5e were merged into dnd5e 2.0.0 btw
L[Lyra [he/him]8/18/2022
As someone not too familiar with exactly how all the modules work I'd still be looking for some guidance on what that means for the availability of the modules I use. But broadly, that sounds 'positive' 👍
Aarcanist8/18/2022
I think it just means that you don't need to install that dependency and that Calego's modules can be updated to work (once he updates them) without the less-than-ideal implementation of More Hooks that was needed previously.
CCalego8/18/2022
as far as I know all of the hooks my mini modules need are now part of v2.0.0 with different names and maybe different payloads.

I've got no timelines for when I personally will update them, but I am certainly open to someone taking a look at things and trying them out in the new hook schemas.

I haven't even had time to install v10 yet.
L[Lyra [he/him]8/18/2022
That's fair enough, I'm definitely not someone with the capabilities to do that unfortunately so I'll have to hope someone more able really wants them on v10.
UUUnknown User8/18/2022
Message Not Public
Sign In & Join Server To View
CCalego8/18/2022
fingers crossed it's :just: changing the hook names and making the minCompatibility 'v10'
UUUnknown User8/18/2022
Message Not Public
Sign In & Join Server To View
CCalego8/18/2022
but obviously haven't looked into if there's anything else that v10 messes with
Aarbron8/18/2022
Breaking changes in v10/2.0? What a ridiculous idea 😮
UUUnknown User8/19/2022
Message Not Public
Sign In & Join Server To View
CCalego8/19/2022
There is talk of another alpha release happening soon™️

As far as usual goes, these alpha releases are new to the dnd5e team so I got no insights for you there
UUUnknown User8/19/2022
Message Not Public
Sign In & Join Server To View
LTLLLeo The League Lion8/19/2022
@Zhell gave :vote: LeaguePoints™ to @Calego (ElfFriend) (#1 • 1510)
UUUnknown User8/24/2022
Message Not Public
Sign In & Join Server To View
CCalego8/24/2022
On that front, I am considering sunsetting MRE in its current form in favor of two distinct modules:
- One which handles "faster rolling by default"
- One which handles "multiple damage groups"
UUUnknown User8/24/2022
Message Not Public
Sign In & Join Server To View
CCalego8/24/2022
But yeah, I would expect those to not need to libwrap anymore
CCalego8/24/2022
at worst, they would return false from one pre- hook or another and take over from there.
CCalego8/24/2022
That'd also allow experimenting with the new ability to add multiple damage rolls to one chat card natively.
UUUnknown User8/24/2022
Message Not Public
Sign In & Join Server To View
CCalego8/24/2022
youre god damn right it wont have any options