Questions tagged [project1]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0
votes
1answer
6 views

How to get markdown info to HTML

Question from Project 1 in CS50W I'm stuck trying to get the markdown info from files to my HTML. I manage to get the markdown info into a HTML string, but when I input it to my HTML I get the same ...
0
votes
0answers
26 views

CS50W Django Project1 Wiki - Textarea issue

I got stuck at completing Wiki assignment because of strange behaviour of textarea in form, needed for creating and editing entries. Everytime user saves the entry, for each line of entered text there ...
0
votes
1answer
42 views

CS50Web: Project1 Wiki - Error loading markdown2 module

I've tried to import the markdown2 module in my views.py file but I get an error ModuleNotFoundError: No module named 'markdown2'. I've tried restarting my machine, uninstalling and reinstalling the ...
0
votes
1answer
26 views

Struggling to debug my code as I can't get print statements to work

I've been working on Project 1 from CS50W for a few days now and finally got my search bar to appear on my page! The issue I have now is I don't think the input is being pulled in from my form. I've ...
0
votes
0answers
202 views

CS50 Web 2020, Project 1 - Wiki, CSS not working

I'm currently using Django as explained in cs50w 2020 lecture 3. Under the static folder inside encyclopedia directory is the styles.css. This was in the distro code and there is already some styles ...
0
votes
0answers
764 views

raise JSONDecodeError(“Expecting value”, s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

@app.route('/api/<string:isbn>', methods = ['GET']) def isbn(isbn): #import api from Goodreads (stats) book_data = db.execute("SELECT * FROM books WHERE isbn=:isbn",{'isbn':isbn})....
0
votes
0answers
31 views

Placing django_markdown2 somewhere in my PYTHONPATH

I am going over the documentation for using django-markdown2 in Project1, and I don't know what is the best way to: 'Place django_markdown2 somewhere in your PYTHONPATH.' https://github.com/...
0
votes
1answer
18 views

.fetchone() is returning extra characters

I made a search system for project 1 that returns the author, title, and year of publication of a book when you give the ISBN. However, my code is returning extra characters. If I input the ISBN ...
0
votes
0answers
27 views

ERROR DATABASE_URL PROJECT1

I am almost new in this course. I am doing right know de project1 and I have a problem. When I start to configure my Heroku DB I appears this error. Can anyone help me please? What I am doing wrong? ...
1
vote
0answers
31 views

cs50w Project 1: Web page running very slow

I just finished my book review page for project 1 and everything is working fine, but the site takes forever to load certain parts. When trying to log in or create a new account, or when trying to ...
0
votes
0answers
16 views

Failing to extract data from html selector

I am currently doing the project1 of the CS50 web programming course and having issues extracting data from an html selector into a flask route. I think its probably best if I just describe what I ...
0
votes
1answer
44 views

postgresql syntax error

So this is part of the import.py code in project1: db.execute("INSERT INTO books (isbn, title, author, year) VALUES (:isbn, :title, :author, :year)", {"isbn": isbn, "title": title,...
0
votes
0answers
24 views

CS50 Web Project 1: Is it necessary to use raw SQL queries?

This is not strictly a coding question, can we use the SQLAlchemy ORM for the Books project? I know it is forbidden to use as per the requirements, but I am unable to run my program using raw ...
0
votes
1answer
59 views

Problem in importing from csv file

I am currently trying to import the contents of the books.csv file into my PostgreSQL database on Adminer. Here's my code: import csv import os from sqlalchemy import create_engine from sqlalchemy....
0
votes
0answers
11 views

Can I use databases to take in signup information from the user?

Can I use database in my Project 1 website for the user signup and login, to store the user information? Or is it necessary to use sessions, as mentioned in the 'hints' section of the Project 1 ...
0
votes
1answer
19 views

adminer.cs50.net not accessible

I'm trying to access https://adminer.cs50.net/ but it's showing HTTP ERROR 503, Is the URL changed or If the server is down for maintenance, when will it be available
0
votes
0answers
164 views

CS50W Project1 TypeError: can't pickle _thread._local objects

My register app @app.route("/register", methods=["POST","GET"]) def signup(): #function to create new users #checking request method if request.method == 'GET': return ...
0
votes
1answer
49 views

goodreads api request return code 404

I have tested my function separately in python and it worked: def get_goodreads_review(isbn): return requests.get(GOOD_READ_URL, params={"key":KEY, "isbns": isbn}) if I set isbn = "...
0
votes
1answer
45 views

How to keep track of current user and book in project 1

I am now doing CS50W project 1. After letting user login and having enabled the user to do the book search, I need a way to keep track of the user when he or she is browsing from one page to another. ...
0
votes
1answer
61 views

CS50W Project1: how to access specific part of json object

I am working on the part of the project where people can click on a book from the search results page, which will then take them to the specific book's page. I am getting this error: json.decoder....
0
votes
2answers
279 views

CS50W Project1: Type error cannot pickle _thread._local object

Currently working on CS50W's Project1, working with the GoodReads API. I thought the Register/Login/Logout requirements would be easy and quick for me to complete since I did it already with the CS50 ...
0
votes
1answer
53 views

Problem with commas in psql

So I have a problem with project1, specifically in import.py. In the csv provided with the books information, some of them have a comma inside the title, and this is causing the following error when I ...
0
votes
0answers
42 views

Textbook for understanding session in flask or in general web development?

Is there any good text book available which can explain the concept of session in web development ?
0
votes
2answers
421 views

CS50's Web Programming - Unable to import books.csv file into database

I'm on a project1, here is the link to it: https://docs.cs50.net/ocw/web/projects/1/project1.html I've successfully made a Table books using my Python script, however when I try to import the "books....
0
votes
3answers
475 views

adminer.cs50.net Not working

Guys there has been a problem in the website : "https://adminer.cs50.net" I tried to login multiple times and keeps giving me the error: "Session expired, please login again." could someone please ...
0
votes
1answer
118 views

Cs50 Web Programming - How to autocomplete - Project 1

I am doing project 1 and I have a problem. While doing the search page, I have show possible autocompleted texts to help the user with the search, but I don't know how to do that. I know it was shown ...
0
votes
1answer
132 views

What are the challenges when setting up your dev enviroment for Project 1 (MacOS)?

So it took me (several) hours yesterday to even have the boiler plate flask web application up on running for Project 1. Here I will be adding my notes on what went wrong and how I fixed it. In a ...
0
votes
1answer
2k views

Issue with psycopg2 dependency - pg_config executable not found on Mac OS

For Project 1: When running "pip3 install -r requirements.txt" for the initial setup, I get an issue with the psycopg2 dependency: Error: pg_config executable not found. pg_config is required to ...
1
vote
1answer
565 views

Having Issues Setting up Flask Server in Project 1

I am having trouble setting up my flask application in Project 1. Here is some additional screenshots of the error messages I get in browser when running flask. Here is some additional info: Running ...