aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeLines
* PR #1157 Reddit: filter NSFW postsGravatar kwzrd2020-10-17-3/+5
|\
| * Merge branch 'master' into filter_redditGravatar Rohan Reddy Alleti2020-10-14-1499/+1270
| |\
| * | re-add comment.Gravatar RohanJnr2020-10-01-1/+1
| | |
| * | handling empty list error in get_top_posts() method and filter posts using ↵Gravatar RohanJnr2020-10-01-23/+9
| | | | | | | | | | | | list comprehension.
| * | Filter out reddit posts which are meant for users 18 years of older and send ↵Gravatar RohanJnr2020-09-28-1/+6
| | | | | | | | | | | | the rest.
| * | Merge remote-tracking branch 'upstream/master' into filter_redditGravatar RohanJnr2020-09-22-2042/+1427
| |\ \
| * | | Restrict nsfw subreddit(s) or similar (subreddits that require you to be ↵Gravatar rohanjnr2020-09-15-7/+18
| | | | | | | | | | | | | | | | | | | | | | | | over 18). Changed the return format a little bit for the fetch_posts() function, instead of returning an empty list, it returns a list with a dict holding the error message.
* | | | Merge pull request #1242 from ↵Gravatar Sebastiaan Zeeff2020-10-17-4/+12
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | python-discord/sebastiaan/features/whitelister-sprinters Whitelist Core Dev Sprinters from our filters
| * | | | Use filter role whitelist for all filter featuresGravatar Sebastiaan Zeeff2020-10-17-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We were using different whitelists for different filters, making it slightly more difficult to maintain the role whitelists. They now all use the same list, which combines our staff roles with the Python community role and the sprinters role. Signed-off-by: Sebastiaan Zeeff <[email protected]>
| * | | | Add sprinters role to filter whitelistGravatar Sebastiaan Zeeff2020-10-17-0/+9
|/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I've added the sprinters role to the filter whitelist. This will not affect antispam and antimalware just yet, as they currently default to using the STAFF_ROLES constant. I've also kaizened the config-default.yml file by ensuring there are two linebreaks between all sections. Signed-off-by: Sebastiaan Zeeff <[email protected]>
* | | | PR #1233 Verification: add note to kicked membersGravatar kwzrd2020-10-17-0/+24
|\ \ \ \
| * | | | Verification: avoid logging whole kick note payloadGravatar kwzrd2020-10-17-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Only the `member` is variable, no need to log the rest. Co-authored-by: Numerlor <[email protected]>
| * | | | Verification: simplify kick note reasonGravatar kwzrd2020-10-15-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | This will make it much easier to filter out verification kicks when querying the infraction database.
| * | | | Verification: add notes to kicked usersGravatar kwzrd2020-10-13-0/+1
| | | | |
| * | | | Verification: implement kick note post helperGravatar kwzrd2020-10-13-0/+23
| | | | |
* | | | | Snekbox: raise paste character lengthGravatar MarkKoz2020-10-15-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It doesn't make sense for it to be at 1000 when the code gets truncated to 1000 as well. Fixes #1239
* | | | | Code block: fix _fix_indentation failing for line counts of 1Gravatar MarkKoz2020-10-14-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This could be reproduced by editing a tracked message to a single line of invalid Python that lacks any back ticks. The code was assuming there would be multiple lines because that's what the default value for the threshold is, but this threshold is not applied to edited messages. Fixes BOT-A5
* | | | | Merge pull request #886 from ↵Gravatar Mark2020-10-14-357/+733
|\ \ \ \ \ | |_|_|_|/ |/| | | | | | | | | | | | | | python-discord/bug/utility/829/non-py-code-detection Code block detection rewrite
| * | | | Utils: clarify why has_lines counts by splitting by newlinesGravatar MarkKoz2020-10-14-0/+1
| | | | |
| * | | | Merge master and fix conflictsGravatar MarkKoz2020-10-05-3820/+3457
| |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Use absolute imports in the code block modules for consistency * Move has_lines utility function into the helpers module * Prefix names of code block modules with underscores so they won't get picked up as extensions by the extension manager
| * | | | | Code block: support the "pycon" language specifierGravatar MarkKoz2020-10-05-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | It's used for code copied from the Python REPL.
| * | | | | Fix conflict for webhook token check in code block detectionGravatar MarkKoz2020-09-09-604/+203
| |\ \ \ \ \
| * | | | | | Code block: make _get_leading_spaces more readableGravatar MarkKoz2020-08-25-7/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | A for loop is less confusing according to reviews.
| * | | | | | Stats: use the is_in_category util functionGravatar MarkKoz2020-08-25-2/+2
| | | | | | |
| * | | | | | Use category_id attribute in is_in_categoryGravatar MarkKoz2020-08-25-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Simplify the code by removing the need to check if the category is None.
| * | | | | | Code block: fix conflict with wait_for_deletion argsGravatar MarkKoz2020-08-23-161/+264
| |\ \ \ \ \ \
| * | | | | | | Code block: clarify that the original message can be editedGravatar MarkKoz2020-08-23-6/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix #497
| * | | | | | | HelpChannels: fix conflict with pin functionsGravatar MarkKoz2020-08-08-1127/+3763
| |\ \ \ \ \ \ \
| * | | | | | | | Code block: dedent code before validating itGravatar MarkKoz2020-06-28-4/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If it's indented too far, the AST parser will fail.
| * | | | | | | | Code block: re-add indentation fixing functionGravatar MarkKoz2020-06-28-0/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's still useful to fix indentation to ensure AST is correctly parsed. This function deals with the relatively common case of a the leading spaces of the first line being left out when copy-pasting.
| * | | | | | | | Code block: support IPython REPL detectionGravatar MarkKoz2020-06-27-6/+53
| | | | | | | | |
| * | | | | | | | Code block: fix BadLanguage creationGravatar MarkKoz2020-06-27-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Forgot to change the kwarg names when the attributes were renamed.
| * | | | | | | | HelpChannels: fix is_in_category callGravatar MarkKoz2020-06-27-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It was still using it like it was a method of the class rather than calling it from the channel utils module.
| * | | | | | | | Code block: clarify get_instructions's docstringGravatar MarkKoz2020-06-27-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It wasn't clear that it also parses the message content.
| * | | | | | | | Code block: simplify channel cooldown dict creationGravatar MarkKoz2020-06-27-1/+1
| | | | | | | | |
| * | | | | | | | Code block: use config constant for cooldownGravatar MarkKoz2020-06-27-2/+4
| | | | | | | | |
| * | | | | | | | Code block: make PY_LANG_CODES more visibleGravatar MarkKoz2020-06-27-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The declaration was a bit hidden between the two regular expressions.
| * | | | | | | | Code block: rename BadLanguage attributesGravatar MarkKoz2020-06-27-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `has_` prefix it clarifies that they're booleans. Co-authored-by: Numerlor <[email protected]>
| * | | | | | | | Merge remote-tracking branch 'origin/master' into ↵Gravatar MarkKoz2020-06-22-133/+469
| |\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | bug/utility/829/non-py-code-detection
| * | | | | | | | | Code block: remove needless f-stringsGravatar MarkKoz2020-06-14-3/+3
| | | | | | | | | |
| * | | | | | | | | Code block: add statsGravatar MarkKoz2020-06-14-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Increment `codeblock_corrections` when instructions are sent * Import our Bot subclass instead of discord.py's
| * | | | | | | | | Code block: simplify retrieval of channel ID from payloadGravatar MarkKoz2020-06-14-1/+1
| | | | | | | | | |
| * | | | | | | | | Code block: add configurable variablesGravatar MarkKoz2020-06-13-21/+41
| | | | | | | | | |
| * | | | | | | | | Create a utility function to count lines in a stringGravatar MarkKoz2020-06-13-2/+13
| | | | | | | | | |
| * | | | | | | | | Code block: adjust logging levelsGravatar MarkKoz2020-06-13-4/+4
| | | | | | | | | |
| * | | | | | | | | Code block: fix missing newline before generic exampleGravatar MarkKoz2020-06-13-1/+1
| | | | | | | | | |
| * | | | | | | | | Move some functions into a new channel utility moduleGravatar MarkKoz2020-06-13-37/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Change `is_help_channel` to`internally use `is_in_category`
| * | | | | | | | | Code block: document the cogGravatar MarkKoz2020-06-13-7/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add docstrings for modules * Rephrase some docstrings and comments * Fix the grammar of some comments
| * | | | | | | | | Code block: fix wrong message shown for bad ticks with a valid languageGravatar MarkKoz2020-06-13-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the code block had invalid ticks, instructions for syntax highlighting were being shown despite the code block having a valid language.
| * | | | | | | | | Code block: don't return bad language instructions if nothing's wrongGravatar MarkKoz2020-06-13-14/+19
| | | | | | | | | |