grandma-collaboration / skyportal_grandma_dev

Little Git Repo to keep track of the work done by the A4 ESILV TEAM
2 stars 0 forks source link

Makarison Jolyane - Adding new features #17

Closed jolyanem closed 1 year ago

jolyanem commented 1 year ago

Hi ! 😄 I am currently working on the tutorial and as it is a quite bit long, for the moment I am focus on the tutorial ReactJS . I also started to search a little bit on the code where I would modify the code for the task 1 given by Sarah ! I wouldn't hesitate ask for help if I feel lost sometimes,

Thank you for your help ! 🚀

Theodlz commented 1 year ago

Hi @jolyanem, any updates using the updated tutorial?

jolyanem commented 1 year ago

Hi @Theodlz ! 👋 I did the tutorial and I've got an error when I make run and make log. Here is my error :

image

I suppose the error is on the file config.yaml I had to modify..

jolyanem commented 1 year ago

Hi @Theodlz ! I don't have the same issue anymore. Now, when I make run, my browser displays "Skyportal is being provisioned" but when I make log, here are my errors :

image

What I don't understand is that, I didn't modify models.py but the error said that it cannot import name from this file.

Waiting for your help but trying to figure it out ! thanks ! 🚀

Theodlz commented 1 year ago

Hi @jolyanem .

This error says that in init.py you imported thr TestComment class that you added as test_comment.py when you did the tutorial, but it cant find it.

jolyanem commented 1 year ago

Thank you for your answer @Theodlz,

So I should check the test_comment.py I created in models and the __init__.py associated to it ?

Theodlz commented 1 year ago

My apologize, I didnt read the error right. The error is in test_comment.py. It cant import user_or_token from Baselayer models. That might be an incorrect import from the new version of the tutorial I wrote. Please check that import (verify where it is in baselayer) and correct it accordingly.

jolyanem commented 1 year ago

In my test_comment.py; I wrote : 'from baselayer.app.models import Base, user_or_token'. Does it mean I have to import Baselayer ? @Theodlz

Theodlz commented 1 year ago

Baselayer is in skyportal already.

What I mean is that maybe user_or_token is imported from the wrong file in baselayer. So try to figure out what would be the correct import if the one you used is incorrect.

Imports are really import, unless you can figure out where what you need is, you wont be able to import it correctly in any of your projects.

Theodlz commented 1 year ago

Also, please check with those who already managed to finish the tutorial. If they commited their code on a branch on git (which they should ALWAYS do), you can easily compare your code with theirs.