#web-development

2 messages Β· Page 197 of 1

gusty reef
#

Like I go to school and when I am back home i make my hw and immediately work on the site

echo iron
#

I understand, but that is not what is meant by dynamic or static

gusty reef
#

Oooh idk actually like I still have no idea how my site is gonna look

#

Probably just 1 page

#

Do you have a site

#

And how much is it going to cost

echo iron
#

Well based on what you've told me, I think you could get a site up quicker than 6 months if you apply yourself

gusty reef
#

Nice

echo iron
#

I don't have a site that is publicly available right now

gusty reef
#

Ohh wdym with publicy

echo iron
#

Hosting plans are pretty cheap, but cheap can be relative

#

The site I am working on is in dev state, so I just run it localy

gusty reef
#

Ohh cause if it's like 20 dollars a month I need to find a way to make money online

gusty reef
echo iron
#

taKE A look at their pricing, this isn't a direct recommendation, but an example of what the cost may look like

#

guess it would help if I posted the link

gusty reef
#

Nice

#

So almost 3 dollars a month

#

For a site

echo iron
#

yes, with a catch, note the * asterisk

gusty reef
#

But can it get than like unlimited visitors

echo iron
#

the next year the price will increase

gusty reef
#

Ohh damn

#

Than I really need to find a way how to make money online haha

#

So I can run a website

echo iron
#

it is hard to define unlimited, if you have a 1 page site, not really creating much server load because you are not doing anything on the backend, you will probably be fine

gusty reef
#

Nice

echo iron
#

bear in mind you are probably also underestimating how long it will take to buyild a following

gusty reef
#

But it can handle like 50k visitors right cause idk how it works but I readed that some sites can only handle a limited visitors

gusty reef
#

Ig

#

So now I only need to see how I can make that money online to run that site

echo iron
#

i mean a basic site that is only html, css and a few png's isn't going to create much server load.

gusty reef
#

What does server load mean like how many memory or bruh idk what I am talking about πŸ˜‚

echo iron
#

how much memory and cpu you are consuming from the shared resources

#

all cheap hosting plans are on shared servers, so you split resources with your neighbors

gusty reef
#

Ooh nice so I had it almost right with memory

echo iron
#

yah

gusty reef
#

Do you also have a cheap hosting plan

#

Like what I am gonna do

echo iron
#

i have a hosting plan, it was cheaper to get the plan than just register the domain. However since shared hosting packages almost never support python in any meaningful way, I will probably have to pay for a VPS at some point

gusty reef
#

Should I do freelancing work to get that 3 dollar a month

echo iron
#

You can, definitely.

gusty reef
#

Nice

#

But i don't have any skills

echo iron
#

You will build them

#

work on your site first

gusty reef
#

I can try it tho

echo iron
#

get to know html and css like the back of your hand

#

πŸ˜›

gusty reef
#

Okay that seems nice tho cause next year I am going to follow ict on school

#

And I am going to work with arduino than

native tide
#

You can run a decent amount on a $5/mo VPS with some linux skills.

echo iron
#

@native tide good point, @gusty reef you should familarize yourself with Linux

gusty reef
#

What is linux

echo iron
#

You don't have to become a god, just good enough

#

it is an Operating system

native tide
#

Handful of commands and understanding docs gets you a long way.

gusty reef
echo iron
#

It runs the majority of the web

gusty reef
#

Cool

#

This is interesting

echo iron
#

I take it you probably don't have a job? student, etc

gusty reef
#

Yes I am a student

#

So idk how to get that money lmao

echo iron
#

would your parents spot you?

gusty reef
#

Idk maybe

echo iron
#

where I live $5 is nothing, but I know that isn't true everywhere

gusty reef
#

What should I do if they don't should I do freelancing or something than

native tide
#

How about this, @gusty reef . You make something worth putting on the web, and I'll pay you the $60 for your first year on a $5/mo server.

echo iron
#

freelancing as a noob is a bit dangerous,

gusty reef
gusty reef
echo iron
#

@gusty reef heh, not too familiar with the Netherlands economy

gusty reef
gusty reef
echo iron
#

my advice, before worrying about hosting, or how you are gonna pay for it; build your site locally, make sure you actually enjoy creating websites

native tide
gusty reef
#

Okay yeah I can try that first

gusty reef
#

Idk it feels weird to take ppls money

native tide
#

@echo iron is right though, you have a whole lot in front of you before you're even ready for that.

gusty reef
#

Yeah true

#

I can update you guys if you guys want it

#

Cause I still need to learn everything about coding

#

And stuff like that

#

So it's going to take time XD

echo iron
#

sure hang out, don't be a stranger

native tide
#

Absolutely. And I'm sure you'll have questions along the way and if you go with Python, this will be a good resource.

gusty reef
#

Okay thx

#

I'll install everything I need tomorrow on my laptop

#

What is the best way to learn coding

native tide
#

Depends on you...really. Books and or videos help, but nothing beats trying it out.

gusty reef
#

Okay so I just need to try things

echo iron
#

@gusty reef That being said, the site as you are describing it is less coding and more about layout

gusty reef
#

And do as much as i can everyday

echo iron
#

HTML and CSS are not programming languages

gusty reef
#

Like layout languages if that exists

#

Idk

echo iron
#

html is a mark up language, and css is a styling language for lack of a better term

gusty reef
#

Nice

echo iron
#

a lot of ppl start where you are tho

gusty reef
#

How old are you guys if I can ask you don't need to answer if you want

gusty reef
echo iron
#

then they realize they need a programming language, because they want more functionality from their site.

#

I'm in my 40's trying to make a career change

gusty reef
echo iron
#

hence why i am learning python, and yes exactly

gusty reef
#

I am 16

echo iron
#

ah youth

#

just carve out at least 30 minutes a day, and I think you'll do fine

gusty reef
echo iron
#

πŸ‘

gusty reef
#

Did you also started programming when you were 16

#

Or coding

echo iron
#

hgaha!

#

No when I was 16 I didn't think I would ever own a computer in my life

gusty reef
#

Ohh that's good tho cause I already have a glasses 🀣

#

When I am in my 40s i am probably blind lmao

echo iron
#

nah, I wear glasses too, since I was a kid

gusty reef
#

Nice

echo iron
#

r u using windows 10?

gusty reef
#

Yes

#

Cause I am on my school laptop

#

It has a ryzen 5 5600u and 16gb ram

#

So idk if that's good for coding

echo iron
#

search the M$ store for Ubuntu, it is a command line version of linux for windows, will let you familiarize yourself with linux

gusty reef
#

Okay is Linux like a whole software like windows

echo iron
#

Yiss

gusty reef
#

Cause I think I can't change from windows to Linux cause of school

#

Or I would have to buy a new laptop

#

Or pc

echo iron
#

it will let you run the Linux command line interface within Windows!

gusty reef
#

Nice

#

So I don't have to switch

echo iron
#

Get comfy with command lines...is also my advice

#

nah no need to switch

gusty reef
#

Okay thx

echo iron
#

yup

gusty reef
#

But I think I have to sleep now XD cause it's almost 2 am and I need to wake up at 6:30 for school so thx for all the help I'll start tomorrow after school with all this but I am going to sleep now

#

Bye

echo iron
#

later

#

good luck!

gusty reef
#

Thx

honest solar
#

guys does some one has a really nice DJANGO course like those from zero to hero

#

with projects included pls

cedar mortar
honest solar
#

what are ur thoughts with django for everybody

#

?

pearl vigil
#

Anyone know how to use the tmp storage on Heroku using Flask?

cerulean badge
#

how do i overwrite webpush_serviceworker.js in django-webpush?

candid meteor
cerulean badge
#

how do i show push notification only when tab is not visible?
document is not available in service worker
so i can't do document.hidden

native tide
#

the h1 or any elment on html not showen why

#

@native tide help

#

anyone

#

pls

#

.

tulip beacon
#

hey guys, does anyone have an idea why I'm getting this error in react js
Error: Invalid hook call.

little panther
quasi willow
#

why do people use linux?

native tide
#

@quasi willow are you asking in terms of development on linux

#

or just general every day use?

quasi willow
#

actually

#

both

native tide
#

linux is more lightweight meaning less bloated, quicker and more reliable than windows

#

hence most of the servers on the web that make up the "internet" are running on linux

quasi willow
#

what do you mean lightweight

native tide
#

windows in particular has so many trackers in its code as well as useless features that just eat up you RAM that it noticeably affects your performance

#

for example in games you would see an actual drastic change in FPS

#

if you ran some of "debloating" cleaner programs

#

that get rid of all the tracking and optional features

#

that run in the background

#

in linux thats not an issue most of the time

#

@quasi willow also security

#

compared to windows linux basically doesnt have any viruses

#

customisation as well, you get way more control of your linux machine that you do of your windows or MacOS machine

native tide
quasi willow
#

hmmmmm

#

but linux sounds so

#

boring

native tide
#

no its not

#

download arch

#

definition of not boring

inland oak
# quasi willow why do people use linux?

I am web developer, I develop application which run at Linux servers.

Using Linux for development helps me to learn the target where my apps will run

Plus all web developing tools have only Linux support by default. Windows and MacOs are supported at the remaining level with half arse amount of efforts.

Every stuff is just easier to install at Linux. CLI faster than GUI

Plus it is nice to have a bit of privacy. Windows is surely one big bloated spyware

If I would choose being desktop Dev, perhaps I would have remained at Windows

I keep having windows at dual boot purely for games btw. I am not 🍷 perverted enough for alternatives.

quasi willow
frank pawn
#

can i share my free hosted dynamic website, on 000webhost, to anybody else ?

inland oak
inland oak
#

Technically Android is Linux, but I heard people were finding windows better to contact their droids

#

Not sure for sure, I did not do mob dev

inland oak
inland oak
# quasi willow and android dev?

Plus... Partial support for mob Dev is extended to technically web frontend solutions. React native, Vue native, and few other things.
But kotlin should be more powerful by magnitude

#

I did not do mob Dev, that is just what I gathered as rumours ;)

quasi willow
#

k thanks

#

wait but

#

if linux is better, why do people even use windows?

inland oak
#

Because windows is preinstalled everywhere when u buy computer.

#

U got used to it

#

It takes different habits to get used to linux

#

Windows is technically stupid user oriented first

#

Linux is technically oriented to developers first

quasi willow
#

then does that mean that you can install linux on your windows computer?

inland oak
#

Linux desktop experience can a bit suck. More advanced skill is preferred

inland oak
#

In different ways

#

Virtual machine
Dual boot on separated logical volume
And etc

quasi willow
#

and can i install window back again?

inland oak
#

Let me tell u them

#

Linux works fine without license keys
And in 99% cases u don't need to install any additional drivers

#

If u install Linux as dual boot, u keep windows and can return safely back at any moment

#

But

steady hatch
#

Hi

#

I'm new to web development in python

inland oak
#

If u will replace windows fully with Linux.
Reinstalling windows back requires from you
Having license key
Installing right windows for driver compatibility and downloading them

Usually windows key is written into your hardware.
Perhaps only specific windows version release will work on your pc

steady hatch
#

idk how to made web by py

ember crystal
#

Can someone help me with my Django code?

quasi willow
inland oak
#

I usually just install to separate hard drives (dual boot at physical level)

steady hatch
#

I just know how to create game by python

inland oak
quasi willow
#

so with dual boot, i can simply just change whenever i want?

steady hatch
#

:

inland oak
#

As a first experience it is possible that u will crash boot, and since u use logical volumes

#

I use separate hard drives just because of that πŸ˜‰

quasi willow
#

πŸ˜‘

#

man imma just use windows

#

for now

inland oak
#

U just learn how to handle it

#

And keep less attachments at pc. Everything backing up to clouds (or at least to external drives)

#

It is just best practice with any OS

quasi willow
#

k

inland oak
#

I love Linux desktop though

#

Found the OS of my dream

inland oak
#

Surely, lovely system ;)

#

I use 20.04 LTS for more stability though

quasi willow
#

hmm the UI doesn't look that bad

inland oak
#

everything can be configured, you are the root, you are the admin

#

in windows... access is quite abstracted from you. u a just having semi user access, pseudo admin.

#

i used windows for 15 years, but after few months of diving into linux... it was already a point of no return for me)

#

i return to windows only for games, or in case of need to develop smth for windows.

carmine oracle
sonic island
#

json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
getting json decoder error fetching records using nsetools
few hours back there was no such error
how to solve it?

hushed escarp
#

The decoder was expecting a value

#

but did not receive it

#

Check your database?

sonic island
hushed escarp
#

Yes

#

Check your API

#

OR

#

Records

#

They might be empty

sonic island
hushed escarp
#

check the records

sonic island
#

this is the line where i am getting the error

#

and when i am using it outside the project then also it is showing the same error ...

#

is that a problem with api coz in docs the same thing is working?

steady hatch
#

<!doctype html>
<html>
<head>
<title>Home page</title>
</head>
<body>
<h1>Home Page</h1>
<p>Hello</p>
</body>

</html>

#

I have an error with this

#

how can I fix this

golden bone
tulip beacon
#

hey guys, does anyone have an idea why I'm getting this error in react js
Error: Invalid hook call.???

golden bone
tulip beacon
golden bone
tulip beacon
normal skiff
#

Is web development worth doing for the future? 🀠

solar zephyr
#

That's a good question. But with everything, it mostly depends on how good you will be/are.

#

That's how you will get the people to consider you as an option when trying to make a website. So you can't exactly tell if it will be, maybe it will, maybe not, but you should proceed to do what you are skilled in and love doing.

normal skiff
#

Ok, thanks a lot. Also another question, can Python be used in professional web dev?

native tide
#

Yes!

solar zephyr
#

Ofc

slate kelp
#

Hello,
I need to help about Django models.
I have custom User model and email and phone_number fields. Users can signup with any of this fields and these fields are must be unique. When I use unique attributes for fields user must fill these. How can I use these fields unique and one of blank?

native tide
#

I believe adding null=True, blank=True to the field should do it. Null shouldn't count against uniqueness

cerulean badge
#

how can i show push notification only when tab is not in focus?

dense slate
#

And again offered basically nothing to get to the root of the problem.

grand tide
#

which is more powerful, php or python

#

and why

pallid lily
#

funny in python you have one way to create an array while in javascript they have alot of ways to create an array << disaster language

#

gota love python

solar zephyr
# grand tide which is more powerful, php or python

First of all, both have different uses. PHP is only for Web-Development. Python on the other hand, can do much more than that. So I do not know what you wan't to use them for. I would still go for Python because PHP is way to old. It's also not really the best because it can only function at the start of the program (before the website is actually on, I think). I would not consider learning PHP nowadays because you got way better options ahead of you. So yeah, Python.

#

Doesn't matter if you can do PHP, still gotta learn JS :/

grand tide
#

I use PHP for a lot of network automated tasks. over the open internet. but most things I've wanted to accomplish in .py, I fall back on php for anyway. since it's familiar.

solar zephyr
#

Well, at the end of the day, I can't tell you what to use and what not to use ;). If you prefer PHP and don't need Python, go for it.

native tide
#

why its not work the static

#

help pls

solar zephyr
#

Can you please explain your problem more precise?

native tide
#

the static file not change any thing

#

Codes do not work

#

I put it on the right track and I did
python manage.py collectstatic

#

@solar zephyr

solar zephyr
#

Are you using Flask?

native tide
#

no

#

django

#

when i collect the static no files that i create imported

#

it says 0 copeid

#

and i have a css folder and its contans a style.css file

#

pls help

#

@native tide

#

u can help me ?

edgy sable
#

I have a question is it possible to run a api website in a apache2

#

Or does this have to be started separately from the website or how does this work exactly ?

native tide
#

hellllllllllllllllllllllllppppppppppppppp

lilac solar
#

@native tide check the spelling of STATICFILES_DIRS

lilac solar
native tide
#

nothing no files or folders has been coped just the admin folder @lilac solar

#

how can i fix

#

i create the static folder in project

#

and i collect it

#

and no fiels has been collected

#

files*

lilac solar
#

Do you have the STATICFILES_FINDERS setting set to something?

native tide
#

what is the STATICFILES_FINDERS am a bignner

#

@lilac solar

lilac solar
#

add this to your settings.py and try running collectstatic again:

    "django.contrib.staticfiles.finders.FileSystemFinder",
    "django.contrib.staticfiles.finders.AppDirectoriesFinder",
]```
native tide
#

okay wait

#

you the best thx

#

bro

#

it works

lilac solar
native tide
#

okay, but i want to learn all the thing to not fall in the way you know

lilac solar
#

sure, i get that but I literally went to that templated project to look at what settings you were missing, they are the kind of settings that you don't want to think about for every new project, they need to just be there when you start the project.

#

That template also has a lot of good practices that will benefit you when learning Django even if you don't use them straight away

native tide
#

and am not good in eng , am ar so i just see the ar videos

#

its a hard to me

honest solar
edgy sable
lilac solar
edgy sable
lilac solar
lilac solar
pallid lily
#

any tutorials for how to world with django and React at same time? xd

edgy sable
native tide
# edgy sable How can I see if I already have mod_wsgi

From a stack overflow answer, may need some modification depending on what your VPS is running.

To check if it is installed:

$ dpkg -s libapache2-mod-wsgi

In case it is installed, you might check if it's loaded by Apache:

$ apache2ctl -t -D DUMP_MODULES

native tide
#

whats that mean

#

@native tide

#

@lilac solar

native tide
# native tide whats that mean

You added a new non nullable field to your model and the database doesn't know what to put there during the migration. You either need to allow it to be nullable or give it a default.

#

aha i fix it thx

#

i forgit ti

thick oak
#

Hellooooo, using django to make a site and have the site made but getting it on wit uwsgi is not working. Tried running it but keep getting module not found errors where it says it can't find my project which is specified under module in the uwsgi file module=Mysite.wsgi:application. Done some research online but those solutions didn't fix my issue. Any advice?

spare ermine
#

I am using Flask and socketio, and I cant seem to get the socketio.emit and the socketio.on to communicate with each other, no errors at all. Heres the code for the both functions: ```py
@views.route('/join/', methods=['POST'])
def joinGame():
gameCode = request.form.get('pin')
name = request.form.get('name')
print("sent info")
socket.emit('join-game', {'pin': gameCode, 'name': name})
return render_template('test.html')

@socket.on('join-game')
def joingame(data):
print('made it this far')
gameFound = False
pin = data['pin']
name = data['name']
for i in games:
if games[i]['pin'] == pin:
gameFound = True

if gameFound == True:
print('Bruh')
join_room(pin)
else:
print('Didnt find anything')
redirect(url_for('views.join'))```

gusty reef
#

Hello

gusty reef
native tide
#

what libraries can I use to make this kind of file explorer tree for my note taking app in html css and javascript

rocky current
#

https://www.jstree.com/ is probably a good place to start

runic lodge
#

Hey nano do you have a second?

#
<!DOCTYPE html>
<html lang="en">
<head>
    {% block head %}
    <link rel="stylesheet" href="style.css" />
    <title>{% block title %}{% endblock %} - My Webpage</title>
    {% endblock %}
</head>
<body>
    <div id="content">{% block content %}{% endblock %}</div>
    <div id="footer">
        {% block footer %}
        {% endblock %}
    </div>
</body>
</html>
#
from flask import Flask, render_template

app = Flask(__name__)

@app.route("/")
def home():
    return render_template("test1.html")

# @app.errorhandler(404)
# def page_not_found(e):
#     return render_template('404.html'), 404

if __name__ == "__main__":
    app.run()
#
{% extends "test1.html" %}
{% block title %}Index{% endblock %}
{% block head %}
    {{ super() }}
    <style type="text/css">
        .important { color: #336699; }
    </style>
{% endblock %}
{% block content %}
    <h1>Index</h1>
    <p class="important">
      Welcome to my awesome homepage.
    </p>
{% endblock %}
#

Having difficulty with jinja 2, not sure how to approach this as the page isn't loading the seperate files.

rocky current
#

Assuming the 2nd file is "test1.html", it needs to extend "base.html", not itself.

runic lodge
#

I ended up getting a bunch of errors as a result of the files

candid meteor
tiny arrow
#

How does anyone like JS

dense slate
#

What's the most efficient way to query a postgres DB for a string that I am splitting in Django? For each word in the string, I want to return the objects whose name contains one or the other from the split array as part of its name (so partial words would also match).

#

@inland oak

inland oak
#

second solution: Postgres probably should have bulk request feature

#

where you can request stuff with delay, when you already requested everything

native tide
#

if you want a django ORM way, you'll want to look at contains and icontains I believe

inland oak
#

Third solution:
for stuff like that I think people apply Searching Engines to databases, like Elastic Search
and query stuff with them for more speed

dense slate
#

I'm using the ORM, yea.

dense slate
#

I'm afraid I'm getting into some inefficient areas here though.

inland oak
native tide
inland oak
#

yeah, this in

dense slate
#

ah ok

#

Perfect!

dense slate
native tide
#

maybe not

#

you might have to do a big OR in the filter

#

.filter(Q(title__icontains="word1") | Q(title__icontains="word2"))

dense slate
#

And if you have n words?

native tide
#

great question. πŸ€”

dense slate
#

or if it's sometimes 1 or sometimes 2, or sometimes n

native tide
#

might have to construct a query in sql and then use the raw sql method

#

there might be a way strictly using the ORM, but I can't think of it at the moment

#

What's the use case, someone enters a bunch of words you want to find rows that contain those words?

dense slate
#

Yea, user enters one or more words in search. DB returns all objects with any of the words in the object name, either partial matches or full.

native tide
#

I've really only seen it done with a single string. After that, we use elasticsearch

dense slate
#

Ok, i'm not too familiar with that. I'll take a look.

native tide
#

Whole can of worms, but if that feature is important, might be something you want to use.

#

raw sql will be the easiest way to stay in postgres world

indigo kettle
#

you can do this

q = Q()
for word in search.split():
    q |= Q(field__icontains=word)
query = model.objects.filter(q)
#

not sure if that's good or not but I've definitely done it before

native tide
#

really? that's awesome

#

I was thinking that, but didn't think you could functionize it like that

indigo kettle
#

yup!

native tide
#

TIL

dense slate
#

Will try it, thanks!

scenic storm
#

in flask we use

if __name__ == '__main__':
         app.run()

why we use this we can use if a = = a or something else

tiny snow
#

It's because __name__ is only __main__ if ran by the main script, otherwise it's the name of the script (like an imported module or something, which won't return __main__)

#

It's used to mark scripts as runnable, and they will execute the code inside it only if they were ran as the main script.

gusty sphinx
#

So i'm trying to make a website with a made-up map that shows if parking slots are available based on license plate detection using pi camera to provide images. I would just like to know whats the best tech to use to achieve this. Like i started using django for it and i'm a bit lost on whether i made the right choice or i'm taking the long way to achieve my goal.

golden bone
native tide
#

why its not work

#

help

#

i fix it thx

#

} this is the proplem

#

hhh

native tide
#

this will make me add a file ??

#

@native tide

#

@lilac solar

#

any one of u u are the best

#

so help pls

slate kelp
#

What is the right way of if condition for this case?

def validate(self, attrs):
        """
        At least one of the phone or email information must be provided.
        """
        if "phone_number" not in attrs or "email" not in attrs:
            raise serializers.ValidationError(
                {
                    "email": "Email or phone number is required.",
                    "phone_number": "Email or phone number is required.",
                }
            )
        return attrs
native tide
#

it will work ??

pulsar oxide
#

Hi!
I'm looking for an asyncio package (I'm using Starlette) to provide a server push service (usable within a ServiceWorker)...
Any idea?

dense slate
#

@native tide That error is basically saying that "FieldFile" doesn't exist. So often this would happen because you didn't import it or you misspelled it.

native tide
#

Where could I get started with creating a dashboard for my bot? I've got a website running on Flask atm

native tide
#

i import the media for img

#

but now i want files

#

so pls help

#

@dense slate

dense slate
#

Is this in your models.py? Did you try FileField? I've never used FieldFile, but I think that's used in views.

native tide
#

okay ill try

#

@dense slate

#

what again

dense slate
native tide
#

@dense slate

dense slate
#

@native tide Sorry but I'll have to ask you to try to learn to ask some better questions and show an interest in learning how to figure these things out on your own. We aren't your personal debuggers but we will absolutely help you learn if you show some initiative to learn how to first debug these things on your own and then work out why you are stuck. For example, I have no idea what that error is referring to because you don't provide any of the traceback or any other relevant code, like your /post/add/ view. What have you tried to fix it?

native tide
#

i try

#

i makemairations and migrate

#

did not work

#

@dense slate

fast hare
#

Hey guys, i have a question. There is someone asking me for making a website. how much should i charge for the website? or how much is the correct amount?

dense slate
#

@fast hare Whatever you feel your time is worth. Find out how complex it is and how much time it will take. Try your best to convert it into hours and think about what you would want per hour to make it worth it. There's no right answer, just what you feel is appropriate for your effort.

fast hare
#

oh i got it

#

Thanks!

dense slate
hybrid lotus
#

Hey can I check if this is the right way of aligning tags in script?

edgy sable
#

How do I make in flask for example that if I enter 127.0.0.1:5000/ironman that it then returns for example an endpoint like e.g. 127.0.0.1:5000/data/ironman.png

native tide
# native tide did not work

you're adding a new field to your schema and don't have a default value set. Your database doesn't know how to add the new column.

native tide
pallid lily
#

they should make a channel for working with python and socket io for video streaming, voice chat etc xD

gusty reef
#

Hello I am back

#

Guys I have a question what is a free tool website that ppl often use

#

Cause I wanna make a website like that

edgy sable
#

I want it to pick an endpoint when I type 127.0.0.1:5000/ironman I want to make a gif api so to speak

spare ermine
gusty reef
spare ermine
#

thats fine, maybe someone else can help me πŸ™‚

gusty reef
#

Yes I am sure someone here can help you :)

#

Do you maybe know what for website I should try to make

spare ermine
#

um, idk

gusty reef
#

Cause I want to make something like a speed testing site, is that hard to make

native tide
edgy sable
native tide
edgy sable
native tide
#

Any reason you don't want to use a help room here?

edgy sable
native tide
edgy sable
#

but nothing happens

native tide
edgy sable
#

Exactly

native tide
native tide
edgy sable
native tide
edgy sable
#

i changed it back to ironman and the endpoint should be the gif not image_path ?

native tide
#

It's tough, you need to serve up the images somehow and they need to be accessible by the server. I need to get a few things done, but can help you in a bit.

edgy sable
#

so I'm testing everything on pycharm can it be because it does not work or how ?

native tide
edgy sable
#

pycharm localhost ?

#

127.0.0.1 ?

#

Or should I set it all up short on apache2 fast

native tide
native tide
native tide
#

I'm out for a bit, catch you later

native tide
#

okay

#

take your time

forest current
#

Is there a guide somewhere for using nodejs npm modules as ordinary JavaScript served from Flask /static/ ? Can I just comment out the require/import/export stuff in the .cjs files and call stuff from the global namespace?

#

I just have one module, I don't need to make a webpack bundle THANK GOODNESS

#

unfortunately it includes another .{,c}js file with requre() so I'm going to have to take the brain damage hit of trying to understand javascript, aren't I?

blazing imp
#

can someone help me? the error is: the User model save the user of the form but don't do the same thing with the Profile model

native tide
blazing imp
# dense slate What's the error?

none, I just want you to create the user using the User model and the profile so that I can log into the page, but only create the User not the profile

dense slate
#

Yea I was wondering why you were sharing the user form with the profile model.

dense slate
#

Those two points seem to be opposite of each other.

native tide
edgy sable
#

that works

edgy sable
native tide
edgy sable
#

It works

#

but it does not do what I want I can only send you something about dm so you understand what I want to have approximately please

#

Either I am explaining it wrong or I am lost

edgy sable
#

in any case it does not come out what I want

manic crane
#

someone please help thank you

#

django.db.utils.ProgrammingError: column Occupier_occupier.date_of_birth does not exist
LINE 1: ..."."is_staff", "Occupier_occupier"."is_superuser", "Occupier_...

#
    email = models.EmailField(verbose_name='email',max_length=59, unique=True)
    username = models.CharField(max_length=30,unique=True)
    occupations = models.CharField(max_length=200,null=False) #amount of occupations user does
    #cliques = models.ForeignKey(Clique,null=True,on_delete=models.CASCADE) #cliques user is in 
    date_joined = models.DateTimeField(verbose_name='date joined', auto_now_add=True)
    last_login = models.DateTimeField(verbose_name='last login', auto_now=True)
    is_admin = models.BooleanField(default=False)
    is_active = models.BooleanField(default=True)
    is_staff = models.BooleanField(default=False)
    is_superuser = models.BooleanField(default=False)
    date_of_birth = models.DateField(default=None)
    password = models.CharField(max_length=255,unique=True)
    objects = OccupierManager()

    USERNAME_FIELD = 'email'
    REQUIRED_FIELDS = ['username','occupations','password']```
dense slate
#

Did you migrate since you added date_of_birth?

manic crane
#

yes just now

#

and i got that error

dense slate
#

You got it when you tried to migrate, or did you get a successful migrate?

native tide
manic crane
#

thanks for replying will try now !

native tide
#

And Demi's question is good, did you get through the migration

#

or did it fail

#

looking to talk with someone about setting up my own file server as a music producer....

dense slate
manic crane
native tide
dense slate
manic crane
# dense slate Can you paste the stacktrace?

in _execute
return self.cursor.execute(sql, params)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/django/db/utils.py", line 90, in exit
raise dj_exc_value.with_traceback(traceback) from exc_value
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/django/db/backends/utils.py", line 86, in _execute
return self.cursor.execute(sql, params)
django.db.utils.ProgrammingError: column "date_of_birth" of relation "Occupier_occupier" does not exist

#

this was trying to add null=true to date of birth

dense slate
#

oh

#

did you add this field to admin.py already?

manic crane
#

i commented out my admin.register but i will uncomment now

dense slate
#

It should be commented out, since that can throw the error until it has successfully migrated.

#

I mean the error means that date_of_birth isn't in your DB, so something is trying to read it before you migrated.

#

So you need to remove whatever that is and migrate, then put it back in.

manic crane
dense slate
#

A good ol' fashion bug hunt! Yeehaw!

chilly garnet
#

Is there anyway to disable the "auto-fetch" functionality of dropdowns in django admin? I use javascript to only populate the state dropdown with whats needed but django still populates the state dropdown with thousands of entries before the JS runs

indigo kettle
#

look into raw_id_fields

#

if that doesn't work for you, you'll have to look into modifying the form field queryset

chilly garnet
#

I have but those interfere with the javascript

fossil pond
#

Hey guys! get_current_site(self.request) for me fetches example.com

#

How do I make it fetch the current url

#

Django

serene depot
#

can any suggest Django project for Beginnner?

#

Beginner?

fossil pond
serene depot
native tide
#

Id say blog app with login system and file uploads

native tide
#

its not work help pls

potent ferry
#

@unkempt temple would u be able to help

#

in my java script by any chance

unkempt temple
#

just ask the question, can't make any promises

native tide
potent ferry
#

Okay so I completed this question (on replit) and then my teacher said that for the question im abt to send i just copy the code and make adjustments

#

The second image is the one i gotta finish^

#

Would i be able to share my replit coding link so u can see what i got so far

unkempt temple
#

this isn't javascript my friend

#

this is java

potent ferry
#

Java idk

#

Ops

#

Wait do u know in java

unkempt temple
#

Java = car
Javascript = carpet

#

similar name, nothing to do with each other at all

potent ferry
#

Would u be able to help

#

I need help on while loops and for loops

unkempt temple
#

I don't feel like thinking about Java right now, I hate that language

potent ferry
#

Uh okay thx tho

#

Can somebody pls help

native tide
#

So you're asking a Java problem in python server

#

Do you see the problem

potent ferry
#

Nobody is helping in java server

#

Or my other coding severs

native tide
#

It doesn't seem hard. It's a loop

potent ferry
#

Sorry I’m begginer level in highschool learning this stuff

#

0 experience

native tide
#

While balance isnt 2000, do compound interest formula

#

Yes but you're not even trying

potent ferry
#

Ya i am i sat 2 hours the whole period in class tryna figure this out

#

Im not one if those kids i swear

native tide
#

There's no figuring out. Learn the basic concepts of java

potent ferry
#

Yeah i just forget a lot of stuff

#

Wait can u please help

native tide
#

No I hate Java

potent ferry
#

Would i be able to share my replit link so u can see what i have so far

#

Oh

native tide
#

But believe me you can solve it yourself

#

If you actually try and not just sit and think you can do it

potent ferry
#

Ya i think so too im just not thinking if the formulas or their not in my head

native tide
#

Try consulting teacher. They do help too

potent ferry
#

Is that wrong

#

Or anyone help

#

Wait can u please help with the bankbal =2000

native tide
#

Looks good to me

#

Simplify it by

#

+= and remove bankbal on right side

potent ferry
#

Which right

native tide
#

1st

#

If it works in Java that way. Best of luck!

potent ferry
#

Line 13?

#

Remove the entire line?

native tide
#

Oh and while bankbal != 2000

#

No nvm you don't get it. Put it back

#

And just change this while to this

potent ferry
#

Okay

native tide
#

Because you do it until it's 2000

potent ferry
#

Ya thats what I thought

native tide
#

Ya see

#

Next time do it yourself. Have some faith. Byebye

potent ferry
#

Thanks man!

native tide
#

how to get this there am doing it in the static but in django i dont know how

native tide
#

<div class="row row-cols-1 row-cols-md-3 g-4">
  
  <div class="col">
    <div class="card">
      <a href="Untitled-1.html">
      <img src="k.jpg" class="card-img-top zoom" alt="...">
    </a>
      <div class="card-body">
        <h4 class="card-title"><center>RKYfaultx8</center></h4>
        <p class="card-text">category : RP <br> </p>
      </div>
    </div>
  </div>

  <div class="col">
    <div class="card">
      <a>
      <img src="j.jpg" class="card-img-top zoom" alt="...">
    </a>
      <div class="card-body">
        <h5 class="card-title"><center>RKYfaultx8</center></h5>
        <p class="card-text">category : RP</p>
      </div>
    </div>
  </div>
  <div class="col">
    <div class="card">
      <a>
      <img src="h.jpg" class="card-img-top zoom" alt="...">
    </a>
      <div class="card-body">
        <h5 class="card-title"><center>RKYfaultx8</center></h5>
        <p class="card-text">category : RP</p>
      </div>
      </div>
  </div>
</div>
#

its a cars

#

card

#

boost rap

#

i take this part only

potent ferry
#

@native tide

native tide
#

with the style

potent ferry
#

hey man would u be able to help me with my homework

#

on while loops in java

#

begginer leve

native tide
#

am a python only and bigneer

potent ferry
#

ohh you dont know java?

native tide
potent ferry
#

augh okay

native tide
#

images and aligning stuff really isn't what I'm good at, sorry

#

it show in the lift side and i want it to showes lie that

#

@native tide

#

Sorry, not sure.

#

okay

#

thx at all

heady venture
#

Anybody using Fiver for side jobs? How is it?

candid glade
#

can anyone help me make these tags look better

#

Yeah right now my title and fonts look bad in html page how can I make them better

graceful flax
#

Hi

#

I've a Chat application built on Django Channels

It has the capability to send images

#

I send my message data over channels

And create my Message model object during that. Now I've to upload images as well. Uploading images via a REST API and creating/updating a ImageField is what I've done before.

Now in this case, I create the message object when something is sent over the channel and uploading an image over a websocket isn't good as I've read. How do people send images and create the object upon image upload success?

inland oak
#

I think you are already doing fine, since in this scheme you can apply client side caching to image stored as static file, so you should be fine

#

perhaps you ve been reading about sending images with web sockets from server to user is bad

#

the only small issue with all of it... that users send images to servers, and they can be not images but smth else πŸ€” ☣️

#

and if you store them as basically files in filesystem, with url link to object, that can be a bit not efficient too (if I remember right that what ImageField does), simple for sure though

#

people use things like Mongo DB to store files / images for example, as a way for better scaling
it makes sure to keep... stateful things out of your application/server. which is quite needful thing.

grizzled quartz
lavish ferry
#

Could someone please help me with this image, no matter what I do or what I google, I can't get this image to stretch to the edges of the page (100%) width:

.image-container-homepage {
  margin-top: 55px;
  width: 100%;
  height: 345px;
  position: relative;
  background-image: url(images/home_encryption.png);
  background-repeat: no-repeat;
  background-size: cover;
}
#
<h1 class="text-center">Data Encryption</h1>
<br>
<div class="text-center">
    <p>Encryption is about obfuscating data such that unauthorised observers, ideally, can't understand it. Encryption
        historically has been vital in protecting wartime secrets and now is integral to the internet as we know it.</p>
    <a class="btn btn-outline-primary" href="https://en.wikipedia.org/wiki/Encryption" target="_blank">Learn More</a>
</div>
<div class="image-container-homepage"></div>
<br>
#

Current result:

solar zephyr
#

I think you can move the width above 100%. Try that πŸ€·β€β™‚οΈ

lavish ferry
#

Already did, just distorts the image and fires it off the right side of the screen only.

#

Which also makes the page scrollable

frail cape
#

hey im new here, needed a help

lavish ferry
#

I will help you if you solve my problem rather than burying it πŸ˜„

frail cape
#

ohh

#

oops

lavish ferry
#

I am kidding, I don't think anyone is awake to help anyway

#

Go ahead friend πŸ™‚

frail cape
#

well i tried many servers

#

everyone is afk

#

lol

#

same story here?

lavish ferry
#

Probs, who knows

frail cape
#

actually im uploading images and vdeos to aws s3 with django, in local they are uploading fast, but in production it take a hell out of time

#

i dont know wht to do

#

if i upload 700 t0 800 mb it takes like forever

lavish ferry
#

Would I be correct that local is your machine and production is some datacenter far away?

#

Assuming I am, maybe your internet just sucks like mine

frail cape
#

yeah and production is like when site is live

#

haha no man

#

internet is good

#

about ur problem

#

probably ur image not getting full width

#

coz fo some div issue

#

i suppose

lavish ferry
#

Yeah probs, given it sits in a div with content:

<body>
    <!-- Build Navbar > Content > Footer -->
    <header class="site-header">
        {% include 'navbar.html' %}
        {% block header %}{% endblock %}
    </header>
    <div class="container content">
        {% block content %}{% endblock %}
        {% if not self.content() | trim %} 
        {% include "other/soon.html" %} 
        {% endif %}
    </div>
    {% include 'footer.html' %}
</body>
#

I wanted to avoid putting it in the header, pushed down.

frail cape
#

i had a similar

#

issue one time

#

what i did was , i had extra div which was not closed

#

i removed it worked

lavish ferry
#

Guess I can check that all divs close correctly

#

No it was all good. I will just put this into the header instead.

#

To much work otherwise.

native tide
#

,

calm bison
#

help? it was working before but idk now.

native tide
#

and it well work

#

i think

native tide
#

why not work and download the file

#

??

native tide
#

whats django?

#

what whats

#

django

frail cape
#

i guess im in wrong group

#

Django is a framework where u can build web apps

#

using python

calm plume
# native tide whats django?

It's a batteries-included Python web framework that has all sorts of things you can use to get a website up and running with python

winged orbit
#

Hello Everyone. Recently I developed a Python Package usage that can be used to setup a React application in a Django Project

#

Want to use React with Django without any hassles ?? Presenting to you django-webpack-dev-server, a command-line Python package that could help you to set up a react application in a Django project. This package uses webpack and webpack-dev-server to bundle your frontend code. It currently supports React in both the Javascript and Typescript programming languages.

A great thanks to Tim for his awesome tutorial for developing a Full Stack Web App with Django and React. Do check it out!

This project is open source and if you find any issues or have a new feature in mind, feel free to make a Pull Request. Your contributions are always welcome. I believe if this package also supports other frontend frameworks such as Angular and Vue, it would be even more helpful to the community.

Here are the links to the Project:

  1. Github: https://github.com/Jitensid/django-webpack-dev-server
  2. Pypi: https://pypi.org/project/django-webpack-dev-server/
  3. Youtube Demo: https://www.youtube.com/watch?v=6c-lPkKzI_E

LinkedIn: https://www.linkedin.com/in/jiten-sidhpura-40257817b/
Tech with Tim's Youtube Tutorial: https://www.youtube.com/watch?v=JD-age0BPVo&list=PLzMcBGfZo4-kCLWnGmK0jUBmGLaJxvi4j

GitHub

Django Webpack Dev Server is a command line Django reusable app to setup configuration files for React. It uses webpack and webpack_dev_server to bundle your frontend code. - GitHub - Jitensid/djan...

Django Webpack Dev Server is a command line Django reusable app to setup configuration files for React. It uses webpack and webpack_dev_server to bundle your frontend code.

Github: https://github.com/Jitensid/django-webpack-dev-server
Pypi: https://pypi.org/project/django-webpack-dev-server/
LinkedIn: https://www.linkedin.com/in/jiten-sidhpura...

β–Ά Play video

In this django and react tutorial we will be using python and javascript to create a full stack web app. The purpose of this series will be to learn how to use react and django together to develop a full stack web application. Specifically we will be creating a collaborative music playing app in which we will integrate our application with the t...

β–Ά Play video
#

Hope this package helps Django developers !!

native tide
graceful flax
viscid spade
frigid egret
#

Hey all z_wave🐍

#

I have a list of "labels" on an object, a pretty straight forward thing, normally it's solved with a choice field. But I also have a request to make it dynamic. Is creating another model necessary to allow changing and adding "labels" or can it be done without making another model?

spiral blaze
#

unresolved attribute "Column" in class "SQLAlchemy"
can someone tell me what i'm doing wrong? i followed the same thing in a tutorial and this happens

spiral blaze
#

oh right sorry lol

inland oak
#

Just kidding. Or not. I already received opinions like that

sonic kindle
#

do you guys know how to use beautifulsoup ?

patent glade
#

Question about Python, servers, and security

#

I'm making a python framework that interacts with a webpage. The frame writes the HTML from one or more documents supplied by the user (it stitches them together into a single document). This means that there is some limited opportunity to pre-parse both the HTML and any Javascript it directly links to (though, not any it links to from other locations on the web)

#

Also, the browser that is launched is Cefpython, a python binding for Chromium β€” this means I have some control over the settings of the browser

#

My question is, is it safe to use the basic http.server with no security measures?

#

They say in the docs that there are no security checks and so its only safe to use http.server for a quick-and-nasty dev server. I need my frameworks server to be distributable

velvet turret
#

No problem!

golden bone
#

I'm building an API route with Flask, and one or more integers for a certain value can be included in the JSON payload. In terms of what is generally considered clearer or better practice or just normal and expected, should I require input like a) "employee_id": "1" and "employee_id": "1,2" or should it be like b) "employee_id": [1] and "employee_id": [1, 2] or c) should I make it flexible and allow both?

inland oak
#

giving general info about everything related

#

not just beautiful soup

golden bone
native root
velvet turret
#

Never return a list as a comma-separated string.

golden bone
native tide
#

how to set a range for loop and continue in a page 2 ??

#

like this

#

and this will work

#

??

native tide
native tide
formal flame
#

ok

native tide
#

this my for

#

loop

formal flame
#

nice

native tide
#

the err

formal flame
#

you doing a veb

native tide
#

how to fix

formal flame
native tide
#

i want all the posts that have the category = resoursepack

#

i fix it

odd belfry
native tide
#

yp

#

i did that

#

thx

#

at all

native tide
#

my models

restive pine
#

I'm new to django any tips for debugging just spend a day trying to figure out that my linter was eating up an unused but needed import in my urls

native tide
#

ya am new to put on a pig level than u

#

And i have errs too

odd belfry
native tide
#

@odd belfry

manic crane
dense slate
#

Sure, try it

manic crane
# dense slate Sure, try it

tried it got this return self.cursor.execute(sql, params)
django.db.utils.ProgrammingError: column "date_of_birth" of relation "Occupier_occupier" does not exist

#

damn im losing my mind 🀣

native tide
#

I have a putton i want to get the file url from the models to download the file

#

ill check this after eating

fossil pond
#

Hey guys! I want my image URL to be inside the style tag like this but this won't work in Django. How do I make it work?
<div class="view" style="background-image: url('{% static 'images/IMG-1284.jpg'%}'); background-repeat: no-repeat; background-size: cover;">

#

Okay in other news this is working but I'm getting a lot of semicolon expected errors on Visual Studio

#

Whenever I put the static inside the style tag like that

edgy sable
#

i want to deploy a flask website on apache2 but when i try to type the command pipenv install it says python: not found

#

But I have python installed on my server

native tide
edgy sable
#

yes

#

with sudo install pipenv

native tide
#

if you type which pipenv what do you get back?

edgy sable
#

/usr/bin/pipenv

native tide
#

and you're in your code directory with a pipenv file when you run pipenv install

edgy sable
#

i am trying to run this file on my /var/www/API

native tide
#

can you screen shot the command you're running and the output

edgy sable
#

i run the file with pipenv install

#

what does he want to remove please he should just install it besides i have python 3.9.5 what i please the problem this pipenv

manic crane
#

can anyone help ? django.db.utils.ProgrammingError: column "date_of_birth" of relation "Occupier_occupier" does not exist

#

class Occupier(AbstractBaseUser):
email = models.EmailField(verbose_name='email',max_length=59, unique=True)
username = models.CharField(max_length=30,unique=True)
occupations = models.CharField(max_length=200,null=False) #amount of occupations user does
#cliques = models.ForeignKey(Clique,null=True,on_delete=models.CASCADE) #cliques user is in
date_joined = models.DateTimeField(verbose_name='date joined', auto_now_add=True)
date_of_birth = models.DateField(default=None,null=False)
last_login = models.DateTimeField(verbose_name='last login', auto_now=True)
is_admin = models.BooleanField(default=False)
is_active = models.BooleanField(default=True)
is_staff = models.BooleanField(default=False)
is_superuser = models.BooleanField(default=False)
password = models.CharField(max_length=255,unique=True)
objects = OccupierManager()

#

i try migrate and i get that error

native tide
native tide
native tide
#

you must be referencing the field somewhere in your code

#

does your server have 3.9 installed on it?

edgy sable
#

yes

manic crane
# native tide what's your OccupierManager look like?

class OccupierManager(BaseUserManager):
def create_user(self,email,username,date_of_birth,occupations,password=None):
if not email:
raise ValueError('Users must have email address')
if not username:
raise ValueError('Users must have username')
if not occupations:
raise ValueError('Occupiers must have occupation')
if not date_of_birth:
raise ValueError('Users must enter date_of_birth')
user = self.model(
email = self.normalize_email(email),
username =username,
occupations = occupations,
date_of_birth = date_of_birth
)
user.set_password(password)
user.save(using=self._db)
return user

edgy sable
native tide
#

@native tide, hi can u help me

edgy sable
native tide
native tide
edgy sable
#

but why does he not install anything

native tide
#

its not work why @native tide

edgy sable
native tide
native tide
# native tide

file uploads are tricky and this doesn't feel like a question. I don't see an error message or explanation of what's happening

edgy sable
#

I do not understand why he wants to remove it

native tide
native tide
#

it's trying to use 3.8 though, which is weird

edgy sable
#

uh and why

native tide
#

oh I know why

edgy sable
#

And what do I do now

native tide
#

remove pipenv

edgy sable
native tide
native tide
native tide
edgy sable
native tide
edgy sable
#

bash: pip3.9: command not found

native tide
#

which python3.9

edgy sable
#

and now ?

native tide
# native tide

honestly, not sure. file uploads suck. I don't have a good answer

#

what did that tell you

edgy sable
#

bash: pip3.9: command not found

native tide
edgy sable
#

I have already entered

native tide
#

what do you get?

#

I need to know for the next step

edgy sable
#

and then I pip3.9 install pipenv comes error

#

bash: pip3.9: command not found

native tide
#

you aren't listening

edgy sable
#

/usr/bin/python3.9

native tide
#

cd /usr/bin/
ls pip

edgy sable
#

pip

#

only stands there

native tide
#

ls -tla python

edgy sable
#

ls: cannot access 'python': No such file or directory

#

I already have the feeling I have installed Python incorrectly

native tide
#

ls -tla /usr/bin/python3.9

edgy sable
#

/usr/bin/python3.9

#

and then so root root date and etc

native tide
#

is it a link

#

paste the output

#

okay, try pip install pipenv

edgy sable
#

It works

#

should i try again

native tide
#

now try pipenv install in your project

#

🀞

edgy sable
#

bash: pipenv: command not found

native tide
#

how did you install python3.9

edgy sable
#

but got a thousand errors or whatever

#

somehow not everything worked

native tide
#

cd /usr/local/bin

#

ls

edgy sable
#

flask virtualenv

#

I have done something wrong

native tide
#

yea, you should have pip and such installed along with python3.9

edgy sable
#

can i not reinstall python3.9 ?

#

certainly too late or ?

native tide
#

you should be able to run through those steps again

native tide
edgy sable
#

sudo apt install build-essential zlib1g-dev libncurses5-dev libgdbm-dev libnss3-dev libssl-dev libsqlite3-dev libreadline-dev libffi-dev curl libbz2-dev

native tide
#

this on ubuntu vps? or debian?

edgy sable
#

ubuntu

native tide
#

might need to jump into unix channel for that

#

or try installing libc6-dev

#

do you have a lot on the VPS, could always start over

edgy sable
#

I have a lot of important things on the server

#

what is this unix channel

native tide
#

another channel here on the python server. need to resolve what's going on with that install before we can get pipenv working correctly

#

I need to wrap up some work, may be around later to help

gusty reef
#

Hello

native tide
#

you probably dont' want to store a file in a db at all

#

you want to store it in a bucket or on the server and have a path to it on your db

#

yp to make the user download it

#

@native tide

#

now u understand me

native tide
#

now you know what you should do, research how to do it

#

all that time researching and i dont fine only one ved about that thing

#

@native tide

edgy sable
#

Jo I look tomorrow what I can do I have python installed completely wrong

native tide
#

just reinstall

#

and check path active

edgy sable
#

Have already tried and have just made everything worse because I have entered other path or whatever

native tide
#

show me err

edgy sable
#

There is no error I just installed it a thousand times and entered something different from each page no matter I look at it tomorrow

native tide
#

k

ancient sedge
#

I'm trying to work with the "@keyframe move" to make an animation for the welcome class so that it appears to bounce onto the screen.

native tide
#

Absolute position plus before and after?

ancient sedge
#

@native tide my issue was I split translate wrong πŸ˜…

#

Spelt geez

wicked nest
#

Using Django crispy forms to render a form to a page so a model instance can be edited. Whenever I use Layout() it breaks the submission for some reason

wicked nest
#

nevermind got it

native tide
#

can anyone help me get started with django?

#

thanks

eternal panther
#

can anyone help me in my fastapi project?

restive pine
#

umm maybe i'm a very a basic user still have to figure out how to restrict my end point to user with api keys

native tide
#

a helper

calm plume
#

It was @naive crater

native tide
#

@naive crater in the web that was made by latkescary it said that its made using python

glad hare
#

can someone help with html?

twilit needle
#

I was just wondering, using asyncio, how many requests per second can u handle in python?
I could see that top frameworks like falcon max out at 80,000. Is it possible to go any further with any optimizations but same hardware?

last lily
#

Hey guys! I am using FastAPI for, well, building an API lol I have an endpoint that receives a couple of parameters, one of them is a list of strings. Anyone know how do I make sure the list is no longer than 5 strings and every string isn't longer than 20 letters?

toxic pilot
#

Why does python convert my javascript object to type none when it receives it as json, I'm using flask

dusk portal
#
def notes_search(request):
    if request.method == 'POST':
        searched=request.POST.get('searched')
        q1=Notes.objects.filter(title__contains=searched)
        if len(searched)>55:
            messages.info(request,'TEXT IS TOO LONG')
            return render(request,'index/notes.html')
        return render(request,'index/notes_search.html',{'q1':q1,'searched':searched})
    return render(request,'index/notes.html')
``` how can i take it advanced the next lvl  as im gonna deploy this n i dont want bugs
#

how can take a damn good search bar

solar zephyr
#

Are you using flask?

dusk portal
#

django

#

@solar zephyr

whole sierra
#

hello guys

#

In this django rest api authentication tutorial, you will learn how to use TokenAuthentication and SessionAuthentication and when each approach is appropriate.

7 Tips For Getting Better At Django:
https://mailchi.mp/dea592ab3f6d/tips-for-getting-better-at-django

Here you can find more information about REST API authentication:
http://www.djang...

β–Ά Play video
#

its just basic token authentication through username and password

#

but how do i make sure that the user is authenticated on each page?

#

none of the django tutorials seem to provide any context to that

golden bone
native tide
#

hi i need help

#

I want the user to be able to download the file
The file is stored in the media folder inside the files folder
And I want the user to be able to download it
And each post has its own file

golden bone
golden bone
# native tide so

So... "Can so someone please help me in #help-whatever? I'm trying to make it so a user can download a file." No need to invade a discussion channel.

naive crater
twilit needle
#

That's what I'm doing- but with fastapi instead for my backend

native tide
#

it gives me the path and i cant download it

native tide
#

How do i get the values from a POST request? i know it has something to do with flask.request

frank shoal
#

{{ request.values }}

native tide
native tide
#

hellllllllllllllllllllllllpppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppp

#

pleaseeeeeeeeeeeeeeeee

chilly obsidian
#

When I run a file and call a print statement in that program that does NOT change the file? But if I run the same program on that file with return THAT will change the original file?
I'm playing around with parsing and using my messed up apple music folder to see If I can clean it up with some python code?
I'd love to hear your thoughts?

#

sorry incorrect channel