Forums

Django-wiki on python anywhere

Has anyone attempted to install django-wiki here?

I should add, I'm currently have a django project running and I'm interested in adding a personal wiki for my own use to this.

Due to bugs in the most recent release, the recommended method to get all dependencies and wiki module is: pip install git+https://github.com/django-wiki/django-wiki.git

when I run pip3 install git+https://github.com/django-wiki/django-wiki.git (Note pip3) because PA is on python 3.7, I get:

Exception: Traceback (most recent call last): File "/usr/lib/python3.7/site-packages/pip/_internal/basecommand.py", line 141, in main status = self.run(options, args) File "/usr/lib/python3.7/site-packages/pip/_internal/commands/install.py", line 299, in run resolver.resolve(requirement_set) File "/usr/lib/python3.7/site-packages/pip/_internal/resolve.py", line 102, in resolve self._resolve_one(requirement_set, req) File "/usr/lib/python3.7/site-packages/pip/_internal/resolve.py", line 256, in _resolve_one abstract_dist = self._get_abstract_dist_for(req_to_install) File "/usr/lib/python3.7/site-packages/pip/_internal/resolve.py", line 209, in _get_abstract_dist_for self.require_hashes File "/usr/lib/python3.7/site-packages/pip/_internal/operations/prepare.py", line 298, in prepare_linked_requirement abstract_dist.prep_for_dist(finder, self.build_isolation) File "/usr/lib/python3.7/site-packages/pip/_internal/operations/prepare.py", line 98, in prep_for_dist build_requirements = self.req.get_pep_518_info() File "/usr/lib/python3.7/site-packages/pip/_internal/req/req_install.py", line 577, in get_pep_518_info pp_toml = pytoml.load(f) File "/usr/lib/python3.7/site-packages/pip/_vendor/pytoml/parser.py", line 10, in load return loads(fin.read(), translate=translate, object_pairs_hook=object_pairs_hook, filename=getattr(fin, 'name', repr(fin))) File "/usr/lib/python3.7/site-packages/pip/_vendor/pytoml/parser.py", line 23, in loads ast = _p_toml(src, object_pairs_hook=object_pairs_hook) File "/usr/lib/python3.7/site-packages/pip/_vendor/pytoml/parser.py", line 352, in _p_toml s.expect_eof() File "/usr/lib/python3.7/site-packages/pip/_vendor/pytoml/parser.py", line 124, in expect_eof return self._expect(self.consume_eof()) File "/usr/lib/python3.7/site-packages/pip/_vendor/pytoml/parser.py", line 164, in _expect raise TomlError('msg', self._pos[0], self._pos[1], self._filename) pip._vendor.pytoml.core.TomlError: /tmp/pip-req-build-vgp0p1no/pyproject.toml(125, 1): msg Any thoughts on why are welcome!

@umairny I saw you have something which looks like django-wiki working. Any thoughts on the above?

OK... answering my own question a little here.

Upgrated from Earl Grey to Haggis, changed python default versions to python3.10

Now pip3 install git+https://github.com/django-wiki/django-wiki.git works.

The needed modules are still not being found by my project, so now creating a new virtualenv to try pip installing again. Out of processing time though!

OK... so it's now working, and here's how it worked.

In a custom virtualvenv (python3.10) I pip installed from github again as above, and configured site to run in this custom virtualenv.

Glad you figured that out!

thanks to @justajolt 's youtube video, i've got a django project live on pythonanywhere with django-wiki installed as an app on it (alongside the main app/s). The only problem i've found, so far, is the media files are not being served (worked fine on my desktop setup). Has anyone else experienced problems with this?

Sorry to state the obvious but the paths to your static files directory will be different on PythonAnywhere, could it be that?

thanks for the reply @sboyd but sadly you're not necessarily stating the obvious to me. I'm 99% sure that the problem is between my chair and the computer, but having tried various path mapping options, and not found a solution, I was hoping that someone better at this jive than me had a magic (easy) answer. I'll continue trying to puzzle it out over the next few days. If anyone reading this can offer any guidance/direction, that'd be most welcome. Thanks.

We have a help page to help you to debug issues with static files here: https://help.pythonanywhere.com/pages/DebuggingStaticFiles/

@glenn sorted, thanks