Bug 232379 - net-im/py-matrix-synapse package instructions mismatch with application
Summary: net-im/py-matrix-synapse package instructions mismatch with application
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Martin Wilke
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-10-18 12:27 UTC by Pete
Modified: 2018-12-04 15:57 UTC (History)
3 users (show)

See Also:
ports: maintainer-feedback+


Attachments
Patch 0.33.5.1 to 0.33.8 (3.34 KB, patch)
2018-11-07 14:00 UTC, CTS - FreeBSD Team
no flags Details | Diff
Upgrade net-im/py-matrix-synapse to 0.33.8 and update pkg messages and sample config (20.55 KB, patch)
2018-11-15 16:41 UTC, Sascha Biberhofer
ports: maintainer-approval+
Details | Diff
Upgrade py-matrix-synapse from 0.33.5.1 to 0.33.9 based on Sascha's patch for 0.33.8 (20.55 KB, patch)
2018-11-22 02:17 UTC, CTS - FreeBSD Team
de-freebsd: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Pete 2018-10-18 12:27:05 UTC
Post install messages does not match the current version. Report-stats should be "yes/no" instead of "true/false". Running the command advised from the package results in an error.

# pkg info -D py27-matrix-synapse-0.33.3.1
...
/usr/local/bin/python2.7 -B -m synapse.app.homeserver -c /usr/local/etc/matrix-synapse/homeserver.yaml --generate-config --server-name=example.com --report-stats=false
... 

See the help output from synapse below:

# /usr/local/bin/python2.7 -B -m synapse.app.homeserver --help
 usage: homeserver.py [-h] [-c CONFIG_FILE] [--generate-config]
                     [--report-stats {yes,no}] [--generate-keys]
                     [--keys-directory DIRECTORY] [-H SERVER_NAME] [-D]
                     [--print-pidfile] [--manhole PORT]
                     [-d SQLITE_DATABASE_PATH] [-v] [-f LOG_FILE]
                     [--log-config LOG_CONFIG] [-n] [--enable-registration]


While --server-name still works, it might be prudent to update to "-H" as shown above.
Comment 1 Sascha Biberhofer 2018-11-01 14:49:27 UTC
Hi,

Sorry for the delay, October has been a very busy month. I can confirm that this message is indeed outdated. There might also be more than just -H missing, as the --generate-keys option should probably be specified too if you want to generate all the necessary files. 

I'll revise this and test this to make it part of the 0.33.8 bump.
Comment 2 CTS - FreeBSD Team 2018-11-07 14:00:47 UTC
Created attachment 199054 [details]
Patch 0.33.5.1 to 0.33.8
Comment 3 CTS - FreeBSD Team 2018-11-07 14:03:24 UTC
I made a patch to 0.33.8 on my build server already, so i just incorporated this suggestion.

While i was there i added the devel/py-pyasn1-modules dependency and moved the sysutils/py-psutil dep to the mandatory deps (as this was done in the project's own dependency file also).

What i left out again was the update of the homeserver.yaml.in to a recent version. That's something for the winter holidays ;)
Comment 4 Sascha Biberhofer 2018-11-15 16:41:54 UTC
Created attachment 199258 [details]
Upgrade net-im/py-matrix-synapse to 0.33.8 and update pkg messages and sample config

Phew, this took me much longer than it probably should have. 

I've checked the necessity of the config parameters. We don't need --generate-keys for the example config. Changing the parameter to -H is sufficient and adjusting the --report-stats parameter to the newer syntax is fine too. 

I've also reviewed Markus' patch, which looks fine. I've adjusted the rest of the dependencies as well (in accordance w/ the python dependencies in the synapse repo) and updated the sample config we ship to reflect the latest config synapse generates. I'd also leave the --report-stats parameter to no, because I'm not quite sure what anonymous usage statistics entail and I'd hate to step on someone's privacy.

Patch is attached and works fine for me.
Comment 5 CTS - FreeBSD Team 2018-11-15 17:18:03 UTC
I just tested Sascha's patch - worked for me too.
Comment 6 CTS - FreeBSD Team 2018-11-22 02:17:29 UTC
Created attachment 199441 [details]
Upgrade py-matrix-synapse from 0.33.5.1 to 0.33.9 based on Sascha's patch for 0.33.8

While we wait for the commit, the project released 0.33.9. I added a patch to the current version based on Sascha's patch for 0.33.8. Basically i just changed the version and deleted the pydenticon dependency, as the project did in this release (compared to Sascha's patch for 0.33.8).
Comment 7 Sascha Biberhofer 2018-11-30 18:32:08 UTC
Got around to testing Markus' patch, which looks good and works perfectly fine. We should get this committed before yet another synapse release happens.
Comment 8 commit-hook freebsd_committer freebsd_triage 2018-12-04 15:57:45 UTC
A commit references this bug:

Author: miwi
Date: Tue Dec  4 15:56:57 UTC 2018
New revision: 486610
URL: https://svnweb.freebsd.org/changeset/ports/486610

Log:
  - Update to 0.33.9
  - Adjust pkg-message

  Changelog:
  	https://matrix.org/blog/2018/11/20/synapse-0-33-9-is-here/

  PR:		232379
  Submitted by:	maintainer
  Sponsored by:	iXsystems Inc.

Changes:
  head/net-im/py-matrix-synapse/Makefile
  head/net-im/py-matrix-synapse/distinfo
  head/net-im/py-matrix-synapse/files/homeserver.yaml.in
  head/net-im/py-matrix-synapse/files/pkg-message.in