Skip to content

Local setup: cchardet error #49

Description

@MaaJoo13

For Windows users, an error might appear when installing oemof-tabular:

"ERROR: Could not build wheels for cchardet, which is required to install pyproject.toml-based projects"

Guidelines on how to fix this error: twintproject/twint#1407 (comment)

If these guidelines do not fix it, try this work-around:

  1. Clone the oemof-tabular-plugins repository to your local machine: https://github.com/rl-institut/oemof-tabular-plugins and checkout fix/refactor_dash
  2. Find the file pyproject.toml and change these lines:
[build-system]
requires = ["setuptools", "oemof.tabular", "numpy==1.26.0", "dash", "Werkzeug==2.2.2", "oemof-industry"]
build-backend = "setuptools.build_meta"

[project]
name = "oemof-tabular-plugins"
authors = [
  { name="Ciara Dunks", email="ciara.dunks@rl-institut.de" },
  { name="Pierre-François Duc", email="pierre-francois.duc@rl-institut.de" },
]
description = "A package that contains various constraint facades to be used with oemof-tabular"
requires-python = ">=3.9"
classifiers = [
    "Programming Language :: Python :: 3",
    "License :: OSI Approved :: MIT License",
    "Operating System :: OS Independent",
]
dynamic = ["version", "dependencies", "readme"]

to

[build-system]
requires = ["setuptools>=61"]
build-backend = "setuptools.build_meta"

[project]
name = "oemof-tabular-plugins"
authors = [
  { name="Ciara Dunks", email="ciara.dunks@rl-institut.de" },
  { name="Pierre-François Duc", email="pierre-francois.duc@rl-institut.de" },
]
description = "A package that contains various constraint facades to be used with oemof-tabular"
requires-python = ">=3.9"
classifiers = [
    "Programming Language :: Python :: 3",
    "License :: OSI Approved :: MIT License",
    "Operating System :: OS Independent",
]
version = "0.1.0"
dynamic = ["dependencies", "readme"]
  1. With your virtual environment for WEFEgui activated, go to the oemof-tabular-plugins repository and install editable: pip install -e .

  2. Open WEFEgui/app/requirements/postgres.txt and delete/comment the line oemof_tabular_plugins @ git+https://github.com/rl-institut/oemof-tabular-plugins.git@fix/refactor_dash

  3. Re-run pip install -r requirements/postgres.txt

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions