github-actions[bot] b9c250ff19
build(deps-dev): bump black from 23.10.1 to 23.11.0 (#345)
Bumps [black](https://github.com/psf/black) from 23.10.1 to 23.11.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/psf/black/releases">black's
releases</a>.</em></p>
<blockquote>
<h2>23.11.0</h2>
<h3>Highlights</h3>
<ul>
<li>Support formatting ranges of lines with the new
<code>--line-ranges</code> command-line option
(<a
href="https://redirect.github.com/psf/black/issues/4020">#4020</a>)</li>
</ul>
<h3>Stable style</h3>
<ul>
<li>Fix crash on formatting bytes strings that look like docstrings (<a
href="https://redirect.github.com/psf/black/issues/4003">#4003</a>)</li>
<li>Fix crash when whitespace followed a backslash before newline in a
docstring (<a
href="https://redirect.github.com/psf/black/issues/4008">#4008</a>)</li>
<li>Fix standalone comments inside complex blocks crashing Black (<a
href="https://redirect.github.com/psf/black/issues/4016">#4016</a>)</li>
<li>Fix crash on formatting code like <code>await (a ** b)</code> (<a
href="https://redirect.github.com/psf/black/issues/3994">#3994</a>)</li>
<li>No longer treat leading f-strings as docstrings. This matches
Python's behaviour and
fixes a crash (<a
href="https://redirect.github.com/psf/black/issues/4019">#4019</a>)</li>
</ul>
<h3>Preview style</h3>
<ul>
<li>Multiline dicts and lists that are the sole argument to a function
are now
indented less (<a
href="https://redirect.github.com/psf/black/issues/3964">#3964</a>)</li>
<li>Multiline unpacked dicts and lists as the sole argument to a
function are now also
indented less (<a
href="https://redirect.github.com/psf/black/issues/3992">#3992</a>)</li>
<li>In f-string debug expressions, quote types that are visible in the
final string
are now preserved (<a
href="https://redirect.github.com/psf/black/issues/4005">#4005</a>)</li>
<li>Fix a bug where long <code>case</code> blocks were not split into
multiple lines. Also enable
general trailing comma rules on <code>case</code> blocks (<a
href="https://redirect.github.com/psf/black/issues/4024">#4024</a>)</li>
<li>Keep requiring two empty lines between module-level docstring and
first function or
class definition (<a
href="https://redirect.github.com/psf/black/issues/4028">#4028</a>)</li>
<li>Add support for single-line format skip with other comments on the
same line (<a
href="https://redirect.github.com/psf/black/issues/3959">#3959</a>)</li>
</ul>
<h3>Configuration</h3>
<ul>
<li>Consistently apply force exclusion logic before resolving symlinks
(<a
href="https://redirect.github.com/psf/black/issues/4015">#4015</a>)</li>
<li>Fix a bug in the matching of absolute path names in
<code>--include</code> (<a
href="https://redirect.github.com/psf/black/issues/3976">#3976</a>)</li>
</ul>
<h3>Performance</h3>
<ul>
<li>Fix mypyc builds on arm64 on macOS (<a
href="https://redirect.github.com/psf/black/issues/4017">#4017</a>)</li>
</ul>
<h3>Integrations</h3>
<ul>
<li>Black's pre-commit integration will now run only on git hooks
appropriate for a code
formatter (<a
href="https://redirect.github.com/psf/black/issues/3940">#3940</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/psf/black/blob/main/CHANGES.md">black's
changelog</a>.</em></p>
<blockquote>
<h2>23.11.0</h2>
<h3>Highlights</h3>
<ul>
<li>Support formatting ranges of lines with the new
<code>--line-ranges</code> command-line option
(<a
href="https://redirect.github.com/psf/black/issues/4020">#4020</a>)</li>
</ul>
<h3>Stable style</h3>
<ul>
<li>Fix crash on formatting bytes strings that look like docstrings (<a
href="https://redirect.github.com/psf/black/issues/4003">#4003</a>)</li>
<li>Fix crash when whitespace followed a backslash before newline in a
docstring (<a
href="https://redirect.github.com/psf/black/issues/4008">#4008</a>)</li>
<li>Fix standalone comments inside complex blocks crashing Black (<a
href="https://redirect.github.com/psf/black/issues/4016">#4016</a>)</li>
<li>Fix crash on formatting code like <code>await (a ** b)</code> (<a
href="https://redirect.github.com/psf/black/issues/3994">#3994</a>)</li>
<li>No longer treat leading f-strings as docstrings. This matches
Python's behaviour and
fixes a crash (<a
href="https://redirect.github.com/psf/black/issues/4019">#4019</a>)</li>
</ul>
<h3>Preview style</h3>
<ul>
<li>Multiline dicts and lists that are the sole argument to a function
are now indented
less (<a
href="https://redirect.github.com/psf/black/issues/3964">#3964</a>)</li>
<li>Multiline unpacked dicts and lists as the sole argument to a
function are now also
indented less (<a
href="https://redirect.github.com/psf/black/issues/3992">#3992</a>)</li>
<li>In f-string debug expressions, quote types that are visible in the
final string are
now preserved (<a
href="https://redirect.github.com/psf/black/issues/4005">#4005</a>)</li>
<li>Fix a bug where long <code>case</code> blocks were not split into
multiple lines. Also enable
general trailing comma rules on <code>case</code> blocks (<a
href="https://redirect.github.com/psf/black/issues/4024">#4024</a>)</li>
<li>Keep requiring two empty lines between module-level docstring and
first function or
class definition (<a
href="https://redirect.github.com/psf/black/issues/4028">#4028</a>)</li>
<li>Add support for single-line format skip with other comments on the
same line (<a
href="https://redirect.github.com/psf/black/issues/3959">#3959</a>)</li>
</ul>
<h3>Configuration</h3>
<ul>
<li>Consistently apply force exclusion logic before resolving symlinks
(<a
href="https://redirect.github.com/psf/black/issues/4015">#4015</a>)</li>
<li>Fix a bug in the matching of absolute path names in
<code>--include</code> (<a
href="https://redirect.github.com/psf/black/issues/3976">#3976</a>)</li>
</ul>
<h3>Performance</h3>
<ul>
<li>Fix mypyc builds on arm64 on macOS (<a
href="https://redirect.github.com/psf/black/issues/4017">#4017</a>)</li>
</ul>
<h3>Integrations</h3>
<ul>
<li>Black's pre-commit integration will now run only on git hooks
appropriate for a code
formatter (<a
href="https://redirect.github.com/psf/black/issues/3940">#3940</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="2a1c67e0b2"><code>2a1c67e</code></a>
Prepare release 23.11.0 (<a
href="https://redirect.github.com/psf/black/issues/4032">#4032</a>)</li>
<li><a
href="72e7a2e43e"><code>72e7a2e</code></a>
Remove redundant condition from <code>has_magic_trailing_comma</code>
(<a
href="https://redirect.github.com/psf/black/issues/4023">#4023</a>)</li>
<li><a
href="1a7d9c2f58"><code>1a7d9c2</code></a>
Preserve visible quote types for f-string debug expressions (<a
href="https://redirect.github.com/psf/black/issues/4005">#4005</a>)</li>
<li><a
href="f4c7be5445"><code>f4c7be5</code></a>
docs: fix minor typo (<a
href="https://redirect.github.com/psf/black/issues/4030">#4030</a>)</li>
<li><a
href="2e4fac9d87"><code>2e4fac9</code></a>
Apply force exclude logic before symlink resolution (<a
href="https://redirect.github.com/psf/black/issues/4015">#4015</a>)</li>
<li><a
href="66008fda5d"><code>66008fd</code></a>
[563] Fix standalone comments inside complex blocks crashing Black (<a
href="https://redirect.github.com/psf/black/issues/4016">#4016</a>)</li>
<li><a
href="50ed6221d9"><code>50ed622</code></a>
Fix long case blocks not split into multiple lines (<a
href="https://redirect.github.com/psf/black/issues/4024">#4024</a>)</li>
<li><a
href="46be1f8e54"><code>46be1f8</code></a>
Support formatting specified lines (<a
href="https://redirect.github.com/psf/black/issues/4020">#4020</a>)</li>
<li><a
href="ecbd9e8cf7"><code>ecbd9e8</code></a>
Fix crash with f-string docstrings (<a
href="https://redirect.github.com/psf/black/issues/4019">#4019</a>)</li>
<li><a
href="e808e61db8"><code>e808e61</code></a>
Preview: Keep requiring two empty lines between module-level docstring
and fi...</li>
<li>Additional commits viewable in <a
href="https://github.com/psf/black/compare/23.10.1...23.11.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=black&package-manager=pip&previous-version=23.10.1&new-version=23.11.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>
2023-11-08 23:08:16 +01:00
2023-10-21 10:58:54 +02:00
2023-10-20 16:36:54 +02:00

aki_prj23_transparenzregister

python Actions status Ruff pre-commit Checked with mypy Documentation Status Code style: black

Contributions

See the CONTRIBUTING.md about how code should be formatted and what kind of rules we set ourselves.

Available entrypoints

The project has currently the following entrypoint available:

  • data-transformation > Transfers all the data from the mongodb into the sql db to make it available as production data.
  • reset-sql > Resets all sql tables in the connected db.
  • copy-sql > Copys the content of a db to another db.
  • webserver > Starts the webserver showing the analysis results.

DB Connection settings

To connect to the SQL db see sql/connector.py To connect to the Mongo db see [connect]

Create a secrets.json in the root of this repo with the following structure (values to be replaces by desired config):

The sqlite db is alternative to the postgres section.

{
  "sqlite": "path-to-sqlite.db",
  "postgres": {               
    "username": "username",      
    "password": "password",
    "host": "localhost",
    "database": "db-name",
    "port": 5432
  },
  "mongo": {
    "username": "username",
    "password": "password",
    "host": "localhost",
    "database": "transparenzregister",
    "port": 27017
  }
}

Alternatively, the secrets can be provided as environment variables. One option to do so is to add a .env file with the following layout:

PYTHON_POSTGRES_USERNAME=postgres
PYTHON_POSTGRES_PASSWORD=postgres
PYTHON_POSTGRES_HOST=localhost
PYTHON_POSTGRES_DATABASE=postgres
PYTHON_POSTGRES_PORT=5432

PYTHON_MONGO_USERNAME=username
PYTHON_MONGO_HOST=localhost
PYTHON_MONGO_PASSWORD=password
PYTHON_MONGO_PORT=27017
PYTHON_MONGO_DATABASE=transparenzregister

PYTHON_SQLITE_PATH=PathToSQLite3.db # An overwrite path to an sqllite db

PYTHON_DASH_LOGIN_USERNAME=some-login-to-webgui
PYTHON_DASH_LOGIN_PW=some-pw-to-login-to-webgui

CR=ghcr.io/fhswf/aki_prj23_transparenzregister
TAG=latest

HTTP_PORT=80

The prefix PYTHON_ can be customized by setting a different prefix when constructing the ConfigProvider.

Description
No description provided
Readme 138 MiB
Languages
Jupyter Notebook 84.5%
HTML 12.1%
Python 3.3%