Hi everyone! I have taken over a project which was being developed using devstack and I am now using tutor dev instead and trying to port the existing project to tutor because devstack is causing a lot of problems and is deprecated. Unfortunately, the old developers have all left the project with insufficient documentation and I am getting a little confused trying to connect the bits and pieces together. I have successfully set up tutor in my local environment and I am looking to setting up Xblocks on it.
I have the code for multiple Xblocks on my machine locally. According to the old documentation, I have been asked to install them using pip install -e /path/to/xblock. But this documentation is for devstack and not tutor. When I run pip install -e /path/to/xblock, the code executes successfully. After this, when I start the server using tutor dev start, I see no changes on the platform.
Is the process to set up and install Xblocks the same in tutor dev as devstack? Or am I missing something? Any help or guidance pointing me to the right resources would be highly appreciated!
Hi @sarina the old documentation I have been talking about is the one left internally to me by the old developers for my project. Those steps are specifically for devstack and not tutor so I am a little clueless.
I have been been trying to refer to the documentation left by the developers to me and the tutor documenation online so that I can successfully update all of the existing code from devstack to tutor.
I am stuck on the step where I need to set up and install Xblocks in tutor. I have been looking at the tutor documentation to find out how to install Xblocks but I have not been finding any resources which are pointing me towards it. Any help or guidance on where I should look for this would be greatly appreciated!
Thanks for your response @harout7 ! I really appreciate it.
When following your steps, I tried to check the path .local/share/tutor/env/build/openedx/requirements on my machine but I cannot see anything inside the share directory. I am just going to proceed with your steps from step 2 onwards and clone the xblocks in some other directory.
Do you think that is going to cause any problems in my set up?
Also, since I cannot see the path you mentioned in step 1 by default, is there anything you think I might have done incorrectly in my set up of tutor dev?
@harout7@tanmaypardeshi if these instructions are indeed missing from Tutor documentation I encourage you to add some documentation. If that’s not possible at minimum file an issue Sign in to GitHub · GitHub and link to this thread.
Hi @sarina, once I am completely done with the set up of XBlocks, I will definitely go and add some more documentation(or file an issue) wherever I think it would be more easier to follow for someone who is completely new to OpenEdX like me. Thank you so much for your support!
Thank you for all your help and support @harout7 . I really appreciate it. I had gone through the web pages you have shared but I could not completely grasp on how to go about doing my tasks after reading them. I am a complete beginner to OpenEdX and maybe that is the reason why following the current documentation got a little difficult for me. Thank you so much for your help once again!
@harout7 , if the requirements directory does not exist by defaullt under my <project-root>/env/build/openedx , can I just create a directory myself or is there anything wrong I am doing in my set up?
Hi @medamine . The problem is that the documentation does not exactly mention this anywhere but the release notes do. If you go to the release notes link and check the notes for v17.0.0 (Quince), you will see that using private.txt and requirements folder is no longer supported and you have to use tutor mounts add ... instead.
However, all the other posts including the answer in this thread above which are related to this issue ask you to use private.txt and the requirements folder. This is the reason for the confusion.
Basically you have two options now:
Use some version below v17.0.0 (Quince) and you can create a private.txt file and use the requirements and follow the answer mentioned above. I tried it for v.16.1.8 (Palm) and it worked just fine for me.
(Recommended) For any version from v17.0.0 and above, install your xblock in editable mode using command pip install -e <xblock-name> and then mount the xblock on tutor using 'tutor mounts add . When you rebuild your image using tutor images build ..., you should see that your xblock is being detected during the build process.