Ivan Nedzveckij and Umputun
c3b39b41ae
telegram notifications format headers, resolve #1202
2022-01-12 11:40:00 -06:00
Dmitry Verkhoturov and Umputun
151913f371
style fixes to the documentation and CLI params description
2021-12-20 13:36:58 -06:00
Dmitry Verkhoturov and Umputun
e341e25f0f
improve notifications documentation (telegram, webhook)
2021-12-20 02:56:38 -06:00
Dmitry Verkhoturov and Umputun
4f672cdec5
fix formatting for telegram reply notifications
2021-12-20 00:07:15 -06:00
Dmitry Verkhoturov and Umputun
11c8bf6228
do not issue deprecation warning on notify.type by default
...
Default configuration for notify.type is "none",
and prior to this change it was issuing the
deprecation warning which was not an intended
behaviour.
2021-12-19 23:32:48 -06:00
Dmitry Verkhoturov and Umputun
f43dfd57e0
clarify telegram channel ID param and documentation
2021-12-19 13:56:16 -06:00
Dmitry Verkhoturov and Umputun
90e537358d
update golangci-lint to 1.43.0, fix found issues
2021-11-23 15:00:40 -06:00
witjem and Umputun
473e3328e1
updated comment for rest.SendErrorJSON
2021-11-12 03:32:14 -06:00
Dmitry Verkhoturov and Umputun
be3643ed10
use single loop for telegram auth and notify
2021-11-09 02:04:51 -06:00
Dmitry Verkhoturov and Umputun
c027dcd765
enable telegram notify trough writing bot a message
...
Previously it was done through writing bot first,
clicking a button, copying the token, and pasting
it into the web interface.
The new flow is way simpler: click the link
to write bot a message, then click the "Check"
button in the web UI and you got notifications
enabled.
2021-11-07 11:51:28 -06:00
Dmitry Verkhoturov and Umputun
e1a2374a2d
clarify telegram notification flow
2021-11-04 15:42:04 -05:00
Dmitry Verkhoturov and Umputun
6449b7d92b
improve telegram notifications
...
These changes are designed to ease the transition into
the simplified telegram notifications verification model.
2021-11-01 14:35:37 -05:00
Dmitry Verkhoturov and Umputun
8fc9141f19
extract TelegramBotInfo structure
2021-10-25 16:47:15 -05:00
Dmitry Verkhoturov and Umputun
ca7cbedea4
regenerate mocks and use require.NoError in place of Nil
2021-10-25 16:47:15 -05:00
Dmitry Verkhoturov and Umputun
498073c509
send telegram messages in HTML mode
...
That resolves problem with inability
to properly render message text in the
resulting telegram message due to markdown
escaping trickiness.
2021-10-24 14:05:06 -05:00
Dmitry Verkhoturov and Umputun
f817fd38ed
improve telegram messages escaping
...
Due to the wrong order of `html.UnescapeString`
applying, messages sometimes ended up crippled.
Due to `parse_mode=Markdown` set in Telegram
send message call, `ParseMode` in message
was ignored.
2021-10-24 14:05:06 -05:00
Dmitry Verkhoturov and Umputun
4793a31075
move previewCommentCtrl to private REST struct
2021-10-16 11:04:03 -05:00
romanilchyshyn
df0d4d27fa
patreon auth
2021-10-13 00:30:14 +03:00
romanilchyshyn and Umputun
e341227cae
import from commento engine
2021-10-06 13:51:31 -05:00
Dmitry Verkhoturov and Umputun
5abeab4008
stop Ticker after use to prevent the memory leak
...
https://github.com/golang/go/wiki/CodeReviewConcurrency#ticker-stop
2021-10-03 16:09:30 -06:00
Dmitry Verkhoturov and Umputun
3f0ede560c
bump go modules in the project
2021-09-08 11:34:48 -05:00
Dmitry Verkhoturov and Umputun
2443b9d0a2
prevent data race within TestService_UserReplies
2021-09-04 15:22:02 -05:00
Dmitry Verkhoturov and Umputun
fa6c0e0d5e
don't use "t" inside assert.Eventually
2021-09-04 13:00:25 -05:00
Dmitry Verkhoturov and Umputun
bb3c86281c
make TestService_UserReplies more robust
...
It flaps (see #380 ), and with this change, it will
have more time to get the expected output in
the flaky GitHub Actions environment.
2021-09-04 12:44:42 -05:00
Umputun
91441d1160
add controversy and imported to untrusted list
2021-09-01 14:21:52 -05:00
Umputun
72bdf1b176
fix quoting issue
2021-09-01 14:18:18 -05:00
Umputun
e90dae2b94
sanitize Title on find level as well
2021-09-01 14:14:12 -05:00
Umputun
a7b44eee1a
sanitize PostTitle
2021-09-01 13:56:06 -05:00
Umputun
8754add874
add skip to user's comment rest request #1085
2021-08-29 12:45:35 -05:00
bakurin and Umputun
be46e849a4
Webhook destination for notifications
2021-08-28 12:50:36 -05:00
Dmitry Verkhoturov and Umputun
9df8de511a
Run telegram auth goroutine
...
Fix for https://github.com/go-pkgz/auth/issues/90
2021-08-06 16:56:07 -05:00
Dmitry Verkhoturov and Umputun
0efc04e5cd
fix deprecated flag, improve tests
2021-07-27 11:45:42 -05:00
Umputun
b66c94e002
migrate jwt lib to maintained fork and updated (the same way) go-pkgz/auth
2021-07-26 21:06:12 -05:00
Dmitry Verkhoturov and Umputun
ea644a1a31
add telegram auth backend support
2021-07-25 13:16:50 -05:00
Umputun
ad54a9450b
fix parent tg formatting
2021-07-04 00:30:11 -05:00
Umputun
b8050f817c
quote parrent comment in tg notif
2021-07-04 00:03:23 -05:00
Umputun
70245504f5
restore link to original in tg notif
2021-07-03 23:52:20 -05:00
Umputun
05a85b6bfd
reformat tg message to make it readable again
2021-07-03 23:48:00 -05:00
Dmitry Verkhoturov and Umputun
83ae758573
address review commends
2021-07-03 14:57:09 -05:00
Dmitry Verkhoturov and Umputun
200733ed03
add user telegram notifications
2021-07-03 14:57:09 -05:00
Dmitry Verkhoturov and Umputun
1847184960
clarify telegram notifications code and text
2021-06-13 19:07:56 -05:00
Dmitry Verkhoturov and Umputun
de6e541604
fix telegram token server setting
2021-06-13 15:47:52 -05:00
Dmitry Verkhoturov and Umputun
fd4c6ceb18
add UserDetailTelegram support
2021-06-13 13:18:33 -05:00
Dmitry Verkhoturov and Umputun
d6167980f4
remove ability to set telegram API, clarify params
2021-06-13 01:49:15 -05:00
Dmitry Verkhoturov and Umputun
ea15b28bf6
clarification of notify comments and code
2021-06-12 12:59:26 -05:00
Dmitry Verkhoturov and Umputun
c0b392ad4c
separate user and admin notifications
...
The current state is a mess of user and admin
notifications, which will become worse after
implementing the new user notification methods
like a telegram.
This change makes things simpler
for the remark42 users.
2021-06-03 00:30:53 -05:00
Dmitry Verkhoturov and Umputun
c6e2c38e34
fix email templates path in tests
...
Before:
failed to make notify service,
failed to create email notification destination:
can't set templates:
can't read message template:
open email_reply.html.tmpl:
no such file or directory
After:
make notify, types=[email]
create notifier service, queue size=100, destinations=1
2021-05-27 12:23:12 -05:00
Dmitry Verkhoturov and Umputun
1cff4eb847
clarify deprecation messages
...
Turned out we don't really want to break
users configurations, so deprecated values
stay with us at least before 2.0 is released.
2021-05-25 14:42:29 -05:00
Dmitry Verkhoturov and Umputun
b13fa228b6
start using the provided timeout in the telegram notify
2021-05-25 13:29:19 -05:00
Dmitry Verkhoturov and Umputun
9fa23cc537
reset image cleanup TTL on Submit
...
Also:
- make commitTTL equal to EditDuration,
so that image is committed to permanent
storage after comment can no longer be edited
- move cleanupTTL to Cleanup function,
as it's not used elsewhere in the code
- add variables to some tests sleeps, so that
instead of being magic numbers they would
rely on timers of structures they suppose
to wait for
2021-05-24 17:33:59 -05:00