cofacts

Month: 2020-11

2020-11-01

valentin-劉君磊 14:05:52
@floquetvalentin has joined the channel
🐳 1 ❤️ 1 🦒 1
a-chioh 17:15:02
@a-chioh has joined the channel

2020-11-02

github 14:08:03

Review on #231 On-boarding tutorial

The unit tests are extremely helpful when I read through the code. Thanks for providing the thorough tests cases! I have some comments regarding wording and how `replies` array can be constructed.

請問今天開會前有機會 merge 嗎 @acerxp511
應該可以吧
github 14:08:03

Comment on #231 On-boarding tutorial

Please replace `"send your message to our chatroom"` with `"Send messages to chats"` to match <https://github.com/cofacts/rumors-line-bot/issues/216#issuecomment-718374931|LINE UI> and also update the translate file key, thanks!

請問今天開會前有機會 merge 嗎 @acerxp511
應該可以吧
github 14:08:03

Comment on #231 On-boarding tutorial

It seems that `createPermissionSetupDialog` does not return a promise, thus no need to `await` here? Please check if all `await` in this method are necessary. If all of them are not, we may remove `async` for `tutorial()` as well :+1: Another thing is, no matter we need `await` or not, the construction of `replies` can be simplied using object spread operator: ``` replies = [ { type: 'text', text: replyProvidePermissionSetup, }, { ...await createPermissionSetupDialog(askForPermissionSetup), quickReply: {...} }, ] ``` The pattern above can be applied to all other `if` cases and replace all `replies.push()` invocation.

請問今天開會前有機會 merge 嗎 @acerxp511
應該可以吧
github 14:08:03

Comment on #231 On-boarding tutorial

Why does serve middleware not work for dev environment?

請問今天開會前有機會 merge 嗎 @acerxp511
應該可以吧

2020-11-03

github 14:34:16

Comment on #231 [wip] Cleanuptests

<https://coveralls.io/builds/34667833|Coverage Status> Coverage decreased (-0.03%) to 86.035% when pulling *<https://github.com/cofacts/rumors-api/commit/f4ec4b2c9d52c7fa56533a2a7ef27fb72e2bc441|f4ec4b2> on cleanuptests* into *<https://github.com/cofacts/rumors-api/commit/177693c345bcbbed7e442f1c71fec3bf3a075e0e|177693c> on backendUsers*.

2020-11-04

github 14:11:01

Comment on #227 index user if not existed and log last active time for user accessing apis via backend apps

Nit: seems that this file is no longer a graphql mutation and is more like a util function. Maybe we can consider moving it to `graphql/models/User`, or move to `util` (along with all utility functions under `graphql/models/User`). We may <https://github.com/magicmark/jest-how-do-i-mock-x/blob/master/src/function-in-same-module/README.md|need some work around to properly mock these utility in the same file>.

github 14:11:01

Comment on #227 index user if not existed and log last active time for user accessing apis via backend apps

nit: `appUserId` here actually can be db user id or app user id. Maybe we can denote this in the doc string, or even choose to change argument name to `dbOrAppUserId` or just `userId`.

github 14:11:01

Review on #227 index user if not existed and log last active time for user accessing apis via backend apps

LGTM! Thanks for the fix! Added some nit-picking comments that should not be merge blockers. Feel free to adapt and merge anytime :)

github 14:26:32

Comment on #231 Cleanup tests

nit: indent XD

github 14:26:32

Review on #231 Cleanup tests

It's looking great! Thanks for making the tests more robust!

github 14:59:26

Comment on #231 On-boarding tutorial

I don't know liff uses proxy to a webpack server for development, just copy and paste the `/liff` part to apply `/static` at that time.

github 15:09:18

Comment on #231 On-boarding tutorial

Text will ellipsis before assigning to altText, so the snapshot looks a little weird.

github 19:33:06

Review on #231 On-boarding tutorial

LGTM! Let's merge!

hsiao 20:35:15
@yutunghsiao19 has joined the channel
wesley zeng 20:45:01
@zengwesley31729 has joined the channel
github 22:45:18

#233 Update tutorial wording and compress images

Details see : <https://g0v.hackmd.io/Sl_84QO8TQ6WKKI0bT4pYw#%E6%9C%AA%E7%AB%9F%E9%A0%85%E7%9B%AE|https://g0v.hackmd.io/Sl_84QO8TQ6WKKI0bT4pYw#%E6%9C%AA%E7%AB%9F%E9%A0%85%E7%9B%AE>

github 23:06:23

Comment on #233 Update tutorial wording and compress images

*Pull Request Test Coverage Report for <https://coveralls.io/builds/34710866|Build 1202>* • *0* of *0* changed or added relevant lines in *0* files are covered. • No unchanged relevant lines lost coverage. • Overall coverage remained the same at *85.94%* * * * * * * *:yellow_heart: - <https://coveralls.io|Coveralls>*

2020-11-05

nonumpa 12:48:21
我發現這兩張圖倒過來了 囧
Screenshot_20201105-124700.png
#測試時記得要清 LINE 的 cache
#雖然清了也不一定會發現圖片順序反了
XDDD
其實我沒試過我們用的那個 koa-sendfile 是否可以讓我們在檔案名稱後面加上 `?cachebust=xxx`
需要麻煩 @acerxp511 測測看惹
如果可以的話那我們可以補一下 cache bust param 確保使用者拿得到新的 build 的圖
github 13:03:58

#234 Fix tutorial image order

Fix wrong image order caused by commit `Compress tutorial images`. bug snapshot <https://user-images.githubusercontent.com/6376572/98199754-e855e280-1f66-11eb-8364-3d8e48cd7d4f.png|Screenshot_20201105-124700>

github 13:11:08

Comment on #234 Fix tutorial image order

*Pull Request Test Coverage Report for <https://coveralls.io/builds/34729643|Build 1207>* • *0* of *0* changed or added relevant lines in *0* files are covered. • No unchanged relevant lines lost coverage. • Overall coverage remained the same at *85.94%* * * * * * * *:yellow_heart: - <https://coveralls.io|Coveralls>*

github 13:49:11

Review on #234 Fix tutorial image order

Thanks for the fix! If applicable, I suggest adding cache busting argument (like `${RUMORS_LINE_BOT_URL}/xxx.png?v=20201105`) to make sure users get the latest image after deploy.

mrorz 14:12:37
其實我沒試過我們用的那個 koa-sendfile 是否可以讓我們在檔案名稱後面加上 `?cachebust=xxx`
需要麻煩 @acerxp511 測測看惹
ichieh 17:37:58
@bil NPO HUB 11/22(日)會有周年慶的活動,他們希望 g0v 可以有個 15 分鐘的 talk (14;00 - 16:00 之間)介紹 g0v 跟 Cofacts ,最好是可以讓參與者動手試著回傳訊息給 LINEBOT 試試看,不知道那天你們有沒有空來分享~:laughing:
22喔....我來問問可不可以改行程
@chiehg0v 有比較確定安排什麼時候的15分鐘嗎
ㄊ們是預計 14:30-16:00 每半小時一個團隊,你們比較方便哪個時段?我去跟他們說說
感謝讓給我們2點半❤️
聽起來像是個大發傳單的時機 📃

2020-11-08

2020-11-09

github 01:25:05

Review on #227 index user if not existed and log last active time for user accessing apis via backend apps

Thanks for the refactor! Let's merge this. I will try deploy it to staging before wednesday, along with data migration.

mrorz 11:59:30
聽起來像是個大發傳單的時機 📃
mrorz 12:18:57
https://cofacts.g0v.tw/article/iqyc8tigxul9
內容農場影片直接從 Cofacts 網站拿內容耶 ._.
謝謝 ilya 2018 年就指給我們的路。
mrorz 12:24:10
Youtube channel: https://www.youtube.com/c/htcheng417/about

關於網址裡的 htcheng417:
https://www.bnext.com.tw/article/57114/walk-in-the-foggy-forest

數位時代

走入網路裡一整片迷霧森林,放下對立就能看見藍天|數位時代

我們在網路的平台資本主義世界裡行走、生存,往往只看到樹木,看不到森林。

mrorz 12:27:21
謝謝 ilya 2018 年就指給我們的路。
💯 2
github 13:44:18

Comment on #234 Fix tutorial image order and handle the case RUMORS_LINE_BOT_URL undefined

I suggest we keep `VERSION` as a variable in `tutorial.js` because • If we change image in the future, it's natural that we go to tutorial.js and make changes there • Since image updates are under source control, so should its `VERSION`. The change of image file and the change of `VERSION` variable should be updated together in a PR.

github 13:44:18

Review on #234 Fix tutorial image order and handle the case RUMORS_LINE_BOT_URL undefined

Thanks for adding the cache-busting mechanism! I have some suggestion regarding where we put the cache busting variable.

github 21:43:11

Review on #234 Fix tutorial image order and handle the case RUMORS_LINE_BOT_URL undefined

Thanks for the fix! Let's <https://github.githubassets.com/images/icons/emoji/shipit.png|:shipit:>

2020-11-10

Sha 16:35:17
@simon261 has joined the channel
Jasmine Liu 19:04:00
@jasmine.liu has joined the channel
stbb1025 20:59:55
@yutunghsiao19 figma已經更新圖片囉~另外登入選單的部分,我想一想覺得會登入的人,應該就不會想再看landing page了,所以現在改成點選登入後登入並連到個人頁,如果使用者再跳回landing page的話只要把登入的地方換成頭像即可,再點頭像也不會有選單,而是直接連到個人頁,感謝~
目前還沒有個人頁 (還在做 ><)
可以先連到 `/hoax-for-you` 唷
好~~
🙆 1
mrorz 23:59:41
chatbot flex message 的自動調整字體大小 `shrink-to-fit` 看起來會有用耶
https://speakerdeck.com/line_developers_tw/line-api-platform-update-202011?slide=20

Speaker Deck

LINE API Platform Update 202011

LINE API Platform Update 2020/11 by NiJia Lin @ Chatbot community #25 <https://chatbots.kktix.cc/events/meetup-025>

2020-11-11

mrorz 13:25:44
今日會議記錄
主要會跟 user refactor 的上線有關唷
https://g0v.hackmd.io/@mrorz/cofacts-meeting-notes/%2FkWuTnoC1TG-MONPhxp8rGQ
yiji 19:09:32
請問有沒有人知道哪裡有專門討論怎麼解決假消息或仇恨言論的「方法、試驗成果、倫理」的網站或討論群?
我看得懂中文跟英文...  謝謝。
「解決」的部分有點難耶,我覺得現在看起來滿多製造假訊息的人都是因為經濟誘因使然,而且又是跨國的所以鞭長莫及。

整理的作法裡面最多就是透過增加查核的曝光為手段來進行「減害」,其他更強制作法,就要考慮到言論自由而有所拿捏了
現在回頭看當時整裡的東西,Facebook 在 2018 年還在試著用馬尼拉中介者來規避平台查核責任,2020 年的現在卻被另一派指責說在做 sensorship。

也是此一時彼一時呢。
感謝!所以說 該用的關鍵字是 Mitigation,了解
yiji 19:16:21
推薦書或期刊也可以。

2020-11-12

2020-11-13

mrorz 01:00:10
現在開始 migration,預計一個小時
Cofacts 網站與 LINE bot 會下線唷
🙏 1
mrorz 01:39:27
data migration 完成,感謝 @zoetwca m(_ _)m
🙏 1
github 02:19:27

#354 Remove stackimpact

Stack impact was introduced to mitigate CPU issue: <https://github.com/cofacts/rumors-site/pull/189|#189> However after it's added, we did not get meaningful insight from it. On the other hand, it requires native extension when installing the project and hence stops some of our contributor in g0v hackathon from contributing. I suggest we remove stackimpact from rumors-site bundle.

mrorz 02:33:27
關於 SEO,我之前有個想法忘記在會議上提出。

大致上的概念是:既然 Google 搜尋不支援 accept-language 自動偵測,那我們一個 domain 就固定用一種語言好。

我提議我們改成
• `cofacts.org`, `cofacts.g0v.tw`, `zh.cofacts.org` 三個 domain 永遠 serve 中文版
• `en.cofacts.org` 永遠 serve 英文版
• 無論是哪個版本,都採用 google 建議,使用 `<link rel="alternate" hreflang="_lang_code_" href="_url_of_page_" />` 指向所有語言
• 在瀏覽器用 `navigator.language` 偵測瀏覽器語言,如果語言與 UI 不同,則顯示一個切換語言的 banner,顯示同一個頁面的不同語言 URL
這樣應該可以讓最長被使用的 cofacts.g0v.tw, cofacts.org 的 <html lang> 在 index 時是受眾最常用的中文,也解決中文首頁 SEO 的問題。

See: https://github.com/cofacts/rumors-site/issues/347#issuecomment-718878471

關於這個變更大家有什麼覺得不妥的嗎~

Google Developers

Tell Google about localized versions of your page

mrorz 02:40:03
關於有三個版本都 serve 中文版這件事情,中文版可能要挑一個 URL 當作 canonical URL。

https://developers.google.com/search/docs/advanced/crawling/consolidate-duplicate-urls?hl=zh-Hant&visit_id=637408030503556838-3312092471&rd=1

目前 cofacts.g0v.tw 是被 index 最多的版本,如果換 canonical url 到 cofacts.org 的話,page rank 會掉嗎?

Google Developers

Consolidate duplicate URLs  |  Google Search Central  |  Google Developers

2020-11-14

mrorz 02:32:20
我發現 Google 其實不認為只翻譯 UI 字串的網站就多語網站。

> Translating only the boilerplate text of your pages while keeping the bulk of your content in a single language (as often happens on pages featuring user-generated content) can create a bad user experience if the same content appears multiple times in search results with various boilerplate languages.
https://developers.google.com/search/docs/advanced/crawling/managing-multi-regional-sites#make-sure-the-page-language-is-obvious

那我覺得我們還是
1. 把基於 http request header 的自動語言偵測功能拿掉;en.xxx server 英文 UI,其他一律 serve 中文 UI
2. 無論哪個版本的網址,canonical 一律使用 cofacts.org/xxx 避免重複爬取
3. 除了整頁都英文的 landing page 之外,其他頁面都不下 hreflang 標籤了,就通通當中文ㄅ

Google Developers

Managing multi-regional and multilingual sites  |  Google Search Central

mrorz 12:04:44
@acerxp511 上次小聚那個訊息分配不會動
可能是因為 code 裡面用 `getSheets()[0]` 可能會抓到不是 README 的其他 sheet
image.png
今天十傑我先改用 getSheetByName 惹
但我沒動到 template~
不知道為啥 import sheet 進來卻會改到 sheet index @@
mrorz 13:20:57
十傑的高中生沒有 FB, twitter, github
有問是否可以用 google 登入(對齁沒有接 QQ
另外有問題是
API 目前 Facebook redirect 回來一律會到 cofacts.g0v.tw
所以如果從 cofacts.org 登入的話
第一次登入會遇到 session redirect 不存在的問題 @@
手機版送回應的時候沒有檢查 reference 是否存在

會送到後端然後再噴出英文的 error
哦哦哦
後來無法登入的人默默又可以ˊ登入了
原因不ㄇㄧㄥ
登入乾脆改用這個?
https://webauthn.guide/
啊,他不能跨網域
所以 api.cofacts.orgcofacts-api.g0v.tw 分開的問題還是存在囧
Google要我幫你接嗎
我自己產品上目前有接過
@lucien 好哇感謝感謝,要開張票ㄇ

我們 passport 設定在這兒
https://github.com/cofacts/rumors-api/blob/master/src/auth.js

elasticsearch mapping 在 `user` index 下可能要增加一個記 google user id 的欄位
https://github.com/cofacts/rumors-db/blob/master/schema/users.js#L21
DB我有問題再問你

2020-11-15

2020-11-16

github 14:32:52

#3 Apply data grid to thank-you editor

• Better appearance for the reply list page <https://cofacts.github.io/community-builder/#/editorworks|https://cofacts.github.io/community-builder/#/editorworks> • Add date filter <https://user-images.githubusercontent.com/108608/99219781-59738080-2818-11eb-8030-ffc33555f67e.png|image>

2020-11-17

github 12:14:53

#235 Feature/dialogflow

Fixes <https://github.com/cofacts/rumors-line-bot/issues/222|#222> dialogflow intent design <https://g0v.hackmd.io/kWuTnoC1TG-MONPhxp8rGQ#2020-Q4--2021-Q1-%E9%80%B2%E5%BA%A6%E7%A2%BA%E8%AA%8D|discussion>

關於長文章也 match 會到 dialogflow intent 的問題,還在沒空詳細研究,我這兩天要準備禮拜四的面試,所以先發 PR 了
加油加油
github 12:36:21

Comment on #235 Feature/dialogflow

*Pull Request Test Coverage Report for <https://coveralls.io/builds/35015547|Build 1216>* • *21* of *21* *(100.0%)* changed or added relevant lines in *2* files are covered. • No unchanged relevant lines lost coverage. • Overall coverage increased (+*0.3%*) to *86.38%* * * * * * * *:yellow_heart: - <https://coveralls.io|Coveralls>*

2020-11-18

github 14:57:05

Comment on #233 ctx userId should be dbUserId

<https://coveralls.io/builds/35051417|Coverage Status> Coverage increased (+0.06%) to 86.003% when pulling *<https://github.com/cofacts/rumors-api/commit/d09fdf58809aabe60a5f86155b1c88ed3c43581b|d09fdf5> on ctxUserId* into *<https://github.com/cofacts/rumors-api/commit/2c0769ea2273fe96efee24006607e8f9bf934b95|2c0769e> on master*.

github 16:01:40

Comment on #52 add slug &amp; bio fields for user

Thanks for updating the typo! I found that the text is a bit outdated as well. Suggested change

mrorz 21:18:05
@stbb1025 請問 landing page 最上面的大圖「懷疑自己收到謠言嗎」有英文版的圖嗎 cc/@yutunghsiao19
我明天提供~
已經放上figma囉~
hsiao 21:21:18
翻譯有缺的部分
```#: components\Hyperlinks.js:115
msgid "Domain name cannot be resolved"
msgstr ""

#: components\Hyperlinks.js:118
msgid "URL is malformed or not supported"
msgstr ""

#: components\Hyperlinks.js:122
msgid "Target site contains HTTPS error"
msgstr ""

#: components\Hyperlinks.js:124
msgid "Unknown error"
msgstr ""

#: pages\article\[id].js:395
#, javascript-format
msgid "There is ${ replyCount } fact-checking reply to the message"
msgid_plural "There are ${ replyCount } fact-checking replies to the message"
msgstr[0] ""
msgstr[1] ""

#: pages\article\[id].js:409
#: pages\article\[id].js:445
msgid "Add Cofacts as friend in LINE"
msgstr ""

#: components\TrendPlot.js:128
msgid "Past 31 days"
msgstr ""

#: components\CreateReplyRequestForm\CreateReplyRequestForm.js:132
msgid "Please provide more info"
msgstr ""

#: components\CreateReplyRequestForm\CreateReplyRequestForm.js:198
msgid ""
"Did you find anything suspicious about the message after you search "
"Facebook & Google?"
msgstr ""

#: components\CreateReplyRequestForm\CreateReplyRequestForm.js:210
msgid ""
"Please provide paragraphs you find controversial, or related news, image & "
"video material you have found."
msgstr ""

#: components\AppLayout\AppLayout.js:65
msgid "Your display name has been updated."
msgstr ""

#: components\AppLayout\AppLayout.js:77
msgid "Please enter new display name"
msgstr ""

#: components\AppLayout\AppLayout.js:82
msgid "Display name cannot be empty."
msgstr ""

#: components\ListPageDisplays\ArticleCard.js:115
msgctxt "Info box"
msgid "reports"
msgstr ""```
```#: components\Hyperlinks.js:115
msgid "Domain name cannot be resolved"
msgstr "找不到網域"
#: components\Hyperlinks.js:118
msgid "URL is malformed or not supported"
msgstr "不支援或錯誤的 URL"
#: components\Hyperlinks.js:122
msgid "Target site contains HTTPS error"
msgstr "目標網站有 HTTPS 錯誤"
#: components\Hyperlinks.js:124
msgid "Unknown error"
msgstr "未知錯誤"
#: pages\article\[id].js:395
#, javascript-format
msgid "There is ${ replyCount } fact-checking reply to the message"
msgid_plural "There are ${ replyCount } fact-checking replies to the message"
msgstr[0] "本訊息有 ${ replyCount } 則查核回應"

#: pages\article\[id].js:409
#: pages\article\[id].js:445
msgid "Add Cofacts as friend in LINE"
msgstr "加 LINE 查謠言"
#: components\TrendPlot.js:128
msgid "Past 31 days"
msgstr "近 31 日"
#: components\CreateReplyRequestForm\CreateReplyRequestForm.js:132
msgid "Please provide more info"
msgstr "字數不足"
#: components\CreateReplyRequestForm\CreateReplyRequestForm.js:198
msgid ""
"Did you find anything suspicious about the message after you search "
"Facebook & Google?"
msgstr "搜尋臉書或 Google 後,你發現了什麼可疑的地方,想給其他編輯參考呢?"
#: components\CreateReplyRequestForm\CreateReplyRequestForm.js:210
msgid ""
"Please provide paragraphs you find controversial, or related news, image & "
"video material you have found."
msgstr "請分享你覺得訊息中的爭議點或是你查核到的相關圖片、影片以及報導資訊"
#: components\AppLayout\AppLayout.js:65
msgid "Your display name has been updated."
msgstr "暱稱已更新"
#: components\AppLayout\AppLayout.js:77
msgid "Please enter new display name"
msgstr "請輸入新的暱稱"
#: components\AppLayout\AppLayout.js:82
msgid "Display name cannot be empty."
msgstr "暱稱不能是空白"
#: components\ListPageDisplays\ArticleCard.js:115
msgctxt "Info box"
msgid "reports"
msgstr "回報"```

2020-11-19

github 01:49:35

Comment on #232 [wip] user profile related api changes

<https://coveralls.io/builds/35067240|Coverage Status> Coverage increased (+0.4%) to 86.354% when pulling *<https://github.com/cofacts/rumors-api/commit/af2a790f0aff540478d4110defd2f4231fd91bd1|af2a790> on userProfile* into *<https://github.com/cofacts/rumors-api/commit/2c0769ea2273fe96efee24006607e8f9bf934b95|2c0769e> on master*.

mrorz 01:59:02
關於今天討論到小聚需要更有系統的教學這件事情
我想到的形式大概是這樣

小聚開始前,準備兩個 spreadsheet:
(a) 每人 10 篇要按讚的回過的訊息
(b) 每人 10 篇還沒回的訊息

先在 Slido 放 (a) 與 (b) 的連結。

1. 2:00 前:確保先來的人有連上網路。每個人簽到的時候取得一個號碼牌。
2. 2:00 ~ 2:20 開場:場地介紹、Slido 簡介、Cofacts 機器人系統簡介,大家自我介紹。
3. 2:20 ~ 2:40 介紹「幫回應按讚」的用途,以及怎麼做;什麼樣的回應可以按「有用」、哪些可以跳過、哪些真的母湯要按「沒用」,如何就事論事的給 feedback
4. 2:40 ~ 3:00 讓大家從 Slido 打開 spreadsheet (a)。直接點進自己號碼牌的那個 sheet (*不要再自己認領,改 tab 名字是高級操作大家做不來!*)然後幫每一篇按有用或沒用
5. 3:00 ~ 3:10 休息時間,閒聊「看到覺得最好的回應、覺得哪裡好」
6. 3:10 ~ 3:30 介紹「寫新回應」的方式,如何找全文、拆解回應、附出處等等
7. 3:30 ~ 4:30 讓大家從 Slido 打開 spreadsheet (b)。直接點進自己號碼牌的那個 sheet,先挑選「*一篇*」覺得最有興趣的回;回完之後如果行有餘力,再挑一篇。如果都覺得不想回,去「等你來答」挑,不要硬回 XDDD
8. 4:30 ~ 5:00 讓大家講感想、介紹文章列表(回家怎麼挑訊息)、RSS 功能、最後拍合照
❤️ 2
mrorz 11:32:27
@lucien 好哇感謝感謝,要開張票ㄇ

我們 passport 設定在這兒
https://github.com/cofacts/rumors-api/blob/master/src/auth.js

elasticsearch mapping 在 `user` index 下可能要增加一個記 google user id 的欄位
https://github.com/cofacts/rumors-db/blob/master/schema/users.js#L21

src/auth.js

schema/users.js:21

mrorz 14:22:48
教學頁面的「分項解說」的內容已經填好囉,請 @lucien@stbb1025 過目
https://g0v.hackmd.io/sB_zayWjTo-W0R7xe_U34w?view#%E5%88%86%E9%A0%85%E8%A7%A3%E8%AA%AA

裡面的每個步驟比照 wireframe,分成下面幾個 section:
• 主標
• 副標
• 內文
• (子步驟主標、子步驟內文、圖)x 1 ~ N

g0v.hackmd.io

關於 / 教學 - HackMD

詢問者的 2 的標題 跟 3 的內容我覺得需要調整
mrorz 19:48:13
某篇一個月以前被回報的訊息,在過去一個小時內得到了 10 多個回應:
https://cofacts.g0v.tw/article/3a68xz85ennsd
• 訊息本文沒頭沒尾,這些人應該是看到下面的回報者理由進來的。
• 訊息本文只有一個人回報,LINE 上幾乎沒人在傳
• 過去一個小時內在此篇以下回應的人,沒有一個有寫出處,也沒有人在其他訊息下有回應。
• 這些新使用者之間幫彼此的回應 upvote,把其他有附出處的回應頂到很下面的地方。
其實過去也有洗錢集團在 Cofacts 洗版,不過當時只有一個編輯發表意見:
https://cofacts.g0v.tw/article/1fj7zlv1mgfbs

這種行為其實有些接近 Facebook、Twitter 與 Youtube 所定義的「資訊操弄」的行為:https://tfc-taiwan.org.tw/articles/767

不過 Cofacts 其實不像是上面的平台,有在使用者條款裡頭載明平台方可以進行的動作,所以想問問社群的大家,我們是否要針對這篇( https://cofacts.g0v.tw/article/3a68xz85ennsd )做什麼動作呢?

2020-11-20

2020-11-21

jojomango 15:43:29
@jojomango has joined the channel

2020-11-22

Albert 11:05:55
@fltermare has joined the channel
jojomango 13:23:30
Hi 我想要幫忙修rumor-site的issue,
請問優先該修的是有‘good first issue' tag的issue嗎

開發流程是從dev checkout一個fix/xxx的branch 修正後PR回dev嗎
然後討論都在github進行嗎
討論在github或是slack這邊都可以喔
okie~ 👍
👍 3
github 17:16:17

Review on #233 ctx userId should be dbUserId

Super thanks for spotting this issue! Let's get the fix out ASAP and see how we can migrate entities with `userId` being `U.{32}` .

2020-11-23

github 00:49:48

Comment on #233 ctx userId should be dbUserId

The fix is tested on staging and deployed to production. After the fix is enrolled, the following query yields 1804 results: ``` curl -XPOST "<http://172.18.0.3:9200/_all/_search?pretty=true>" -H 'Content-Type: application/json' -d' { "query": { "regexp": { "userId": { "value": "U.{32}" } } } }' ``` Let's observe if the number stopps increasing after the fix.

github 12:26:01

Comment on #233 ctx userId should be dbUserId

Update: The number of documents w/ `U.{32}` `userId` stops at 1,804, so the API patch is successful :tada: The indexes that needs to be migrated: • `articles`: 296 documents • `replyrequests`: 499 documents • `articlereplyfeedbacks`: 1009 documents No documents in other index need migration.

github 13:08:21

Comment on #228 untangle test dependencies

It seems that <https://github.com/cofacts/rumors-api/pull/231|#231> has fixed this issue. May I close this? <https://github.com/ztsai|@ztsai>

github 13:10:17

#234 Support Google sign-in

From <https://g0v.hackmd.io/Ha-SMCxJQuGzqx6EnrKanA?both#%E5%8D%81%E5%82%91%E6%AA%A2%E8%A8%8E|20201118 meeting>, we should support new login method: Google. &gt; 我們 passport 設定在這兒 &gt; <https://github.com/cofacts/rumors-api/blob/master/src/auth.js|https://github.com/cofacts/rumors-api/blob/master/src/auth.js> &gt; elasticsearch mapping 在 user index 下可能要增加一個記 google user id 的欄位 &gt; <https://github.com/cofacts/rumors-db/blob/master/schema/users.js#L21|https://github.com/cofacts/rumors-db/blob/master/schema/users.js#L21>

github 13:11:24

Comment on #278 Hint editors on mobile to fill in references

From <https://g0v.hackmd.io/Ha-SMCxJQuGzqx6EnrKanA#%E6%89%8B%E6%A9%9F%E7%89%88%E5%AF%AB%E5%9B%9E%E6%87%89%E6%99%82%E6%B2%92%E6%9C%89%E6%93%8B%E3%80%8C%E6%B2%92%E5%AF%AB-reference%E3%80%8D%E7%9A%84%E7%8B%80%E6%B3%81|20201118 meeting> we should prevent user from submitting when reference is not provided on mobile UI.

github 13:12:40

Comment on #347 SEO for Mandarin content

Conclusion from <https://g0v.hackmd.io/Ha-SMCxJQuGzqx6EnrKanA#SEO-for-landing-page|20201118>: *所有頁面* 移除現有的 accept-language 偵測機制 *一般頁面* <http://cofacts.g0v.tw|cofacts.g0v.tw>, <http://zh.cofacts.org|zh.cofacts.org>, <http://en.cofacts.org|en.cofacts.org> --canonical–&gt; <http://cofacts.org|cofacts.org> *Landing page* • <http://cofacts.g0v.tw|cofacts.g0v.tw>, <http://zh.cofacts.org|zh.cofacts.org> --canonical–&gt; <http://cofacts.org|cofacts.org> • <http://cofacts.org|cofacts.org>: canonical self, --hreflang=en–&gt; <http://en.cofacts.org|en.cofacts.org> • <http://en.cofacts.org|en.cofacts.org>: canonical self, --hreflang=zh–&gt; <http://cofacts.org|cofacts.org> The change above should go to rumors-deploy instead, because only nginx settings are needed.

github 18:41:14

#235 List reply request

ListReplyRequest API • pagination args: first, after, before • filter args: userId, appId, articleId, createdAt • orderBy args: createdAt, vote

github 19:10:05

Comment on #235 List reply requests

<https://coveralls.io/builds/35169757|Coverage Status> Coverage increased (+0.1%) to 86.065% when pulling *<https://github.com/cofacts/rumors-api/commit/82255775d2f446b5c8ebd6bc6db5fb7376e6f936|8225577> on listReplyRequest* into *<https://github.com/cofacts/rumors-api/commit/aa7e7f89f84d9321f18d73ee3f505166a73ffdbb|aa7e7f8> on master*.

github 21:43:13

Comment on #284 Fix logout in mobile menu

I think this issue already be fixed

jojomango 23:02:22
https://github.com/cofacts/rumors-site/issues/265
我在local修了這個bug, 不過feature branch 無法push (`remote: Permission to cofacts/rumors-site.git denied to jojomango`)
可以幫忙加我進專案嗎 https://github.com/jojomango

#265 Reply search result's time is not correct

請你 fork 專案後,發 PR 過來好嗎?
ok
@jojomango 的 fix 上 production 囉
非常感謝 m(_ _)m
多謝~
github 23:33:11

#355 fix reply time display bug

fix <https://github.com/cofacts/rumors-site/issues/265|#265> createdAt is property of reply, not articleReply

2020-11-24

github 11:17:48

Comment on #355 fix reply time display bug

Hello <https://github.com/jojomango|@jojomango> thanks for taking a look at the issue! It turns out that `ArticleReply` actually have `createdAt` attribute on the <http://api.cofacts.org/|API>. ``` """The linkage between an Article and a Reply""" type ArticleReply { replyId: String reply: Reply # ...(omitted)... status: ArticleReplyStatusEnum createdAt: String updatedAt: String } ``` Seems that the root cause is that we forgot to include `articleReply`'s `createdAt` in our GraphQL queries. To be more specific, we forgot to include `createdAt` in <https://github.com/cofacts/rumors-site/blob/3a135df69172617599e0dc7ebee704040a88fcf5/components/ListPageDisplays/ReplyItem.js#L125-L131|ReplyItemArticleReplyData fragment>. Whatever field we use in `ListPageDisplays/ReplyItem` shall be included in the fragment, as we try to <https://www.apollographql.com/docs/react/data/fragments/#creating-colocated-fragments|colocate fragments and components> in this project. When an editor re-use other's written reply in another article, `articleReply.createdAt` will be different from `reply.createdAt`, thus I think it would be more adequate if we keep using `articleReply.createdAt`. Would you mind taking a look and giving it a try? Thanks!

👌 1
mrorz 13:57:55
由於小聚與 summit 會連續兩週進行
明天的會議主要會討論這兩個唷
另外也需要推進 tutorial 跟 code review (抱歉最近在弄小聚 QQ)
https://g0v.hackmd.io/@mrorz/cofacts-meeting-notes/%2FnaJGBDO0QFW4b4H4M9ElIw
🙌 3
github 14:27:33

Comment on #284 Fix logout in mobile menu

Confirmed on production. Seems that it's fixed in <https://github.com/cofacts/rumors-site/pull/352|#352>. Thanks for keeping our backlog clean!

2020-11-25

github 01:20:59

Review on #355 fix reply time display bug

Fix confirmed on my localhost env. Thanks a million for taking a look at this issue and submit the concise yet powerful fix!

🎉 1 👍 1
github 18:14:05

#5 Yegogo spamming incident

[WIP] wait for community response at <https://www.facebook.com/groups/cofacts/permalink/2866149510283526/?__cft__%5B0%5D=AZUx4iEfHMHCvEpOuvnUWnzQWrc1F5PyBeoRNlOIaRNFpP7tzpxTiPNwE4sG7tIaXdsmgSkQLIQ1ZAt5oA29HcBkKUJYeP-zqA1xhOI3uvkGiI8-VwrjyG38Y1BX6_JTx4zrrb879kV3OO-6trWuFrMGwchw5NjUjp7jEv74X1GWbN_nXEF9eoagBhpW5N_MJ2U&amp;__tn__=%2CO%2CP-R|https://www.facebook.com/groups/cofacts/permalink/2866149510283526/?__cft__[0]=AZUx4iEfHMHCvEpOuvnUWnzQWrc1F5PyBeoRNlOIaRNFpP7tzpxTiPNwE4sG7tIaXdsmgSkQLIQ1ZAt5oA29HcBkKUJYeP-zqA1xhOI3uvkGiI8-VwrjyG38Y1BX6_JTx4zrrb879kV3OO-6trWuFrMGwchw5NjUjp7jEv74X1GWbN_nXEF9eoagBhpW5N_MJ2U&amp;__tn__=%2CO%2CP-R>

github 19:57:57

Comment on #236 [WIP] Script to remove an article reply on production

<https://coveralls.io/builds/35237086|Coverage Status> Coverage increased (+0.02%) to 85.963% when pulling *<https://github.com/cofacts/rumors-api/commit/3169147d6f349f126f8afd831f4feb06728576b8|3169147> on delete-script* into *<https://github.com/cofacts/rumors-api/commit/aa7e7f89f84d9321f18d73ee3f505166a73ffdbb|aa7e7f8> on master*.

github 20:11:57

#356 Landing page

*Spec* figma: <https://www.figma.com/file/zpD45j8nqDB2XfA6m2QskO/Cofacts-website?node-id=2760%3A463|https://www.figma.com/file/zpD45j8nqDB2XfA6m2QskO/Cofacts-website?node-id=2760%3A463>

2020-11-26

Dave Morrissey 13:53:57
@david.l.morrissey has joined the channel
github 22:11:32

#5 need-to-check-list-generator V2

*Description* Update script for Cofacts meetup, details see <https://g0v.hackmd.io/naJGBDO0QFW4b4H4M9ElIw#%E5%B0%8F%E8%81%9A-rundown|discussion>. ``` npm start -- -p &lt;number of people&gt; -f &lt;number of articles per person&gt; -r &lt;number of articles per person&gt; -r, --rnumber Number of articles which has no replies. -f, --fnumber Number of articles which reply has no positive feedbacks. ``` *Screenshot* <https://user-images.githubusercontent.com/6376572/100360193-9408c480-3033-11eb-979d-94f2b0a6b55c.png|螢幕快照 2020-11-26 下午10 05 24>

github 23:32:05

Review on #5 need-to-check-list-generator V2

LGTM! Thanks for the change.

2020-11-27

Yen-wen Chen 15:56:48
@yenwen825 has joined the channel

2020-11-29

clementtang 21:36:18
剛剛發現 cofacts 進到任何一個闢謠頁面都顯示 `an unexpected error has occurred`
Image from iOS
喔喔,感謝回報<
現在應該是好的呢
請問 @clementtang 用的是 iOS 多少呢

之前測試 6 的 Safari 與 Chrome 似乎會這樣
clementtang 2020-11-30 11:07:04
@mrorz 我是 iPhone 12 Pro 使用 iOS 14.2.1
1

2020-11-30

github 13:51:44

Comment on #232 user profile related api changes

If `UpdateUser` does not update the user, why would `updatedAt` exist here?

github 13:51:44

Comment on #232 user profile related api changes

nit: if only count is needed, we can use <https://www.elastic.co/guide/en/elasticsearch/client/javascript-api/current/api-reference.html#_count|`client.count`> instead

github 13:51:44

Comment on #232 user profile related api changes

Does this mean that each test case will receive different date? If we add new test case between existing test cases, does all subsequent test cases' `updatedAt` also change?

github 13:51:44

Review on #232 user profile related api changes

LGTM overall, thanks for the contribution! I have noted some questions regarding implementation detail.

github 13:51:44

Comment on #232 user profile related api changes

Seems that `updatedAt` is also written @@

github 13:51:44

Comment on #232 user profile related api changes

Looks like a typo lol Let's align the name with the file name. Suggested change

github 13:51:44

Comment on #232 user profile related api changes

nit: suggest adding description on `avatarData`, stating that it should be used only when `avatarType` is `OpenPeeps`

github 14:01:45

Review on #235 List reply requests

LGTM, let's ship this <https://github.githubassets.com/images/icons/emoji/shipit.png|:shipit:>

1