Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Help - Stuck Installing v0.9.0 Again #2795

Open
DeepSeaCatz opened this issue Oct 28, 2024 · 3 comments
Open

Help - Stuck Installing v0.9.0 Again #2795

DeepSeaCatz opened this issue Oct 28, 2024 · 3 comments

Comments

@DeepSeaCatz
Copy link

I've been trying to get my team up to date with the latest of Adapt. We've been using Adapt for 6 years and our last update was to v0.9.0, using v2.4.0 framework.

We currently want to upgrade out adapt version to the latest, but during the process of doing so, I've messed up my nodes version, MongoDB version and potentially npm.

It's been 2 weeks that I keep trying to install version 0.9.0 properly, while trying to understand the correct versions required so I know for sure what to install on the other computers of my colleagues. I'm starting to get desperate. There are so many strict dependencies that I'm starting to go insane. Even ChatGPT and Claude.ai don't know and get me into a dependency loop.

This is my current way of installing so far :

  1. Use node version 10.16.1 (nvm use 10.16.1)
  2. Create new folder named adapt in C:\
  3. Open command prompt and write the following commands:
  1. Spam Enter to have the default choices
  2. Get stuck when linking it to the MongoDB:
    image

Currently, I understand that MongoDB requires to be at version 4. I've tried to use version 4.4, but there were issues connecting to the database when adapt was installed. Since the current oldest version of MSI possible to download is version 5.0.30, I had to go into the archives, which only have a Zip version:
Windows x64
Archive: mongodb-win32-x86_64-2008plus-ssl-4.0.28.zip

Claude.ai helped me set it up successfully, which I would have never been able to do without.

For the node versions, I've tried various versions, which all seem to have a different effect when doing npm install and node install:
image

I tried npm install with version 16, then going switching back to version 10 for node install, vice-verca, all of the version 1 install or mix. It seemed that installing with a version requires another dependency for it to work, so the current way the 0.9.0 is setup is not possible with all 1 version of 8-10 as recommended.

If I use node version 8.16.2 - 10.16.1 or **14.19.**0, I get this error:

C:\adapt\adapt_authoring>node install
C:\adapt\adapt_authoring\node_modules\winston-transport\node_modules\readable-stream\lib\ours\util.js:5
const AbortSignal = globalThis.AbortSignal || require('abort-controller').AbortSignal
                    ^

ReferenceError: globalThis is not defined
    at Object.<anonymous> (C:\adapt\adapt_authoring\node_modules\winston-transport\node_modules\readable-stream\lib\ours\util.js:5:21)
    at Module._compile (internal/modules/cjs/loader.js:778:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
    at Module.load (internal/modules/cjs/loader.js:653:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
    at Function.Module._load (internal/modules/cjs/loader.js:585:3)
    at Module.require (internal/modules/cjs/loader.js:692:17)
    at require (internal/modules/cjs/helpers.js:25:18)
    at Object.<anonymous> (C:\adapt\adapt_authoring\node_modules\winston-transport\node_modules\readable-stream\lib\stream.js:31:5)
    at Module._compile (internal/modules/cjs/loader.js:778:30)

If I use version node 12

(node:3888) [MONGODB DRIVER] Warning: Current Server Discovery and Monitoring engine is deprecated, and will be removed in a future version. To use the new Server Discover and Monitoring engine, pass option { useUnifiedTopology: true } to the MongoClient constructor.
error [28 Oct 24 15:52:17 -04:00] Failed to load content plugin of type: bower

If anyone out there could help me list the correct version to install Authoring Tool v0.9.0 and Framework v2.4.0, I would appreciate you a lot! The main goal is to have both v0.9.0 and the most up to date version installed at the same time to easily access both version at once on different ports. This way it will be easier to transfer all the content over for upgrade.

Thanks

@taylortom
Copy link
Member

taylortom commented Nov 6, 2024

As a side-note: I would highly advise against relying on any AI helpers for this kind of thing, you are likely to find yourself in more of a mess than if you read documentation etc. yourself.


Now, before advising on the install process: do you already have access to a working v0.9.0 install? If so, I would strongly suggest you do the following:

  • Export the existing courses
  • Perform any necessary steps to upgrade courses outside of an AAT
  • Import courses into a clean AAT

If you're unable to access to another AAT, it's advisable to start with a clean install of the current dependencies of the time:

  • Node.js v10.x
  • MongoDB v4.2.x
  • Grunt v1.0.4
  • A global bower install is not necessary as far as I'm aware

Once you're at this point, check that you're able to access your MongoDB server (this should be possible by running the mongo command) - if this doesn't work, you'll need to figure out what's gone wrong with your MongoDB install before proceeding.

@DeepSeaCatz
Copy link
Author

DeepSeaCatz commented Nov 22, 2024

Sorry for the late reply. Thank you for the specific dependencies required! I have forgotten about Grunt version 1.0.4. I have been trying to resolve this on the side of my accumulated projects.

I've finally been successful in running mongo command. This wouldn't work even after adding the bin path to the environment variable, but this command resolved it: setx /m PATH "C:\Program Files\MongoDB\Server\4.2\bin;%PATH%"

I also discovered that I had to delete all 3 grunt files under AppData\Roaming\npm to install a new grunt version. I was wondering why I couldn't go foreword.

Right now it seems I am stuck with an error from MongoDB in the node modules in the node install process:

image

From what I see online is that I am not able to make connection with MongoDB and require some kind of authentification? I verified that I have MongoDB running as a background Service.

I tried creating an admin account and a user account in MongoDB Compass and alternatively using cmd to create them, but it seems to have created more issues, so I've removed it. I am using the version 4.2.25 and npm is at version 6.14.16 (I'm not sure if should use an older or newer version). From what I remember, the username and password are only after the initial steps of node install, which is where I am getting the errors.

I didn't expected to have had this amount of issues. I'm a front-end Web developer, so working the in the back-end is a very different way of problem solving. Thanks for the help!

@taylortom
Copy link
Member

taylortom commented Dec 12, 2024

Hi @DeepSeaCatz,

Yes, it seems that the either database requires auth and it hasn't been provided during install, or possibly that auth details have been provided during install but don't exist on the DB side.

I'm not sure how you specify DB auth using compass (from what I can see there isn't a way) - if you do have auth users set up, they should be in the admin database:

image


One thing you can try is to skip the database server and port values, and use the database connection URI instead, which would be mongodb://localhost:27017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants