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

Installation of CouchDB via pastaELN Wizard not possible #182

Closed
moritzva opened this issue Jan 5, 2024 · 2 comments
Closed

Installation of CouchDB via pastaELN Wizard not possible #182

moritzva opened this issue Jan 5, 2024 · 2 comments

Comments

@moritzva
Copy link

moritzva commented Jan 5, 2024

The installation of CouchDB via the pastaELN Wizard was not possible.

Trying to open pastaELN via python -m pasta_eln.gui resulted in:

**ERROR dit01: Could not connect with username+password to local server

Therefore, CouchDB installer was downloaded manually from the Website (apache-couchdb-3.3.3.msi).
During the installation of this file, username (admin) and password were set. Then, these steps were followed:

(venv-pastaELN) (base) python -m pasta_eln.gui

**ERROR Configuration file does not exist or version is not 2

(venv-pastaELN) (base) python -m pasta_eln.installationTools install

---- Create PASTA-ELN installation ----

Enter user name:
Enter password:

(venv-pastaELN) (base) python -m pasta_eln.installationTools install

No errors

(venv-pastaELN) (base) python -m pasta_eln.gui

Installation successful, access to CouchDB is possible.

Setup

  • OS: Windows 10
  • python 3.11.5 packaged by Anaconda
  • PASTA ELN Version: 2.1.4
@SteffenBrinckmann
Copy link
Contributor

@moritzva Thank you for sending this first issue!

@SteffenBrinckmann
Copy link
Contributor

SteffenBrinckmann commented Jan 9, 2024

Stash of information that was in the readme.md file but does not belong there anymore

How to create a new version

  1. Lint
  2. Type checking: ignore extractors to keep them simple, some mistake might still remain
  3. test documentation building. The documentation can be viewed with "firefox docs/build/html/index.html"
  4. run test
  5. ensure extractors updated
  6. do normal commit
  7. create a new version:
pylint pasta_eln
mypy pasta_eln/*.py
make -C docs html
pytest -s Tests
diff -q ../Extractors/ pasta_eln/Extractors/ |grep differ

git commit -a -m 'linting and testing'

./commit.py "Minimal viable product" 1

THIS STEP IS NECESSARY FOR ALL GITHUB-Actions TO WORK

Create git-commit-hook

To automatically run many tests, create a file '.git/hooks/pre-commit' and make it executable

#!/bin/sh
#
# Test if extractors updated
if [ "$(diff -q ../Extractors/ pasta_eln/Extractors/ |grep differ |grep extractor)" ]; then
  echo "Differences in EXTRACTOR EXIST"
  exit 1
else
  echo "All is correct: extractors match"
fi
# Run pylint
exec pylint pasta_eln
# Run mypy
exec mypy pasta_eln/*.py
# Test document creation
exec make -C docs html
# Run pytest
exec pytest -s tests
#
echo 'Pre-commit-tests are finished'

HOW TO DIFF Version-1 and Version-2

COMPARE BOTH DIRECTIONS
at .. pasta-eln$ and remember the changes required to Version2 in first change. If nothing to remember, do not execute 2nd command

kdiff pasta_eln/miscTools.py ../Python/miscTools.py
kdiff ../Python/miscTools.py pasta_eln/miscTools.py
kdiff pasta_eln/inputOutput.py ../Python/inputOutput.py
kdiff ../Python/inputOutput.py pasta_eln/inputOutput.py
kdiff pasta_eln/database.py ../Python/database.py
kdiff ../Python/database.py pasta_eln/database.py
kdiff pasta_eln/backend.py ../Python/backend.py
kdiff ../Python/backend.py pasta_eln/backend.py

Desired Differences:

  • miscTools:
    • Version1 has colors at the beginning and few additional functions at the end
  • inputOutput:
    • NO differences
  • database:
    • imports are different
    • init arguments are different
    • Version1 has testUser
    • colorDefinition is small-case in one and upper-case in the other
  • backend:
    • imports and base-class different

Differences don't matter:

  • subdirectories
  • init.py

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