#hangar-dev
1 messages · Page 4 of 1
Yeah, you show 404 if you don't have perms, that's pretty standard
Don't leak any info
And yes, I guess we could enable it for the 404 page
we use 401/403 if you try to do something you aren't allowed on an already public thing
haven't really been following hangar development, but will hangar support download links directly to Jenkins?
Yeah, Plan is to support external links, with a warning
so like link to JENKINS/job/PLUGIN/lastSuccessfulBuild/artifacts/PLUGIN.jar or whatever?
so it's always latest?
Could do that I guess, yeah
But like, ideally, you have a channel for proper release
And then could have a channel for Dev stuff
that's the idea
But you also want to send update notifications and stuff, so not sure how good that would be
could you not just publish an update on hangar with the same link every once in a while for an important build or something
new suggestion: link to download latest dev build lol
download stable
download dev
or smth idk
MVP stuff
This is a link currently to download the recommended version
Which is something the author sets
Then there is “promoted versions” which are created in some massive materialized view query that I don’t ask how it works
So idk what they are, but they exist
inb4 something's wrong with one of those giant queries and we're all just "yeah idk"
I mean, so far, the only changes have been decrementing any visibility number by 1 cause we made it 0-indexed, but yeah, hopefully no more
that already caused enough oopsies haha
Ugh yeah. But it’s so much nicer if we can just use the @EnumByOrdinal
what should go here for velocity? https://github.com/PaperMC/Hangar/blob/version-selector/src/main/java/io/papermc/hangar/model/Platform.java#L22
specifically, the List.of() bit at the end of that line
probably should do mc versions for proxies
especially since they support multiple ones
You don't care about the mc version, you care about the proxy version
all aspects relevant to MC are hidden away in API, so that deals with the grunt of it, nothing really tied to MC version
zzzCat, what about for waterfall? it has mc versions. I just included the ones listed in the paper download api
It doesn't have mc versions
it has versions
Those just happen to tie close to mc versions, but do not always line up
The versioning system we already use is fine
how should authors identify what version their plugins work with?
The issue is that saying that it's the mc version is just false
ah ok
and for stuff like velocity, 100% useless there
what about for velocity then?
velocity isn't the mc server
velocity has their own version numbers
heck, they just had a major version bump a few months ago
what's a major version?!
oh? I just saw the build numbers on the ci?
@cinder silo ik that. im wondering what numbers and style to use for velocity
oh I guess I do see 1.0.9, 1.0.10, and 1.1.0
@sly mason We haven't bumped major versions at all yet 🙂 still on 1.1.0 for dev
oh, I thought that you did 0.9 > 1.0 recentlyish
but, the general point still stands ;P
velocity versions don't tie into mc versions at all, it's only really bungee that does that, and for some reason we follow that
Slight chance I might break from that one eventually, especially as their versioning pattern has just become even more of a "we bump it when we feel like it", bleh
soon as y'all break free of the md mothership you can go to the enlightened side and promote Velocity 
@limpid stump
Do you think hangar should use the 1.x versions when asking authors what version of velocity it supports? So right now it’d just be 1.0 (and soon 1.1).
it's semver
The issue with defining supported versions is that it's messy
Like, for some plugins 1.0 > 1.1 is nothing
for some, that's gonna be a major breaker
1.0.x and 1.1.0 are not major versions. The major version is 1, the minor versions add features but are backwards-compatible with the older version.
Right yeah, wrong word.
1.1 > 1.1.1 might be nothing for some, might also totally destroy others
We already told people that 1.0.x > 1.1.0 is going to break plugins that don't stick to the API.
The only real super viable way for it is to just have a list of every release, which, ofc, is also a headache...
even build numbers matter for paper plugins
I’m just talking about paper, waterfall, and velocity, not versions for other plugin dependencies.
Honestly, part of me questions if "supported versions" is even worth it
for Velocity stable releases we are generally super conservative and don't tend to make breaking changes
I mean you do need some system right? Like how are people to know if it’s a plugin for 1.14, or 1.16?
Literally nobody updates that shit anyways
Ok, what about in the future, a 1.16 plugin vs 1.18
When that happens
There will be older plugins on the site, we need some way to say they are outdated right?
you'll have last update dates?
But the plugin might still work.
And the author knows that and just doesn’t update anything.
Which is literally the point I'm trying to make
But it might not work.
I mean... that seems pretty annoying. To download a plugin without having a clue as to whether it’s for whatever version of server you are running.
I'm not really sure what you're expecting a magical solution here to be
Like, you can go for throwing version numbers on, irdc
But, they're hardly a useful metric for "will it work on my version" unless devs actually update that
which especially in regards to plugins which haven't been updated in months literally highlights the issue
At least, for paper, having a list similar to spigot, where you check what versions of Mc it supports.
Ofc that doesn’t take into individual builds, but it’s a good step
The thing is that individual builds are really solely where it actually matters
It's not much point if you select to search for a plugin for 1.12.2, and the plugin you're looking for is solely not listed because the latest release doesn't support it
There doesn’t happen to be a way to get the build number from the plugin jar right? Prob not cause you don’t shade paper api into it
Well it’s an indicator of what features the plugin might be using. Anything from that build num and below
The thing is that with supported version numbers, etc; Literally every problem you're tryna solve with them is the exact same as the issues they cause in the long run
the version it's built against means nothing as to if it's going to work in future releases
and how sensitive version numbers are for plugins depends 100% on the plugins
Imagine if changes were actually tracked, and automatically compared against built plugins to determine minimum and maximum versions.
I mean... we could use CI type thing to see if the plugin actually loaded on various versions
but that wouldn't test all the features of that plugin
It would be more thorough to have a program check the bytecode to determine where it reaches, and compare that against what was added/removed/changed
And then just spit out all the versions the plugin would have no issues working on
you'd also need to have some way to analyze reflection, etc
CI method would also be 100% unviable
well yeah, I was just spitballing
(inb4 the version test CI falls behind as far as spigots premium resource queue)
yeah, itd get crazy backloged
Well wait a second actually, would reflection actually be an issue if the programmer isn't trash?
There would also be a manual selection for authors
lol
that is what we were talking about
and how tf to do something like that, if at all
?
(have manual version selection for authors)
I mean, people implement their entire nms level stuff in reflection
Whats complicated?
Coz, you know reflection > doing stuff
well as zzzCat pointed out, its really build number based
cause new features in paper get added all the time
not just in mc updates
Servers dont usually update with every build though
I just don't think that there is a magical solution here, having version selections is nice and should be per-build, etc; But, really, you're not solving an issue here
Aligning to minor revisions would probably be best
Well... minecraft patch* revisions
I'd just stick to mc versions for paper, etc; whatever format bungee/waterfall is using right now, and same for velocity
you ofc would still have issues when authors don't update that info
fuck em
but I think having at least mc versions as selections, would at least provide some information, even if its incorrect
is it better to be uninformed or misinformed?
I mean
Ideally people would rely on stuff like critical thinking, reading the reviews/comments, etc
Both have equally unfortunate outcomes
shamefully we live in the real world and people are lazy morons
A true shame
just throwing this in here since I wrote it on another discord https://i.imgur.com/964Sef8.png
in development for over a year 
wasn’t it?
at least you’ve been working on it for a while lol (I don’t experience time as a student)
@barren shale yeah, you're correct - in fact, it's been in development for over 14 months now and I'm really tired of waiting for Adventure to have a stable API
ah :p
Oh boi
sorry tux 😦
soon™️
Is hangar released yet? Or coming soon?
Soon
™
holy cow. ok, now I have a full appreciation for why taking the entire frontend from sponge is such a massive time saver
spent like 3 hours adding one small page so admins can add versions for paper/waterfall/velocity
DraMA genERATor: Kashike annouces stable adventure is tied to hanger release!.
DMAERAT
.
useful
What does the label mean?
"Platform Versions"?
admin site to edit selectable versions
didn't look at it yet, but that looks nice
maybe server? idk
yeah, I guess server is good. I just didnt want the same icon
+1 on that
So do you manually add the versions or do you select check boxes? I feel like it might not be the best idea to let people free-type stuff.
@leaden lily that is the admin page for available versions
its a bunch of checkboxes when you upload a version
Okay cool
the versions on that page, affect what checkboxes are shown per platform
lol yeah, would not be good for people to free type the version
Awesome
k, so tags isn't working right off the bat. im not sure I understand how this whole fontawesome thing is working. there are 4 fontawesome dependencies, and idk what the difference is
Which ones are there?
"@fortawesome/fontawesome-svg-core": "1.2.30",
"@fortawesome/free-brands-svg-icons": "5.14.0",
"@fortawesome/free-regular-svg-icons": "5.14.0",
"@fortawesome/free-solid-svg-icons": "5.14.0",
Okay yeah those are all needed
They split up how the items are stored
You have core, and then you have transparent icons and then solid ones
k. but tags isn't showing up. like I do <i class="fas fa-tags"></i> and I get the not found icon thing
Lord okay I'm a little out of it right now. What language is the front-end being written in?
do I have to import each icon that I use?
cause I found a js file that seems to do that. https://paste.gg/p/anonymous/565a58ea80244d1b9da81cd8fb5fcc90
Yeah you might have to import it. Sorry, I'm not at my PC right now so I can't check for you.
ah yeah
It's different in regular vs react and stuff.
ok, I didnt realize each new one I had to import, I thought they'd all be available
Oh this is just Vue.
Yeah you will have to important the icon.
I'd like to setup a dev environment for Hangar sometime I just need to setup docker / postgresql database.
ya, there are some instructions on the README
What port does it default to? Doesn't seem to print it out.
Hmm then maybe it didn't start properly.
oh yeah, if you aren't using this along with hangarauth, then you don't use docker for everything
Yup
the console output should output any errors in boot up then
Okay yeah it's something with it creating stuff in the database.
ERROR: relation "roles" does not exist
oh yeah...
the db migration expects that the table already exists
did you run init.sql?
Probably not.
although...
yeah, so what you wanna do, is make sure there is a db user named hangar, and a db named hangar
Yup I did that
Okay
atm, the migration system expects that to already exist
(because it was added after the fact)
itll then apply the other 3 migrations when you start the application
Yup, that did it, thanks.
nice
How long does yarn run serve typically take? I don't think it's actually finishing because it doesn't actually bring the localhost server online.
do I have to import each icon that I use?
@random badger yes you need to
shouldn't take that long. but all yarn run serve does is allow hot-reloading of all the files in the frontend folder
ya, I figured that out mini
Both Kenny and I stumbled upon that before
Oh so then what's the proper command to get the webserver up and running?
Could've sworn that's what I did.
or mvn spring-boot:run, or whatever the maven goal is
Ahh let me try that.
maybe its spring-boot:start idk
Yarn run serve never quite
Quits
It's a dev server for the frontend, it runs indefinitely
Yeah I'm, trying the spring-boot run now.
I think it did it because it got to the spring part
should be some big SPRING ascii art
Aha I got it.
I told it to start and then I stopped it and then I did run.
This is really cool!
Oh I love that you can have multiple pages for each plugin page.
yep! atm there is only 2 deep pages, but itd be nice to have more than that at some point
yeah, not implemented yet, but is the plan.
Would be funny if you had an "import from spigotmc" button.
Okay so actually it kinda works to an extend. You can use an online converter from BBcode to Markdown.
can probably just link to that converter when editing a page right?
Yeah, it's just not perfect yet, still playing with it.
The markdown seems to be different in ore than on github. I copy and pasted directly over and not all of it came out properly.
what seems to be different?
Not sure it works properly declaring variables to use later.
For example, this is the GitHub page on PlaceholderAPI https://github.com/PlaceholderAPI/PlaceholderAPI/blob/master/README.md
Here it is in Hangar:
hmm. if you want, you can take a look at the MarkdownService. that is where its all rendered
Okay!
While I do that, I'll also tell you what's wrong. It's not allowing for MarkDown placeholders to be set (apparently GitHub does). So it's like in a class where you assign a variable to use later. It's using the variable instantly when declared vs initializing when it's declared somewhere else.
yeah, I see what you mean. I don't know anything about flexmark-java, mini set that up.
should be possible ofc
Yup!
It was the first Google result that looked decent, lol
It has ton of options, I enabled GitHub like stuff already iirc
Yeah there's some GitHub stuff enabled, I don't know if it supports this placeholder stuff tho. If not, not the end of the world.
hmm, I don't see anything for placeholders in the documentation
k, adding an external link system for versions is pretty darn complex
slowly but surely, cleaning out that TODO column. @pallid yoke do you know what the plan is for email?
And we need to get the discourse situation figured out.
I don't have access to my main PC for the next few days as I'm moving (and I cba to set up auth/discourse on my laptop)
well looked like it's gonna be the same kind of discourse integration as Sponge has
heck I don't think my laptop would cope with Discourse lol
does Sponge have anything custom on the Discourse side? or does it just post with a link to ore?
just looks like they're slapping the exact messages on the forums, with 2 minor additions: updates get an extra header, and the main doc page is edited/sent to the forums (as the thread start)
slowly but surely, cleaning out that TODO column. @pallid yoke do you know what the plan is for email?
And we need to get the discourse situation figured out.
@random badger just make it take config options for smtp stuff (spring got an api) and for testing, plug it into the thing that is configured in docker
Forgot how it's called
mailhog?
Yep
That's perfect for testing, a real mail server without having to have all the troubles of running a mail server
In prod we then just use aikars mail server
Man, machine maker be overtaking me in amount of commits
It's really time that I get back into stuff :/
@pallid yoke hangar wen
You look two weeks away and he just finishes the project
lmao
@barren shale hangar wen
as soon as I emptied my 2 ovens
Oh, totally forgot about one thing. Caching. We need to go about and implement that everywhere
Yeah, but spring makes that amazingly easy
Just slap @cachable on service stuff and be done basically ^^
Without redis it is easier as well.
hi im new to this channel... what is hangar? :I

paper hangar is it like a hangar for paper airplanes?
oh ok
oh a plugin repository
so a hangar for paper plugins... i was close
for plugins*
Hey @pallid yoke. If/when I get around to adding all those other admin pages for value changes, should I do it in Vue? Ik ore is making some shifts to more front end stuff.
its significanly easier to setup tables like that with vue than to manually add table rows and such
and is probably easier to get looking nicer
bootstrap-tables ?
I mean... right now that version page I showed earlier is just a table that has buttons that add rows to it
or are you talking about bootstrap-table the addon thing
cause we aren't using that atm. we could for sure
yeah
we use it, very useful
mainly for searching and stuff
99% sure it can handle adding rows and stuff, though I dont like getting anywhere near js
ok yeah sure, that is an option. but its setup looks more complex than setting up that system with vue, or a vue table addon. and since we are already using vue, I feel like switching there would be better. but we shall see what Mini says
should hangar support IE?
well we are using babel so its not such a big deal
EdgeLib.suggestEdge()
Totally do new stuff in Vue is it's possible
Long time we want to get rid of jQuery
I meant to say that yesterday when I saw your commit but got distracted
yeah ok. ill rework it. I was gonna use the bootstrap-table package (which has a vue addon) but it requires jQuery. should I find some other table component?
we should probably wait to upgrade bootstrap when boostrap 5 comes out, as that removes the jQuery dependency
Bootstrap Vue is a thing
Also, don't really need a plugin for tables, should already be really easy to generate tables with Vue, right?
Does bootstrap vue replace the jquery stuff? I thought it just wrapped the jquery components inside Vue components
@pallid yoke yeah sure, but im sure there is a useful component that makes adding/removing rows nice
No, bootstrap Vue has no jQuery iirc
And generally, I don't really care
I want to get rid of the code where we directly use jQuery and use Vue cause it's easier to use
The internals I don't care that much about
this table thing does. https://bootstrap-table.com/docs/vuejs/introduction/
pins
why tf would the style tags in a vue component file not be loading? what are some possible reasons for that?
in 194891 years, 934561 months, 958194819 days, 85927924857773415 hours, 9591894995 minutes, and 5731328564832555 seconds
@random badger in your browser dev tools, does it detect webpack?
oh ok, I have to manually add the generated css file to the page
there's gotta be a better way of doing this right? Right now, if I want to use a vue component on a page, I have to add both the css file and the js file for it
hmmm
iirc typically stylesheets get built as a separate file to the JS, not sure if there's a standard way to bundle them?
yeah, that's what I just discovered, that they were build separately. I don't know alot about how webpack does its thing, im usually using it in an abstracted sense, not directly
I bet the frontend isn't setup for single file components?
wdym single file components?
Where you have style, template and js in one file
It needs special handling in webpack to extract the css
it does that. it extracts it to another file
that's the thing I was missing, I had to add a link to that stylesheet in the page template
it also looks like bootstrap vue requires bootstrap 4
idk how well itll play if we have bootstrap 4 and 3 at the same time
yall are still on 3??
not by choice, that is what ore is on
Since if long term we want to go 5, Vue 3, remove jQuery
there aren't many breaking changes, if any, between boostrap 4 and 5
just new things
isnt jquer a dep of bootstrap tho?
its not like 3 to 4
Yeah that's too long to read rn, lol
not in bootstrap 5 chew
Open an issue I guess
i cant find any trace of bs 5 anywhere
alpha in june
oh it's v5.getbs.com
they are also dropping IE support in 5
finally
wonder how good this is http://upgrade-bootstrap.bootply.com/
A free Bootstrap 4 upgrade tool to convert Bootstrap 3 to 4. Create a custom Bootstrap 4 build from SASS to CSS. Learn what's new in Bootstrap 4, and migrate code online.
@pallid yoke you got a preferred js library for making http requests? if we want to eventually get rid of jquery, $.ajax wont be an option right?
I always use axios
Idk if that's good or bad
I think Vue nowadays has a client too
its what ive always used as well, but I also dont know if its good or bad
But axios is nice to use
https://github.com/pagekit/vue-resource this maybe?
5 min Google says axios is fine, let's just use that if you got experience with it too
ok
man yeah, I just re-did the platform versions thing in vue, was easier to understand
way nicer
oh yeah sexy
hmm.. I wonder. right now, if you upload a zip, it tries to find the first jar file in that zip. what if... what its actually supposed to do, is support multiple versions by putting them all in one compressed file
and it tries to load the meta from all the jar files in the top level of the compressed folder.
dang fancy
the whole multi-platform support hasn't been figured out in general
is that what ore does?
we need to support that in multiple places
like, what's the point of uploading a zip otherwise
will you make an app? lmao
hangar api exists, make your own :)
yeah right, an app to download and upload plugins from your phone 
oh, ok. Well, i think i should start with figuring out what is spring...
its a season 🙂
pls say json api
ive always wanted to do a graphql api
its a query language for apis
oh, cool
instead of having various api endpoints, you only have one. and you request exactly what you want
o thats cool
whats this endpoint from? Communication Endpoint or service-oriented architecture?
lmao
well, ok, ill read all of this topics
huh, it seems cool to me, ive just never had a chance to use it
hey api, give me all memes by this author, but dont tell me the author, i already know them
api: "gotchu" then sends all memes without author field
like that?
You basically posting scripts around
It's like the dum Nexus api where you post groovy
Like, wtf
Just gimme rest
now i kinda get what endpoint means
Will hangar be able to filter plugins by popularity, # of downloads, ratings, etc?
no ratings
That's not good
how is that not good
yes it is
Ratings are a mess anyways
If a rubbish plugin with bad code is uploaded, how will most people know?
Read the forum
yes
View the source
^^
i thought it would force
No policies are decided
Well, some plugins are just so small and the creators so inexperienced they don't go open source
but they aren't obfuscated either
Still think ratings is the best way to tell at a glance. It would be pretty bad for example if Amazon didn't have ratings. Not quite like for like sure, but similar concept
i rarely care about rating, mostly reviews/discussion
words say so much more than 3/5
Ratings are the worst way to tell. 1-star rating with stacktrace? Yeah, that never helped anyone
I usually ignore 4-5 star reviews but will read 1-3
Often it's YAMLException due to a missing colon or quote.
can you star resources or anything? serve as a nice marker vs downloads, etc
finna make a hangar api lib 😤
hangar skript api lib?
are we doing that? making a "skript" platform category?
ok just checking 😛
if someone wants to write up some hangar guidlines, we might be able to start that discussion. although idk if aikar already had some in mind
graphql is pretty cool. I've used it for a work thing. some of the frontend clients for it tho are :peppega:
inb4 11) must be compatible with MC 1.8
Just as plugins should decide which MC versions to support, so too should they decide which Java versions to support
should that be a thing? a java compatiblility selector?
I don't think so
that's a nice idea, actually
Variances in support for java versions are less common than for MC versions
there's plugins that don't support 8
of all of those, you pick that to debate lol
Hard req. on Java 8 will never be a thing
but well eh, people should just mark that in their docs, I don't think an extra checkbox is necessary
mc stil uses 8 doesnt it? a tonof servers are still 8
realization is cool, idea is bad
Unlike with MC versions, supporting future Java versions is something your plugin should probably be capable of without any changes
not closed source. Are we doing that? I thought we were encouraging that
Encouraging closed source??
yall took that joke way too far, geez
open
pretty sure chew was just writing a bunch o nonsense down :p
There are no official policy positions here, it's all suggestions
wow
like, guidelines
nuked that as soon as a debate started
it's ok chew, i was gunna debate #6 cuz i prefer my plugins not to exist
troll plugins only
see, thats what i was lookin for
wow, I was actually trying to be serious... 😛
add a category that only allows closed source, obfuscated plugins with backdoors 
let's try again
hangar guidelines:
- Plugin MUST do 15 or more of the following
- Work
- No phone home
- Not trolling
- Exist
- Load properly
- Be a plugin YOU wrote
- Must be compatible with Paper
there ya go
no debate, all 100% perfect
there aint even 9
it's almost like it's a joke
dont forget the most important rule - ppl are stupid and lazy. They wont read duscussions, they just want to plug in and play. So thats why we still need ratings, and also it motivates to do more

you missed 4 and 5
I am aware you are all idiots and need me to point out the obvious.
That's exactly the reason why ratings are a poor indicator. As you have stated, most people do not read the description. When they realise they can't use the plugin because they didn't read one of the nuances of the description, they make a fit.
I removed 4 and 5, they were too controversial
And by nuances, I mean glaring red letters.
i see plugin devs get so mad over ratings when they really shouldn't
Replying to @cold ridge from https://canary.discordapp.com/channels/289587909051416579/746367733699969104/755899529286385674
implying theyll read ratings as well
"wow it's rating me bad cuz i had bug that did bad"
Pretty much every discussion/rating system is gonna get abused by dumb people at some point when a plugin dev doesnt bend over backwards for their request
yeah they get too caught up about it
just need to figure out how much youre going to tolerate it, draw your line, and start dealing with it
how about we make a test over the description, so to make a rating ppl will have to answer questions to prove that they read description well
sounds dumb
just like me
make them fill out a form like https://protocol.support/old/ every time they download an old version 
lmao
how do you know whether the user answered correctly?
lol kenny
so like the discord guideline gate thingy
put answers to overview page
it's sad that they actually needed the page, it's not even meant to be that much of a joke :D
when you set it up
did i pass
kek welcome to supporting older versions
what is this?
view link
ok
let me get off-topic by getting on-topic again, @random badger things currently get rather messy with multi-platform, since dependencies are just all over the place then, and we still kinda need to make it a bit prettier in showing that it supports multiple platforms (like a clearer separation between platform dependency and plugin dependencies, as well as the display in the home listing)
if you don't
through that as well, I'll look at it after I've relaxed a few days now 😂
im wondering if we should expand the "recommended version" to "supported versions"
hm should be pretty clear that latest always = supported, + dev builds if you specifically select them (otherwise people might confuse supported with stable or actual recommended or whatever)
ok, so for some reason, there is some weird caching going on where its not using the updated /assets/main.css file...
hmm
ok... so I have to rebuild the app, not just rely on webpack
because spring gets main.css from the classpath as a resource, and that doesn't get updated when webpack rebuilds
oh boy... this converting to v4 is gonna be painful. not even done with the home page...
you should just be real men and write everything in html and php
Api should be working
I think there is only 1 or 2 endpoints that haven’t been implanted
@narrow verge what did you try?
Is it much what needs to be changed in the convert?
@random badger the authenticate endpoint
Gives me a session token
But when i try it on say project, just gives me 401
is it a public project?
I'm just searching
/projects?q=test
In swagger shows response properly
The 3 test plugins
the 3 test plugins?
Yes
what 3 test plugins?
you can probably create some projects as the fake user on hangar-new
we can get it pretty much working, if mini has time to setup the auth
Also, will users have API keys or will it just be through the session things
yeah, users can create api keys
and you give those keys certain permissions that you have access too
Oh like GitHub tokens?
ive never used gh tokens, so idk
https://GitHub.com/settings/tokens I believe
yeah, i mean, generally that would be the public session
which you don't need an api key for
Ah, but you still need to authenticate every hour or so right?
I forget what the expire time is, but yeah
you will need to get a new session every so often
also, is the header for those still gonna be smth like WWW_Authenticate or whatever
for sending the session token thing?
yeah, at least thats what ore hangar spring says
pretty sure you send the session token in the Authorization header
Authorization: HangarApi session="<token>"
ah
oofies
Unsupported media type
hmn
ah because i didnt provide a json body
Internal server error now 😄
nah on /projects?q=bruh now
ye it's a bit broked i guess lol
maybe because no projects?
oh, yeah, just one thing wrong w/that endpoint
tiny sql formatting error
k, wait for latest to deploy
should work now
and the ?q= isn't what you think it is.
its literally insertted in after an AND in the query
so... ?q=p.plugin_id='test' or something
wtf
No it isnt? If it were, you could perform sql injections with it. query will use the words it get to look throught the name and description and maybe some other text which is being saved
yeah that still doesnt work but still lol
finna learn spring to fix your api issues smh 😤
oh hold on, I forgot about the queryStatement thing
idk why it wouldn't work in deploy... its working fine for me 🤷
Also, I think that @Define is necessary. Since the it will throw a superfluous exception if you removing without adding the AllowUnusedBindings annotation. Although the count project query has always been and odd one
if you do @Define, it can't find the named parameter :query
Thats odd
nah, if you do @Define, you can't use it in the format :varName
you can only use it like <varName>
You can if you add the DefineNamedBindings annotation
that does the opposite I think
allows you to use params w/o @Define as if they were also defined
cause :varName is a named paramenter
so DefineNamedParameters sounds like it should define all the parameters that don't have @Define on them
I would say it does, because when I made them with it, i needed to define them because string template, but then it throw the exception that it couldnt find it. After adding that annotation it did find them
but maybe my memory is just messed up
If in the query string, you have :varName, you can't have @Define on that argument
And there are no exceptions thrown when something is null? 🤔
is that why it's 500 internal server errorin
It used to be why
No, because there are a bunch of string template ifs to check for null
If something is null, it’s not included in the query
But if they arent used nor @define nor @allowedunusedbinding, the superfluous exception would be thrown, right? That could also cause a 500 response
I think we have allowunusedbinding
tbh, I don't really know why they aren't that by default
unless there is some massive performance hit if there are unused bindings
ok, so I think a majority of the conversion to v4 is done.
if someone is developing, try using the boostrap-v4 branch and note anything that looks wrong. I know a few things that still need changing, but im sure I missed a bunch
What're the steps to test? Unless that's documented somewhere
no steps
just mess around with different pages
and see if something looks wrong
I tried to check them all, but I may have missed some popups, or dialogs, or some obscure pages
oh. I mean readme should have instructions
Ah neatill
I'll mess around with it when I get home*
After I take my exam**
And finish my essay***
ok, I cannot figure out how to include the bootstrap js file w/o including it in the resources/public folder
something something webjars? idk exactly how they work tho
Yeah, idk anything about those.
Maybe that’s a solution. But it seems stupid to have to have something installed as a webjar, and an npm package. Like jquery
hmm maybe the webjars are only for the non-webpack stuff then?
Cant you also add it to the resources like its done with the public folder? the method for that is in the MvcConfig class
I really want to restructure the whole frontend build
Like, webjars suck, we just want webpack bundles
And then I can solve a ton of other issues with the frontend
right, well I remember back when we moved the javascripts folder to the frontend. way back near the start of all this. And you said that each of them really ought to be entries themselves, rather than just using the copy plugin to move them
well I tried making them entries, and they just didnt work
I made them all entries, and then adjusted all the references in the various script tags
Vue 3 shipped ^^
I'll take a look next week and basically redoing all frontend stuff with it
The build and stuff
sexy
Actually
Lemme spend work time on this instead and migrated our main website
Then it's easier for hangar ^^
wow mini thinks work > hangar .... smh
Heh, that would be fun. The main other contributor to the website frontend is on vacation for two weeks
He gonna come back and not recognize his website ^^
I did a bit of reading on the changes a while back, but I should read up on it too
Meh, v2 to v3 migraiton and ie11 support isn't done yet, coming q4
Vue.js - The Progressive JavaScript Framework
Best thing about v3
hows things going for hangar?
ie11 support
Who cares about IE11 @pallid yoke?
12 % of my users at work 😂 😂
Excluding internal traffic
Website traffic to our main website
Thankfully half of our edge users migrated to the new edge already, so that's good
noice
you work for an insurance company right Mini?
Ye
oh cool now you can insure hangar plugins against fraud or something idk how they work
and 11% of your users use IE11? what kind of insurance?
Electronic @random badger
I wonder if there's any correlation between browser used and insurance rates where @pallid yoke works 
Also this is getting off topic aaaa
assuming our systems are sophisticated enough for that 😂
ok, so say a version has an external download link
what should happen when someone tries to navigate to the download link for that version.
redirection right?
Navigates to some "hey! You're leaving hangar and going to x, we don't endorse or whatever this site, click continue to confirm"
Unless it's verified then just yeet them
ok, there are specific urls to download a jar from a plugin. should those return a 404?
so, the way I see it, if you want to remove all the webjars, you need to remove javascript code that requires any of that stuff from the templates, and the javascripts folder.
and then each of those javascripts file can be switched over to a webpack entry, and then included in their respective files
ok, ill steer clear
At most I'll be busy with this shit till Tuesday, then I can look at hangar again
What’s hangar? 😛
Yeaaah
everyone always asks what's hangar, but never how's hangar ;(
when's hangar
where's hangar
Why hangar
hangar who
hangar where
hangar wen
henger wan
hunger wen
in Australia we ask ..."How is it hanging? " which is colliqual for "How you going" to which the correct response when your fine is " A little to the left..."
pronounced Howzit Hanging
Australian slang is informal language used in Australia.
I just opened the hangar project 😮
:O

is the hype level so high that every time he opens hangar, he announces it 😮
"I opened my file explorer"
loud cheering
it's just been a while since anyone aside from Jake has done anything in code https://github.com/PaperMC/Hangar/commits/master 😂
I seem to remember Mini having to break out beer cam to get that much love
see, I havent worked on hanagr in a while sadly
epic 😎
something I'm annoyed at intellij is if I click on a dialog box on one monitor, it brings any other projects I have open on other monitors to the front, covering up anything else
not sure why it does that
yep
it has a few issues with multiple instances like that
I thought they fixed that one specifically but maybe Im misremembering
I have the git toolbox plugin, which auto fetches stuff in the background. if it fails to fetch stuff (like merge conflicts), that instance goes into foreground
even if I dont touch any IJ instance
ok, I cant do this webpack shit without using work config for reference, lol
does prettier look through the .ftlh files?
ya, didn't think so
we can make it format the template later too I guess
idk how itll handle all the extra <@ /> inside stuff tho
but like, I wanna focus on rebuilding the js and (s)css part first
ya, I was just curious
this is such a mess, we will properly need to export all methods and shit
do you mean methods that are called from some script tags in a template file?
those should probably be moved to a util file and then imported in the js file
134 errors after importing jquery everywhere 😄
can't you have webpack auto import jquery to all files?
instead of doing it in all the files
I could
but no real need for that
webpack will treeshake everything anyways, not every bundle will have jquery
right
ok, the rest will take a while, lol
its also stuff like this
ij is already warning that
and then there is stuff like this
where the fuck is that var defined?
lol what? it only appears once in all of ore as well
80, wooo
hey, are those 4 html files in resources/public/errors actually used?
where? cause we have an error template that the error controller uses?
ah yes
cause all 4 have the user icon and dropdown hardcoded in
which doesn't make sense if they were used
well I assume most of those will get weeded out when most of those individual js files get switched over to vue components
inb4 they are called in an eval()
I did a string search
so as long that eval isnt base64 encoded we fine 😄
ah yes
not its ignoring my disable comment https://i.imgur.com/csHZG5G.png
should ask about that in the sponge discord
meh, we can figure it out later
not bad
in theory, those should already work exactly the same as the old ones 😄
no, those are all js files
right, but the ones that load the components
those are the compiled bundles
Refused to apply style from 'http://localhost:8080/assets/build/main.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled.
urg
does that link 404? I sometimes see that error after it 404s trying to find it
you have to rebuild the project. add a comment in a java file, rebuild, and remove comment
I ran into this as well
normally it worked just by hitting build
its cause /assets looks in the classpath right? and that wasn't updated
well, kinda
I had to add a /css to the path too
which isnt showing up
even after restarting everything and shit
wtf
is main.css located in target/classes/public/build/css/main.css?
oh ffs
<link rel="prefetch" href="<@hangar.url "build/css/main.css" />">
I only edited prefetch 😄
lol
bleh
first setting everything up for deployment, can later look into making hotswap work
so that we have live reload for frontend stuff, especially when we do more vue shit we want that
review pls
😛
(pls dont)
+8,077 −8,908
at least that will get my contribution stats back up, lmao
wow...
I mean, a ton of moving shit around and prettier formatting shit
but yeah, I think all that is left now is hunting down those 404s, replacing htem with proper stuff, prolly playing with how the webpack chunks are created, making sure all webjars and manually copied libs are moved to yarn, and then we should be fine!
tomorrow ill most likely have to finish my contract thingy, so after that I have time again
this is way easier than I anticipated
Lovely
whats the dummy entry point
webpack was complaining not finding the 'app' entry
ill get rid of that junk later
added a few TODOs
so how do we serve, say, the filesize script to the frontend?
should be installed via yarn
right it is
then we can decide if we shove it into a common chunk, or if we create a new entry point for that file (where you would import the thing)
every file in entrypoints creates a new webpack entrypoint and thus a new chunk (aka file with bunch of stuff)
so like, we look if the thing is just used on one or two sites, then it should be put in a bundle for those pages, else it can go into a common bundle
(it should end up in a common bundle if its imported in some other js file managed by webpack)
pls screenshot, diff links on such large diffs dont really work well 😄
oh I see
that was my thing to force a rebuild 😄
fixed
am done for today tho, its 12 now and I wanna go swimming before work with my sis tomorrow, so I need to get up early, lol
HUGE icons
I love that my logo is still in there
oh wait, what about all the js files, the ones in frontend/src/js
webpack isn't doing anything w/those
Oh, ffs MM. I was supposed to take a look at fixing stuff at VT and forgot until you showed that screenshot lol
yeah, I have been doing stuff on hangar, haven't really spent any time on vt
they are only referenced in script tags in the templates
Else they get discarded as unused code
<@hangar.url "build/javascripts/whatever.js" />
Then you need to manually import stuff in the entry points I guess
Oh yeah those should be entry points
We don't want to manually import individual files that aren't entry points
right, but those should be entry points I think
but most of those will eventually be replaced with vue stuff
Yeah it looks like
The old webpack config had two loops for entry points and I only copied one, I thought the other went into an empty dir
Or wait, yeah, that's fine
Those files were really just manually referenced without webpack
Which explains why they don't use modern js features
Since they didn't go thru babel
We want everything thru webpack so that we can use all the new stuff js has to offer
and since they are going thru webpack now, Im not sure the functions defined in them will be availible where needed?
unless exporting them does that
Exporting them allows you to import them in other js files
They aren't placed into global scope anymore
yeah, that'll be an issue
No clue how we gonna handle that with the js code in the templates
Ideally we move that code away I guess
cause ik for a fact that some functions defined in main.js are used in a vue component somewhere
Since that's also not getting the babel treatment
Vue components go thru webpack, they can use import
yeah ok, so thatll be fine
but also, there are function calls in script tags in templates
But like, maybe webpack can handle html files and detect the js code? Never did that before
which wont work
If webpack can't handle that, we should move most of that code out of there
oh lol. some of the eslint disables you put on the same line as functions got moved one line down cause prettier I imagine
switching to use the next-line yeah
hmm, also, yarn serve doesn't work anymore. cause it starts a dev server on localhost:8081, which isn't what the templates are looking for to load whatever
Yeah, that's what I said, I worked on making full build work first, then I can use the url helper we already have and change the urls to localhost there in local mode
or maybe the reason is, that only yarn build actually puts the files in the target folder
oic
I mean, we could construct the old way, watch and incrementally build, but as said before, I want live reload, that's what we need the devs server with the websockets connection for
Added to Todo
But now I really have to go to sleep
💤
Are we switching to vue 3 now? Or waiting for more of the phased releases to come out?
The migration tools weren't published yet when I looked at it on the weekend
So it would be meh to do manually I guess?
I stilled stayed up for another hour yesterday and now I had 5 hours of sleep 😭 😂
There is hardly any migration.
Mfw you have been finishing my todos again ^^
That's not even what I mean
But you have been working on stuff I started again is what I am saying
It feels so strange not being the only one to work on a project
Progress while sleeping, what madness is this?! ^^
Well hopefully it’s better to have more than one person working on it. 👍
So I think one of the things that needs input, is how to determine whether or not to get the scripts/css from local host:8081 or /assets/.
The former is when you run the local dev server, and the later is when you aren’t developing the front end or you are in production
An Environments file that handles dev vs prod?
That's the generally accepted practice for webdev
Yeah, we have a file similar to that, (application.yml) I’m just wondering if I need to add yet another setting to it. It’s becoming kinda cluttered
An even better solution, would be to have html script and style sheet that have fallbacks if the primary source 404s.
Not sure what the best way to set that up would be.
I mean, the overkill solution would be to let all asset links go thru spring and let spring ping webpack or smth, lol
The question really is, in local mode, do we want everybody require to have the webpack server running or not?
Since you would need to build once anyways, I would argue making required to have webpack running is ok
Then we can just send all asset links to 8081, or, if we get cors issues, run 8081 as base and proxy everything using webpack to spring
Well the build once happens via maven.
Currently that’s how it’s setup, if the hangar.debug (idk if that’s the right setting) is true, it gets the webpack stuff via 8081
Ok, yeah, it can be it’s own setting
Not sure if the global hangar debug is good, but I see your point with more options
Yeah, I feel like there are already redundant settings.
Idk what the debug is even doing
I still think auto detection could be cool, surely you could ping 8081 and see if something that looks like webpack is answering
Yeah, it does seem like overkill tho. Cause in production, you know not to use 8081
Yeah, right, let's not then
At work we have a stage env var, but for local I always require yarn serve
You haven't looked at bootstrap yet, right? I remember downloading a zip via a config website for the theme, we really want to do that via scss
Yeah, the config.json was bootstrap 3
But that’s just there for reference now.
You override sass variables now. Look at _custom.scss
That has a bunch of overrides already.
Hey, i have a question i don't if i ask here would be wrong., how the bukkit plugin loader work?
Yeah, wrong place
If you want to look at possible overrides, look in the bootstrap folder in node_modules. There’s a variables.scss somewhere in there
Oh so it's not needed anymore?
That nice
I know how to configure bootstrap via scss
The config.json? No.
Just wasn't sure, so you did that with the bootstrap 4 port already?
Yeah
Can probably easily get rid of bootstrap from the public folder. Just need to add an entry point for both the bootstrap css and js files. You can do that right, add an entry point for something in node_modules?
That materialize style Machine-Maker mentioned in that newest issue, is that Vue Material? Or are those 2 different things?
Materialize is a css framework
I wouldn't be surprised if whatever Vue material is uses it
Nah rhsts a different implementation that seems to be closer to Google's guidelines
Ah okay
