| anthony_p has quit (Ping timeout: 480 seconds) | 10:21 | |
| thomasboimah | Yesterday, I was reading the Django documentation and also preparing myself for my work session with Zonny today. No blockers. | 12:00 |
|---|---|---|
| thomasboimah | ACTION DONE | 12:00 |
| zOnny | Good morning Thomas | 12:02 |
| thomasboimah | Good morning zOnny | 12:02 |
| zOnny | Last weekend, Thomas and I successfully launched Secosol's blog feature! Today, I'm excited to update the database through Mayfirst. No Blockers. | 12:02 |
| zOnny | ACTION done | 12:02 |
| thomasboimah | Yesterday, I was reading the Django documentation and also preparing myself for my work session with Zonny today. No blockers. | 12:02 |
| thomasboimah | ACTION done | 12:02 |
| zOnny has quit (None) | 12:03 | |
| zOnny | Nice | 12:03 |
| zOnny | Learning more about Django? | 12:04 |
| thomasboimah | +1 | 12:05 |
| zOnny | Sorry about my late connection. I was making my coffee :) | 12:05 |
| thomasboimah | np | 12:05 |
| zOnny | It is just you and me today? | 12:05 |
| thomasboimah | Yep | 12:06 |
| thomasboimah | the others are on Christmas break | 12:06 |
| zOnny has quit (Remote host closed the connection) | 12:06 | |
| zOnny | Thomas are you here | 12:09 |
| zOnny | I t seems like my irc isn't sync | 12:09 |
| thomasboimah | yes | 12:10 |
| zOnny | I had to go to the logs and see if you have replied | 12:10 |
| zOnny | Got it, It seems that it works now | 12:11 |
| zOnny | Ah Christmas | 12:11 |
| zOnny | it's all good | 12:12 |
| thomasboimah | Yep but you and I need to keep things going | 12:12 |
| zOnny | I was reading the logs and saw you all have moved to the new office | 12:12 |
| thomasboimah | Yep | 12:12 |
| zOnny | How it feels? | 12:13 |
| thomasboimah | Great! | 12:13 |
| zOnny | Working together from the same place | 12:13 |
| thomasboimah | super! | 12:13 |
| thomasboimah | It is great when working together as a team, it help motivate each other | 12:14 |
| zOnny | I'm happy for you all, I hope it helps you to plan things better and work as a team\ | 12:14 |
| thomasboimah | sure | 12:14 |
| zOnny | So let's start | 12:15 |
| zOnny | Not sure if you noticed | 12:15 |
| zOnny | but I have changed the Secosol DB to postgrest | 12:15 |
| zOnny | However | 12:16 |
| zOnny | I didn't spend much time with it | 12:16 |
| zOnny | In my perspective | 12:16 |
| zOnny | It is still using the Mysql | 12:16 |
| zOnny | can you login to the DB with your credentials | 12:17 |
| zOnny | I meant | 12:17 |
| zOnny | to the secosol's website | 12:17 |
| zOnny | It is still working, yes? | 12:17 |
| thomasboimah | +1 | 12:18 |
| zOnny | But the server, it did ask me to migrate all the apps again | 12:18 |
| zOnny | once it was changed | 12:18 |
| zOnny | Do you understand why we need to change to postgres? | 12:24 |
| thomasboimah | No | 12:25 |
| zOnny | they are built with fundamentally different designs and priorities, leading to mismatches in data types | 12:27 |
| zOnny | Can you go to the blog | 12:28 |
| zOnny | in the secosol website | 12:28 |
| thomasboimah | yes | 12:28 |
| zOnny | and click on the card view button | 12:29 |
| thomasboimah | That give an error message | 12:29 |
| zOnny | right | 12:31 |
| zOnny | Do you understand the error? | 12:31 |
| thomasboimah | I yes | 12:32 |
| thomasboimah | i think so | 12:32 |
| thomasboimah | The Django code is trying to use a database column (thumbnail) that doesn't exist in the actual database table. | 12:33 |
| zOnny | right | 12:34 |
| zOnny | It means that it is still using mysql | 12:37 |
| zOnny | because if you run it locally | 12:39 |
| zOnny | the error never happens, yes | 12:39 |
| zOnny | Are you checking the seeting.py? | 12:46 |
| thomasboimah | +1 | 12:46 |
| thomasboimah | zOnny, this is what i am think i don't know if i am right | 12:47 |
| zOnny | I also notice that os.getenv | 12:47 |
| zOnny | not working | 12:47 |
| zOnny | sure, what are you thoughts | 12:47 |
| thomasboimah | in production we are you core/setting or theme/setting i want to confirm something | 12:48 |
| thomasboimah | ? | 12:48 |
| thomasboimah | *using* | 12:48 |
| zOnny | good question | 12:48 |
| zOnny | wait what? | 12:50 |
| zOnny | what is going on on the prod theme settings | 12:50 |
| zOnny | I didn't notice | 12:50 |
| zOnny | that it is also trying to override core setttings | 12:50 |
| zOnny | it shouldn't override the core settings | 12:51 |
| zOnny | give once sec | 12:51 |
| thomasboimah | That is what i am trying to understand | 12:51 |
| zOnny | We shouldn't have any DB in theme settings | 12:51 |
| zOnny | the theme settings should only host the extra apps | 12:52 |
| zOnny | that is the goal | 12:52 |
| zOnny | It shouldn't override the core settings | 12:52 |
| zOnny | Theme settings should not exists | 12:53 |
| zOnny | but for custom features, we realized that it is needed | 12:53 |
| zOnny | That is why it is still there | 12:54 |
| zOnny | We need to update the settings from the secosol_home | 13:00 |
| zOnny | We shouldn't update it in prod | 13:00 |
| zOnny | we need to update it locally then push and pull | 13:00 |
| zOnny | Want to do it? | 13:00 |
| zOnny | Or should I do it very quick | 13:01 |
| thomasboimah | zOnny, one more suggestion | 13:01 |
| zOnny | sure | 13:01 |
| thomasboimah | Don't you think we need to remove from core.settings import * from theme/settings.py because it creating a circular import | 13:01 |
| thomasboimah | ? | 13:02 |
| zOnny | Is it there? | 13:02 |
| thomasboimah | yes | 13:02 |
| zOnny | Yes remove that | 13:02 |
| zOnny | Do you want me to do it? | 13:02 |
| zOnny | or you want to do it? | 13:02 |
| thomasboimah | anyone zOnny | 13:02 |
| zOnny | Wait I think we need that one | 13:03 |
| zOnny | the import | 13:03 |
| zOnny | so the theme loads the core default settings | 13:04 |
| zOnny | Let me update it | 13:04 |
| zOnny | one sec | 13:04 |
| zOnny | Do you know why we need that import? | 13:09 |
| thomasboimah | so that the theme can get all the core setting | 13:10 |
| zOnny | we need it because it will load the core first then the themes and add the INSTALLED_APPS += ['apps.blog'] to the core settings | 13:10 |
| thomasboimah | but here: if os.path.exists(os.path.join(BASE_DIR, "theme")): | 13:13 |
| thomasboimah | from theme.settings import * I see that Core Already Imports Theme | 13:13 |
| zOnny | done | 13:21 |
| zOnny | I see | 13:23 |
| zOnny | https://gitlab.com/novawebdevelopment/libreorganize/libreorganize/-/blob/master/libreorganize/core/settings.py?ref_type=heads#L278 | 13:23 |
| zOnny | you mean this line? | 13:23 |
| thomasboimah | yes | 13:24 |
| zOnny | They need each other | 13:39 |
| zOnny | Sorry I did step away | 13:40 |
| thomasboimah | np | 13:40 |
| zOnny | Do you understand why we need that line in core settings | 13:44 |
| thomasboimah | +1 | 13:44 |
| zOnny | The The if stament avoids import errors on deployments without a theme directory. | 13:45 |
| zOnny | *Statement* | 13:45 |
| zOnny | The import pulls in overrides like WEBSITE_NAME and adds theme apps (see libreorganize/theme/settings.py), letting the theme extend INSTALLED_APPS, on top of core defaults. | 13:45 |
| zOnny | Without this import, the theme-specific templates would never load, leaving the site with only the base/core configuration. | 13:47 |
| zOnny | Same goes in the theme seetings | 13:47 |
| zOnny | but the theme settings is secondary | 13:48 |
| zOnny | because the LO can still work without the theme dir | 13:48 |
| zOnny | That is why that circular pattern | 13:49 |
| zOnny | unless we find a better way in the future :) | 13:49 |
| thomasboimah | okay | 13:49 |
| zOnny | alright | 13:50 |
| zOnny | did you pull it | 13:50 |
| thomasboimah | +1 | 13:50 |
| zOnny | the secosol_home | 13:50 |
| zOnny | cool | 13:50 |
| zOnny | can you go to the wensite | 13:55 |
| thomasboimah | have you pull the change to the server now? | 13:56 |
| zOnny | Do you know why it isn't loading the os.getenv() ? | 13:56 |
| zOnny | yes, I did | 13:56 |
| zOnny | the secosol_home? | 13:56 |
| zOnny | I did pull | 13:56 |
| thomasboimah | you restart the server? | 13:59 |
| thomasboimah | because i am still getting the databass error | 14:00 |
| zOnny | I did restart it | 14:05 |
| zOnny | however, that doesn't fix the problem | 14:05 |
| zOnny | I thing the error is coming from the os.getenv() | 14:05 |
| zOnny | *think* | 14:05 |
| thomasboimah | I'm get this when i go to secosol.us on my browser are you getting the samething? Internal Server Error | 14:06 |
| zOnny | Oops | 14:06 |
| zOnny | I se | 14:06 |
| zOnny | That means it finally isn't reading mysql | 14:07 |
| thomasboimah | something like that | 14:08 |
| zOnny | right | 14:08 |
| zOnny | I'm trying to make it work with the environmental variables | 14:08 |
| zOnny | but mayfirst has a different configuration | 14:08 |
| thomasboimah | check the PostgreSQL database and user on the cp | 14:10 |
| zOnny | I have them already set | 14:10 |
| zOnny | Hold on give me 5 min | 14:11 |
| zOnny | Thomas are you here | 14:41 |
| thomasboimah | yes | 14:41 |
| zOnny | almost there | 14:46 |
| thomasboimah | okay | 14:47 |
| zOnny | Everything in the django is working properly | 15:04 |
| zOnny | however | 15:04 |
| zOnny | it seems Apache is denying the access | 15:05 |
| zOnny | According to the error.log | 15:05 |
| zOnny | I'm trying to understand why | 15:06 |
| zOnny | It is the way mayfirst works is very tedious | 15:06 |
| zOnny | I see | 15:26 |
| zOnny | I think we need to contact mayfirst | 15:27 |
| zOnny | I cannot find a way to restart Apaache :( | 15:27 |
| zOnny | This is what I got when I did my research about it | 15:29 |
| zOnny | No—you can’t restart Apache yourself on May First shared hosting. Apache is managed by MF; your .htaccess changes take effect immediately, but full Apache reloads/restarts require May First staff. | 15:29 |
| zOnny | Thomas are you here | 15:30 |
| thomasboimah | yes | 15:30 |
| zOnny | Are you familiar with this error? | 15:35 |
| thomasboimah | no | 15:35 |
| zOnny | Well, it is a very common error | 15:35 |
| zOnny | Is also know as 500 Error | 15:36 |
| zOnny | It is mostly Know as the Web Hosting Error when Apache denies access | 15:39 |
| zOnny | If you tail -n 100 ~/logs/error.log | 15:41 |
| zOnny | It will tell you why the error is | 15:41 |
| zOnny | Alright thomas | 16:04 |
| zOnny | It seems this will take me a time to finish this issue | 16:05 |
| zOnny | I have tried so many ways to get it running | 16:05 |
| thomasboimah | I am also investigating it | 16:05 |
| thomasboimah | But i think the best way is to email mayfirst and hear from them | 16:06 |
| thomasboimah | maybe they might give some important info | 16:07 |
| zOnny | yes | 16:08 |
| zOnny | We need to have it clear so we don't run into this issue again | 16:09 |
| zOnny | mayfirst is giving a very difficult time :) | 16:54 |
| zOnny | Now we are getting a different error? | 17:14 |
| thomasboimah | I just change this from the cp /media/data0102/sites/346107/include/libreorganize/venv/bin/python \ | 17:17 |
| thomasboimah | -b :24680 core.wsgi | 17:17 |
| thomasboimah | because it was invoking python AND gunicorn together | 17:17 |
| thomasboimah | -b :24680 core.wsgi | 17:17 |
| thomasboimah | -b :24680 core.wsgi | 17:17 |
| thomasboimah | -b :24680 core.wsgi | 17:18 |
| thomasboimah | i replace it with this: /media/data0102/sites/346107/include/libreorganize/venv/bin/gunicorn \ | 17:18 |
| thomasboimah | -b 127.0.0.1:24680 core.wsgi | 17:18 |
| thomasboimah | Now we are getting 503 error | 17:21 |
| thomasboimah | This great because i have see this before | 17:21 |
| thomasboimah | we now need to run gnuicorn | 17:21 |
| thomasboimah | and it might likely be fix | 17:22 |
| zOnny | Nice :D | 17:23 |
| zOnny | quick question | 17:51 |
| zOnny | can you create a file in this directory? | 17:51 |
| zOnny | ~/.config/systemd/user$ | 17:51 |
| thomasboimah | =1 | 17:59 |
| zOnny | ? | 18:00 |
| thomasboimah | -1 | 18:02 |
| thomasboimah | now it work | 18:07 |
| thomasboimah | we need to collect the static file | 18:07 |
| thomasboimah | to get the css work | 18:07 |
| thomasboimah | *working | 18:07 |
| zOnny | cool | 18:08 |
| zOnny has quit (Quit: Page closed) | 18:10 | |
| zOnny | It seems you got it, yes? | 18:11 |
| thomasboimah | +1 | 18:13 |
| thomasboimah | how is the site look on your side? | 18:14 |
| zOnny | html | 18:16 |
| zOnny | no css yet | 18:16 |
| zOnny has quit (Remote host closed the connection) | 18:33 | |
| zOnny | According to the error.log | 18:41 |
| zOnny | Alias wouldn't work with Apache | 18:44 |
| thomasboimah | it now work! | 18:55 |
| thomasboimah | everything is now good! | 18:55 |
| thomasboimah | wait | 18:55 |
| thomasboimah | the content | 18:55 |
| thomasboimah | let me fix that | 18:55 |
| zOnny | ok | 18:56 |
| thomasboimah | we also have issue with the blog now | 18:57 |
| zOnny | ? | 18:58 |
| thomasboimah | and also the other nav | 18:58 |
| thomasboimah | dem | 18:58 |
| zOnny | Any progress? | 19:29 |
| thomasboimah | still debugging | 19:32 |
| zOnny | got you | 19:37 |
| thomasboimah | zOnny, all is good now | 20:11 |
| zOnny | :O | 20:12 |
| zOnny | What did you change? | 20:12 |
| thomasboimah | this is what was give me the problem #STATICFILES_STORAGE = 'whitenoise.storage.CompressedManifestStaticFilesStorage' | 20:13 |
| thomasboimah | so i have to get rid on it and make the site use this static files: /home/sites/346107/web/static/ | 20:14 |
| thomasboimah | Wait | 20:14 |
| thomasboimah | Are you asking about the database issue or the css issue? | 20:15 |
| zOnny | in general | 20:15 |
| zOnny | also it is down again | 20:15 |
| thomasboimah | yes i stop gunicon | 20:16 |
| zOnny | it is working again | 20:18 |
| zOnny | I'm referring to what di you do to address the issue? | 20:19 |
| thomasboimah | Okay The 500 error was coming from the server, not Django itself. In our case, Apache (managed by May First) was denying access or unable to properly read environment variables (os.getenv()), which Django uses to connect to the PostgreSQL database. | 20:24 |
| zOnny | yes | 20:26 |
| thomasboimah | I verified that the PostgreSQL database and user exist are correctly set.T | 20:27 |
| zOnny | Do you mean that os.getenv() should work now? | 20:27 |
| zOnny | I did hard coded in the settings | 20:28 |
| zOnny | Due that Apache cannot reach it | 20:28 |
| zOnny | if you say that it can retrieve the .env so I will restore the os.getenv | 20:29 |
| thomasboimah | For now, os.getenv() won’t work because Apache can’t read the environment. Hard-coding the values in settings is the only way it works until May First configures the environment variables. | 20:30 |
| zOnny | I see | 20:31 |
| zOnny | I think the mayfirst customer service can help us out to get Apache work with os.getenv() | 20:32 |
| zOnny | but for now it is ok | 20:32 |
| zOnny | hard-coding is not a big deal | 20:33 |
| thomasboimah | okay | 20:33 |
| thomasboimah | are the content displaying on you side on the site | 20:33 |
| thomasboimah | *your | 20:33 |
| zOnny | No | 20:34 |
| thomasboimah | can you load the data from you side | 20:34 |
| zOnny | it is the data.json? | 20:34 |
| zOnny | or the live_Secosol? | 20:35 |
| thomasboimah | data.json | 20:35 |
| zOnny | on it | 20:35 |
| zOnny | I see :) | 20:36 |
| zOnny | I did load it | 20:44 |
| zOnny | You sure it was data.json? | 20:44 |
| thomasboimah | +1 | 20:45 |
| zOnny has quit (Remote host closed the connection) | 20:45 | |
| zOnny | it is there | 20:46 |
| zOnny | It took awhile | 20:47 |
| zOnny | Thomas are you here | 20:55 |
| thomasboimah | yes | 20:56 |
| zOnny | The site is down again | 20:58 |
| thomasboimah | yeah | 20:59 |
| thomasboimah | I stop gunicorn to check something | 20:59 |
| thomasboimah | I run it back it a bit please | 20:59 |
| thomasboimah | *will* | 20:59 |
| zOnny | no worries | 21:00 |
| zOnny | Do you mind if we continue tomorrow? | 21:00 |
| thomasboimah | okay | 21:00 |
| thomasboimah | zOnny, when will be start on nova website | 21:00 |
| zOnny | I need a better picture of mayfirst | 21:01 |
| thomasboimah | *we* | 21:01 |
| zOnny | Tomorrow | 21:01 |
| thomasboimah | Okay | 21:01 |
| zOnny | Novawebdev is hosted in mayfirst as well? | 21:01 |
| zOnny | I noticed that we cannot log in | 21:07 |
| zOnny | I think it is the ALLOWED_HOSTS | 21:09 |
| thomasboimah has quit (Remote host closed the connection) | 21:16 | |
| zOnny | Thomas are you here?> | 21:24 |
| thomasboimah | yes | 21:24 |
| zOnny | The css issue | 21:24 |
| thomasboimah | did you change something? | 21:24 |
| zOnny | Yes, I did add the CSRF_TRUSTED_ORIGINS in settings | 21:25 |
| zOnny | to make sure that log in works | 21:26 |
| zOnny | But I have commeted it out | 21:26 |
| zOnny | I got to go | 21:30 |
| zOnny | I will figure it out once I get back if you cannot fix it | 21:30 |
| zOnny | is that ok with you? | 21:30 |
| thomasboimah | okay | 21:31 |
| zOnny | ACTION signning off for an 1hr | 21:31 |
| zOnny has quit (Quit: Page closed) | 21:31 | |
| anthony_p has quit (Quit: anthony_p) | 22:03 | |
| thomasboimah | eveything now work | 22:49 |
| thomasboimah | ACTION signing off | 22:49 |
| thomasboimah has quit (Quit: Leaving) | 22:52 | |
Generated by irclog2html.py 2.17.3 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!