aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeLines
...
| | | | | * | | | | | | | | | | Add humanized delta and content to confirmation messageGravatar Akarys422019-09-29-1/+4
| | | | | | | | | | | | | | | |
| | | | | | | | | * | | | | | | Apply suggestions from review, and add correct webhook ID.Gravatar mathsman51332019-10-20-11/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - More informative docstrings for `Reddit.channel` and `get_top_posts` - Add the `amount` parameter, defaulting to 5. - Pin a max of 12 weeks worth of top posts.
| | | | | | | | | * | | | | | | Utilise `tasks.loop` and a webhook for reddit postingsGravatar mathsman51332019-10-15-147/+80
| | | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | | Remove bold tag when no channel is availableGravatar kraktus2019-10-25-2/+2
| | | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | | Requested changesGravatar kraktus2019-10-24-3/+1
| | | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | | Add a footer and one-line a stringGravatar kraktus2019-10-21-7/+4
| | | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | | Compact `!free` outputGravatar kraktus2019-10-12-13/+15
| | |_|_|_|_|_|_|_|/ / / / / / | |/| | | | | | | | | | | | |
| | | | | | | | | | * | | | | group and order constantsGravatar Numerlor2019-11-15-3/+5
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Add variable info after comment was deletedGravatar Numerlor2019-11-15-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Co-authored-by: scargly <[email protected]>
| | | | | | | | | | * | | | | join extra newlineGravatar Numerlor2019-11-15-2/+1
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Adjust code style and commentsGravatar Numerlor2019-11-12-37/+40
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | syntax highlight diff of reloaded inventoriesGravatar Numerlor2019-11-11-3/+3
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Do not cut off text arbitrarily but at last sentence to make sure no ↵Gravatar Numerlor2019-11-11-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | unfinished markdown is left in
| | | | | | | | | | * | | | | clear renamed symbols on inventory refreshGravatar Numerlor2019-11-11-0/+1
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Move signatures definitionGravatar Numerlor2019-11-10-1/+1
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Add a command for refreshing inventoriesGravatar Numerlor2019-11-10-0/+22
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Move paragraph search to not cut off long starting paragraphsGravatar Numerlor2019-11-10-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Co-authored-by: scargly <[email protected]>
| | | | | | | | | | * | | | | Cut off description at 1000 chars if paragraph is not foundGravatar Numerlor2019-11-10-0/+2
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Add a newline after signatures for readabilityGravatar Numerlor2019-11-10-1/+1
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | fix signatures and descriptions not being found when presentGravatar Numerlor2019-11-10-4/+4
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Make sure only signatures belonging to the symbol are fetchedGravatar Numerlor2019-11-03-3/+4
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Comment grammarGravatar Numerlor2019-11-03-2/+2
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Fix case for the python package name in `NO_OVERRIDE_PACKAGES`Gravatar Numerlor2019-11-03-1/+1
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Handle exceptions when fetching inventoriesGravatar Numerlor2019-11-03-31/+57
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Improve module description searchingGravatar Numerlor2019-11-02-7/+35
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Get up to 3 signatures of a symbolGravatar Numerlor2019-11-02-16/+14
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Get symbol description by searching for a dd tag instead of traversing the ↵Gravatar Numerlor2019-11-02-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | siblings
| | | | | | | | | | * | | | | Do not cut off description in code blocksGravatar Numerlor2019-11-02-1/+7
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Grammar check commentGravatar Numerlor2019-10-21-1/+1
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Allow embeds to not include signatures in case the symbol is a moduleGravatar Numerlor2019-10-21-11/+14
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Don't include a signature and only get first paragraphs when scraping when ↵Gravatar Numerlor2019-10-21-10/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | symbol is a module
| | | | | | | | | | * | | | | remove "function" from NO_OVERRIDE_GROUPSGravatar Numerlor2019-10-20-1/+0
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | Auto delete messages when docs are not foundGravatar Numerlor2019-10-20-2/+8
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | show renamed duplicates in embed footerGravatar Numerlor2019-10-20-8/+13
| | | | | | | | | | | | | | |
| | | | | | | | | | * | | | | add handling for duplicate symbols in docs inventoriesGravatar Numerlor2019-10-20-4/+35
| | |_|_|_|_|_|_|_|/ / / / / | |/| | | | | | | | | | | |
| | | | | | | | | | | | * | Make it easier for user to search for tagsGravatar Shirayuki Nekomata2019-10-18-9/+61
| | | | | | | | | |_|_|/ / | | | | | | | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | #### Closes #231 Applying the algorithm for `Needles and Haystack` to find and match tag in tags, for example: ![Example](https://cdn.discordapp.com/attachments/634243438459486219/634592981915140107/unknown.png) This only applies to searching tag_name with more than 3 in length, and at least 80% of its letters are found, from left to right. There are 3 levels of checking, stop at first found: - Check if exact name ( case insensitive ) O(1) getting from a dictionary Dict[str, Tag] - Check for all tags that has 100% matching via algorithm - Check for all tags that has >= 80% matching If there are more than one hit, it will be shown as suggestions: ![Suggestions](https://cdn.discordapp.com/attachments/634243438459486219/634595369531211778/unknown.png) In order to avoid api being called multiple times, I've implemented a cache to only refresh itself when the is a gap of more than 5 minutes from the last api call to get all tags. Editing / Adding / Deleting tags will also modify the cache directly. ##### What about other solution like fuzzywuzzy? fuzzywuzzy was considered for using, but from testing, it was giving much lower scores than expected: Code used to test: ```py from fuzzywuzzy import fuzz def _fuzzy_search(search: str, target: str) -> bool: found = 0 index = 0 _search = search.lower().replace(' ', '') _target = target.lower().replace(' ', '') for letter in _search: index = _target.find(letter, index) if index == -1: break found += index > 0 # return found / len(_search) * 100 return ( found / len(_search) * 100, fuzz.ratio(search, target), fuzz.partial_ratio(search, target) ) tests = ( 'this-is-gonna-be-fun', 'this-too-will-be-fun' ) for test in tests: print(test, '->', _fuzzy_search('this too fun', test)) ``` Result from test: ```py this-is-gonna-be-fun -> (30.0, 50, 50) this-too-will-be-fun -> (90.0, 62, 58) ```
| | | | | | | | | | | | * Fix linting errorGravatar kosayoda2019-10-28-2/+2
| | | | | | | | | | | | |
| | | | | | | | | | | | * Apply suggestions from code review Gravatar Kieran Siek2019-10-28-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix incorrect docstring and comment Co-Authored-By: Mark <[email protected]>
| | | | | | | | | | | | * Add delete emoji to paginationGravatar kosayoda2019-10-28-10/+21
| | | | | | | | | | | | |
| | | | | | | | | | | | * Revert "Remove dev-test limit for filtering debugging"Gravatar kosayoda2019-10-28-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 56696b3b1858ad27dc7f3dce2898c7a6eb151f43.
| | | | | | | | | | | | * Remove dev-test limit for filtering debuggingGravatar kosayoda2019-10-27-2/+2
| | | | | | | | | | | | |
| | | | | | | | | | | | * Differentiate clear and delete emoji in help cogGravatar kosayoda2019-10-27-10/+13
| | | | | | | | | | | | |
| | | | | | | | | | | | * Use trashcan emoji for message deletionGravatar kosayoda2019-10-27-1/+9
| |_|_|_|_|_|_|_|_|_|_|/ |/| | | | | | | | | | |
* | | | | | | | | | | | Prepend emoji indicative of success of !eval (#552)Gravatar scragly2019-10-24-1/+12
|\ \ \ \ \ \ \ \ \ \ \ \ | |_|_|_|/ / / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Prepend emoji indicative of success of !eval Co-authored-by: null <[email protected]>
| * | | | | | | | | | | Merge branch 'master' into eval-emojisGravatar scragly2019-10-24-1468/+2830
| |\ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / |/| | | | | | | | | | |
* | | | | | | | | | | | Merge pull request #547 from python-discord/#540-dont-show-infraction-totalGravatar Daniel Brown2019-10-22-3/+18
|\ \ \ \ \ \ \ \ \ \ \ \ | |_|_|/ / / / / / / / / |/| | | | | | | | | | | Don't show infraction total outside staff channels.
| * | | | | | | | | | | Show total infraction count only in staff channelsGravatar Akarys422019-10-21-1/+3
| | | | | | | | | | | |
| * | | | | | | | | | | Create STAFF_CHANNELS constantGravatar Akarys422019-10-21-2/+15
|/ / / / / / / / / / /
* | | | | | | | | | | Merge pull request #541 from ikuyarihS/masterGravatar S. Co12019-10-21-98/+54
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Fix defcon having wrong text when disabling.
| * \ \ \ \ \ \ \ \ \ \ Merge branch 'master' into masterGravatar S. Co12019-10-21-1276/+2468
| |\ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / |/| | | | | | | | | | |