AOSSIE-Org / AOSSIE-Org/EduAid

🐞 Bug: Issues in script.sh (Cloning, Dependency Installation, Flask Execution & S2V Extraction Path)

Aperta
#186 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
JavaScript
Stelle
171
Fork
425
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

### 🔍 Issue Description
The `script.sh` file does not function as described in the README. There are multiple discrepancies that prevent the proper execution of the script:

- **Unnecessary Cloning**: The script clones the repository even if it already exists locally.
- **Missing Dependency Installation**: The README mentions that dependencies will be installed when running `script.sh`, but there is no command for installing dependencies (e.g., `pip install -r requirements.txt`) in the script.
- **Flask App Not Starting**: The script fails to start the Flask server, as indicated in the README instructions.
- **Incorrect Sense2Vec (S2V) Model Extraction Path**: The script extracts the model to an incorrect directory, which prevents the server from loading it properly.

### 🚀 Steps to Reproduce
1. **Clone the repository**:
```bash
git clone https://github.com/AOSSIE-Org/EduAid.git
cd EduAid
```
2. **Run the `script.sh` script**:
```bash
./script.sh
```
3. **Expected Behavior (according to README)**:
- The script should install dependencies.
- The model should be extracted in the correct directory.
- The Flask server should be started.

4. **Actual Behavior**:
- The repository is cloned again, even if it already exists.
- Dependencies are not installed.
- The Flask server does not start.
- The model is extracted incorrectly, causing errors in `server.py`.

### 🎯 Expected Behavior
- If the repository is already cloned, the script should **skip cloning** and move to the next step.
- The script should **install dependencies** by running `pip install -r requirements.txt`.
- The S2V model should be extracted to the `backend/Generator/s2v_old` folder.
- The script should **start the Flask server** by running `python backend/server.py`.

### 🛠 Suggested Fixes
- **Cloning Issue**: Add a check to skip cloning if the repository already exists.
- **Missing Dependency Installation**: Add the `pip install -r requirements.txt` command after activating the virtual environment.
- **Flask Execution**: Add the command `python backend/server.py` to start the Flask app.
- **S2V Model Extraction Path**: Extract the model in the `backend/Generator/s2v_old` folder to match the expected location in `server.py`.

### ✅ Final Expected Outcome
- **Skip cloning** if the repository already exists.
- **Install dependencies** automatically.
- **Correctly extract the S2V model** into the proper directory.
- **Start the Flask server** automatically.

### 📝 Additional Context
These issues prevent smooth execution of `script.sh` as described in the README. Resolving these problems will help users easily set up the project without manual intervention.

### ****script.sh****

![Image](https://github.com/user-attachments/assets/481a1199-4214-4610-b25d-27f9e2efc7db)

****README.md****
![Image](https://github.com/user-attachments/assets/9e14364a-208f-4b89-b310-2266e6a95369)

Kindly assign this issue to me . I would be happy to resolve it!
@Aditya062003

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.