reprohack / reprohack_site

Reprohack django site
https://reprohack.org/
MIT License
11 stars 11 forks source link

update gulp-sass, deps and associated code/css #235

Closed ubdbra001 closed 1 month ago

ubdbra001 commented 1 month ago

I spent some time looking into this and it looks like gulp-sass and it dependencies (specifically node-sass, which is deprecated) were causing most of the issues I was experiencing with using a newer version of nodejs.

This commit bumps the gulp-sass version, adds dart-sass (sass), and sets this to the default processor for SASS in gulpfile.js. It also complained about how some of the CSS files were structured, so I updated them too.

So, now I can get a local version of the site up and running without specifying that an older version of nodejs needs to be installed. Hopefully, it will work the same on your Mac 🤞

annakrystalli commented 1 month ago

Sadly this isn't working for me. Still getting stuck on:

conda install -c conda-forge nodejs=14

which is returning:

Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Collecting package metadata (repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.

PackagesNotFoundError: The following packages are not available from current channels:

  - nodejs=14

Current channels:

  - https://conda.anaconda.org/conda-forge/osx-arm64
  - https://conda.anaconda.org/conda-forge/noarch
  - https://conda.anaconda.org/bioconda/osx-arm64
  - https://conda.anaconda.org/bioconda/noarch
  - https://repo.anaconda.com/pkgs/main/osx-arm64
  - https://repo.anaconda.com/pkgs/main/noarch
  - https://repo.anaconda.com/pkgs/r/osx-arm64
  - https://repo.anaconda.com/pkgs/r/noarch

Doing a bit of research, it seems to be a platform issue https://github.com/conda/conda/issues/13659. The issue with the advise mentioned using --platform option when creating the environment which doesn't even exist! 🤷‍♀️

Digging some more and following advice from https://stackoverflow.com/questions/65415996/how-to-specify-the-architecture-or-platform-for-a-new-conda-environment-apple

I used:

CONDA_SUBDIR=osx-arm64 conda create -n reprohack python=3.8 -c conda-forge --override-channels

conda config --env --set subdir osx-arm64

To create an osx-arm64 environment.

Got same problem:

PackagesNotFoundError: The following packages are not available from current channels:

  - nodejs=14

Current channels:

  - https://conda.anaconda.org/conda-forge/osx-arm64
  - https://conda.anaconda.org/conda-forge/noarch
  - https://conda.anaconda.org/bioconda/osx-arm64
  - https://conda.anaconda.org/bioconda/noarch
  - https://repo.anaconda.com/pkgs/main/osx-arm64
  - https://repo.anaconda.com/pkgs/main/noarch
  - https://repo.anaconda.com/pkgs/r/osx-arm64
  - https://repo.anaconda.com/pkgs/r/noarch

To search for alternate channels that may provide the conda package you're
looking for, navigate to

    https://anaconda.org

and use the search bar at the top of the page.

In the end, I changed to

conda install conda-forge::nodejs

and managed to get it all working