<RockyTV[m]>
you can expect no Linux and macOS support, modding will be bannable and EGS exclusivity. meaning: we probably won't have SD for KSP2
<RockyTV[m]>
epic games store
<RockyTV[m]>
I wouldn't trust that FAQ because it
<RockyTV[m]>
> and also is that new news or where we told anywhere before today?
<RockyTV[m]>
I hadn't seen that video
<RockyTV[m]>
but the bloomberg article shows T2's bad behavior and I wouldn't be surprised if they didn't deliver anything that was promised/said in the FAQ.
<RockyTV[m]>
<span class="d-mention d-user">VITAS</span> I was going ot ask you, do I just clone the repository and `yarn install` or do I need to run any other commands?
<RockyTV[m]>
I was talking to <span class="d-mention d-user">DasSkelett</span> . I misunderstood what you meant with dummy so nevermind, will just open it normally then
<RockyTV[m]>
how do I know it's the old one?
<RockyTV[m]>
I just got a SSL error
<RockyTV[m]>
and <span class="d-mention d-user">HebaruSan</span> I have the same caching issues even though I haven't accessed SD beta in a while
<RockyTV[m]>
oh
<RockyTV[m]>
can't you force the web server to force a cache reload or expire cache?
<HebaruSan[m]>
If it was up to me people would just learn to read JSON on web sites
<HebaruSan[m]>
Why just js files?
<Darklight[m]>
If it was up to me javascript wouldn't exist 😄
<Darklight[m]>
HEY
<Darklight[m]>
I was a little afk sorry vitas
<Darklight[m]>
4 minutes late
<Darklight[m]>
ping matrix
<Darklight[m]>
Wrong fucking channel >.<
Darklight[m] has quit [Network ban]
godarklight[m] has quit [Network ban]
im52kde has quit [Network ban]
HebaruSan[m] has quit [Network ban]
im52kde has joined #spacedock
godarklight[m] has joined #spacedock
im52kde has quit [Network ban]
pun[m] has joined #spacedock
pun[m] has quit [Network ban]
godarklight[m] has quit [Network ban]
RockyTV[m] has joined #spacedock
<RockyTV[m]>
hey about caching why not reduce caching TTL for js files only?
<RockyTV[m]>
why not cache and calculate the score every X minutes or hours
<RockyTV[m]>
it's not something we need to calculate very often, once an hour might be good
<RockyTV[m]>
hey <span class="d-mention d-user">Darklight</span> have you used a PBK VPN file on Linux, or tried to use Linux to connect to a PPTP VPN?
<RockyTV[m]>
I'm using typescript and react at work and it's pretty good 😛
DasSkelett[m] has joined #spacedock
<DasSkelett[m]>
Aha! Looks like we assign the `friendly_version` to `value` in the template rendering process,
<DasSkelett[m]>
Yes I think we can. Just need to iron it out.
<DasSkelett[m]>
I think saving the game in the session has been a bad design decision. If something on the page should be dynamic based on games, we should have either a way for the user to specify it (i.e. dropdown), or the game should be part of the request parameters, or part of the URL.
<DasSkelett[m]>
If I didn't miss anything, we are now only using the game id saved in the session during mod creation and on `/random` / `random_mod()`.
<DasSkelett[m]>
We should be able to eliminate the need for it in both of them. May need to move the "Random Mod" button from the dropdown to somewhere else (like the game overview), but that shouldn't be an issue.
<DasSkelett[m]>
We should also do a checklist of things to test on beta before giving it a go for production, like uploading a mod, updating mods, downloading mods, changing password, locking mods...
<DasSkelett[m]>
<span class="d-mention d-user">HebaruSan</span> I weren#t entirely sure myself where to put that checklist, I had the Beta->Prod PR in mind. I mean we can create it basically as soon as we merge to beta, keep it open and update it along the way.
<DasSkelett[m]>
<span class="d-mention d-user">HebaruSan</span> I wasn't entirely sure myself where to put that checklist, I had the Beta->Prod PR in mind. I mean we can create it basically as soon as we merge to beta, keep it open and update it along the way.
<DasSkelett[m]>
Maybe we should also investigate the restart webhook before merging to beta. Might be important for the merge to production, since neither HebaruSan nor me could do it manually.
<DasSkelett[m]>
The mod creation bug? Already have a fix in progress
<DasSkelett[m]>
Just wondering if I should bother to update `api.md`
<DasSkelett[m]>
Just wondering if I should bother to update `api.md`
<DasSkelett[m]>
With my fix for the mod creation problem the API will take the game version id instead of the `friendly_version` string.
<DasSkelett[m]>
Before #264 the client has sent the version.friendly_version if we had a pre-selected mod, and version.id as soon as he changed the game in the dropdown.
<DasSkelett[m]>
Since #264 it only sends the id.
<DasSkelett[m]>
Because we run the JavaScript part to update the game version dropdown right after page load.
<DasSkelett[m]>
* As soon as you change the game (which we fortunately only have on currently)
<DasSkelett[m]>
* As soon as you change the game (which we fortunately only have one currently)
<DasSkelett[m]>
Pay attention to what is assigned to the `value=` attribute.
<DasSkelett[m]>
What do you mean <span class="d-mention d-user">Darklight</span> ?
<DasSkelett[m]>
There's no messing up of the database.
<DasSkelett[m]>
The only place the database is involved in is querying it
<DasSkelett[m]>
But IMHO it doesn't make sense explaining my code changes to y'all without you seeing the changes, so I'll just create the PR now, and you can review it there.
<DasSkelett[m]>
Makes sense, will do as a second commit
<DasSkelett[m]>
Yep, experienced that too. Another thing we have to look into, but for me it's at the end of the list, want to fix the more serious problems first.
<DasSkelett[m]>
<span class="d-mention d-user">HebaruSan</span> I would squash the commits of #271 before merging it, since they are largely changing their own changes again.
<DasSkelett[m]>
But I thought it might be easier to review with them not squashed yet.
<DasSkelett[m]>
How?!?
<DasSkelett[m]>
But why does it work for me then?
<DasSkelett[m]>
*whe running locally, sorry
<DasSkelett[m]>
*when running the server locally, sorry
<DasSkelett[m]>
So should I wrap everything I moved in the line above?
<DasSkelett[m]>
no_results_text: "No Options found",
<DasSkelett[m]>
width: '100%'
<DasSkelett[m]>
});
<DasSkelett[m]>
$("#mod-game").chosen({
<DasSkelett[m]>
max_selected_options: 1,
<DasSkelett[m]>
no_results_text: "No Options found",
<DasSkelett[m]>
width: '100%'
<DasSkelett[m]>
});
<DasSkelett[m]>
```
<DasSkelett[m]>
The build script is compiling and copying it fine.
<DasSkelett[m]>
Maybe we should make another `not-so-static` folder which has a lower TTL ^^
<DasSkelett[m]>
I definitely tried ctrl-F5 checking this on Firefox, and it didn't work, so there must be another shortcut too.
<DasSkelett[m]>
As it looks, CTRL-F5 doesn't seem to be reliable, but I've turned off my PC so can't test anymore.
<DasSkelett[m]>
Don't know about prod, but on alpha and beta there are a lot of unused folders and files floating around, for example in `/var/www/virtual/spacedock.info/htdocs/`.
<DasSkelett[m]>
Only `./SpaceDock` is used AFAIK, which is 157 MB, whereas the whole htdocs wolder is 905 MB.
<DasSkelett[m]>
Yes, I'd keep the type hint PR out for now. It doesn't affect anything server-wise, and we can use it as soon as it is merged.
<DasSkelett[m]>
It also threw an import error when I accidentally tried to start the server on that branch, so we have to take a close look at the changed lines, which may take some time.
<DasSkelett[m]>
Haha, there's a log file from 2016.
<DasSkelett[m]>
Are there no scripts left that might be in use (on production maybe)?
<DasSkelett[m]>
There's a database schema migration included though, so switching back and forth might get adventurous
<DasSkelett[m]>
No idea
<DasSkelett[m]>
So this `Checker` watchdog is also not used on production?
<DasSkelett[m]>
Alpha is cleaned up and it looks like it still works.
<DasSkelett[m]>
Just did that
<DasSkelett[m]>
Comes back.
<DasSkelett[m]>
Crashes when trying to change password. Something with sending emails and celery, but I don't think a result of my spring cleaning.
<DasSkelett[m]>
```
<DasSkelett[m]>
File "/var/www/virtual/spacedock.info/htdocs/SpaceDock/lib/python3.8/site-packages/celery/backends/base.py", line 10, in <module>
<DasSkelett[m]>
from future.utils import raise_with_traceback
<DasSkelett[m]>
ModuleNotFoundError: No module named 'future'
<DasSkelett[m]>
```
<DasSkelett[m]>
how is this possible ?
<DasSkelett[m]>
I don't think so. But I have yet to find out where this comes from.
<DasSkelett[m]>
Okay not our fault. A new dependencyby celery v4.4.4, released only 6 hours ago, which they forgot to list in the requirements:
<DasSkelett[m]>
So we just need to install the future module.
<DasSkelett[m]>
Not sure, I guess complex innerworkings of celery.
<DasSkelett[m]>
I'd be all in for that!
<DasSkelett[m]>
Haha yeah that was quite funny. I've an alert set up via IFTTT that triggers whenever a post contains "CKAN".
<DasSkelett[m]>
I was quite surprised when I saw that I am in r/KDE...
<DasSkelett[m]>
Also considered just waiting until a new clery update is out, but who knows when this will be, and we can simply remove the dependency again then.
<DasSkelett[m]>
Well the "fixing itself" will just be that celery adds `future` to its `requirements.txt`.
<DasSkelett[m]>
So we'll have to install it regardless, either by adding it to our dependencies or by waiting until they add it to their dependencies.
<DasSkelett[m]>
I'd say "Rebase and merge"
<DasSkelett[m]>
No, it's good to have as a place to discuss and review proposed changes (pull requests).
<DasSkelett[m]>
Uhm yes, I do have all the other contributors as remotes. How should I checkout their branches otherwise?
<DasSkelett[m]>
Hmm, do we have database migrations automated somewhere in the systemd restart scripts?
<DasSkelett[m]>
Judging from the commit message they only got a single one.
<DasSkelett[m]>
Hmm weird. Anyways, I'm going to remove the if-else.
<DasSkelett[m]>
So is our solution, that the traffic/caching server refetches files under `/static` from the webserver every 10 minutes instead of once every 30 days, okay fo you <span class="d-mention d-user">VITAS</span> ?
<DasSkelett[m]>
I'd say most of the requests are still saved from the cache.
<DasSkelett[m]>
Anything more sophisticated would need tweaking the traffic server config, if at all possible.
<DasSkelett[m]>
So is our solution, that the traffic/caching server refetches files under `/static` from the webserver every 10 minutes instead of once every 30 days, okay fo you <span class="d-mention d-user">VITAS</span> ?
<DasSkelett[m]>
I'd say most of the requests are still served from the cache.
<DasSkelett[m]>
Anything more sophisticated would need tweaking the traffic server config, if at all possible.
<DasSkelett[m]>
Yeah if you look at `/browse/top`, the loading times are huge. I suspect it's the fact that we recalculate the score for _every single mod_ on every request just to return the top 30.
<DasSkelett[m]>
What if we save the score of each mod in the database as Mod.score, and recaclulate it every ten minutes via a `BackgroundScheduler`? Then we could use `.order_by(score)` in the database call, should save a lot on computation time.
<DasSkelett[m]>
Because when we change something in `/static`, like CSS or JavaScript, we'll have to wait 30 days for it to take effect.
<DasSkelett[m]>
Really?
<DasSkelett[m]>
It doesn't. As you can see in this picture.
<DasSkelett[m]>
What can I do? The webserver _would_ return a new file with a new eTag and a new last-changed and a new everything.
<DasSkelett[m]>
But this is useless if the traffic server waits 30 days to check _if the file has changed_.
<DasSkelett[m]>
You "usually" has to be an "every time", if this is what you want as solution. You would have to do the same for every merged PR to alpha and beta.
<DasSkelett[m]>
Sure, no hurry. Just came across this fixing something else, and wondered.
<DasSkelett[m]>
That's cached /browse ?
<DasSkelett[m]>
So investigating the mod creation problem now. For some reason the XHR is now sending the game version id instead of the `friendly_version`, which propagates through to the db query:
<DasSkelett[m]>
`WHERE gameversion.game_id = 3 AND gameversion.friendly_version = '4'`
<DasSkelett[m]>
I confirmed that this has been introduced with #264. I still don't know how though.
<RockyTV[m]>
when does it expire?
DasSkelett[m] has quit [Network ban]
RockyTV[m] has quit [Network ban]
DasSkelett[m] has joined #spacedock
<DasSkelett[m]>
If workers also have separate caches, it's 6*6
<DasSkelett[m]>
`recent` doesn't go through all of ModVersion, it only does a `ModVersion.count()` call for each mod. It also doesn't fetch _all_ mods first and calculates the score afterwards, but directly orders by `Mod.updated`, and offsets+limits the query.
<DasSkelett[m]>
`recent`/`updated` doesn't go through all of ModVersion, it only does a `ModVersion.count()` call for each mod. It also doesn't fetch _all_ mods first and calculates the score afterwards, but directly orders by `Mod.updated`, and offsets+limits the query.
<DasSkelett[m]>
I'd expect my proposed solution for /top to be equally fast.
<DasSkelett[m]>
That's all done in database, which can filter pretty fast.
DasSkelett[m] has quit [Quit: Idle timeout reached: 10800s]
im52kde has joined #spacedock
Darklight[m] has joined #spacedock
im52kde has quit [Network ban]
Darklight[m] has quit [Network ban]
DasSkelett[m] has joined #spacedock
<DasSkelett[m]>
PR that implements my suggestion is up. Consider it WIP for now, I'll go over it again tomorrow and also try to benchmark it after seeding my local database.