[](https://coveralls.io/r/pads/tiddlywebplugins.mapuser)
[](https://crate.io/packages/tiddlywebplugins.mapuser/)
About
=====
Allows TiddlyWeb users to create alias usernames, deliberately without validation.
This is ideal in a scenario where you control the user authentication journey but want to use different usernames
than those expected by the user authentication source.
Any username string can be used as long as it contains valid alphanumeric characters and no spaces.
Essentially, what is being mapped is user ID -> username.
Upon a successful POST, the plugin creates a tiddler in a bag called MAPUSER.
This data is used when a user logs in so that they can be mapped to their username.
Requirements
============
* [Python](http://www.python.org/).
* [pip](http://www.pip-installer.org/en/latest/).
* make.
* A working TiddlyWeb instance to test against.
* [py.test](http://pytest.org/latest/) to run the tests.
Modifying
=========
The best way to figure out how to work with this project is to look at the `.travis.yml` file.
`setup.py` is used to package up the plugin, install and distribute.
Plugin code lives in the `tiddlywebplugins` directory.
Tests live in the `test` directory.
* `make install` installs the plugin as a package on your system
* `make install_dev` installs packages necessary to run tests, check style and provide test coverage
* `make test` runs the tests.
* `make test_with_coverage` runs the tests with code coverage reporting from `pytest-cov`
* `make pep8` runs pep8 over the code to check for style compliance.
(you may need sudo for this.)
* `make release` packages and uploads the plugin to [PyPI](http://pypi.python.org/pypi) for distribution.
Plugin Installation
===================
Install tiddlywebplugins.mapuser:
pip install -U tiddlywebplugins.mapuser
TiddlyWeb Configuration
=======================
Reference the plugin from your TiddlyWeb configuration as a system plugin e.g:
`'system_plugins': ['tiddlywebplugins.mapuser']`
Usage
=====
The URL to send POSTs to will be:
map_user/<userid>
Where `<userid>` is the same as the one used to authenticate. The body will contain the mapped username:
mapped_user: <username>
Metadata
Release files for tiddlywebplugins.mapuser 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| tiddlywebplugins.mapuser-0.1.0.tar.gz | 4.2 kB | Without provenance | Details for tiddlywebplugins.mapuser-0.1.0.tar.gz |
Release files / tiddlywebplugins.mapuser-0.1.0.tar.gz
| Download URL | tiddlywebplugins.mapuser-0.1.0.tar.gz |
|---|---|
| Size | 4.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6ddad0aad7c245add6cfb6e90296615dae2cc075f94944500a2920ce257c06b5
|
|
BLAKE2b-256 checksum How to use checksums |
0563031cbfc3f93c9a929588bb624950510e7ebebbc049bb3d4680e7d31e915a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for tiddlywebplugins.mapuser 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.