aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeLines
...
* Aiohttp fixes (#27)Gravatar Gareth Coles2018-03-10-79/+71
| | | | | | | | | | * Attempt to fix issues with aiohttp spawning way too many threads * Add aiodns to requirements * Math doesn't work for me `Fatal Python error: failed to get random numbers to initialize Python`
* Commenting out the codeblocks detection code, it appears to be interfering ↵Gravatar Leon Sandøy2018-03-08-3/+5
| | | | with self.accept()
* Improving autocodeblocks (#23)Gravatar Henrik Böving2018-03-08-38/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * adding better detection for misformatted python code, using the tags api instead of hardcoded hints and mentioning the user in the hint * use a seperate string instead of msg.content * Better comments and formatting Own function for codeblock stripping splitlines instead of split("\n"), because of readability re.search instead of re.match, because re.match is too strict if content.lower().startswith("python") instead of case sensitive checking, because of readabilty Reformatted hint * More readability Changed hint sentence More descriptive variables * Even more descriptive variable names Fixed small cooldown bug * forgot to save descriptive variable names * i dont believe this * typo at import * reworked getting the tag, not sure if it works * fixed old code * oversaw one * reworked the howto again better stripping * making the hint look better * get_tag_data returns a dict ==> change .description to ['tag_content'] * if the codeblcok tag isnt found do nothing * reformat of hint * removed not needed f * more changes to the hint * lemon lied about fstrings * order of arguments * formatting * logic error * more foooormatting and a debug note * linter... * still blank
* how do I keep forgetting the api. partGravatar Leon Sandøy2018-03-07-2/+2
|
* Actually let's do SITE_URL.Gravatar Leon Sandøy2018-03-07-4/+4
|
* Oops. Forgot a bit.Gravatar Leon Sandøy2018-03-07-1/+1
|
* environment variable created, setting API constants dynamic.Gravatar Leon Sandøy2018-03-07-5/+4
|
* Python syntax method calls (#24)Gravatar Leon Sandøy2018-03-07-16/+69
| | | | | | | | | | | | * Tested on Bot Staging, appears to work just fine. Probably needs more testing to be sure. * Added some documentation to the python syntax overrides, and fixed various bugs with the current implementation. They also support single quotes now. * Solved all single and double quote issues, most use cases should work now. Tested quite a bit, but could probably stand a little more testing. * forgot a local testing environment * Switched parse method from regex (what was I thinking) to ast.literal_eval
* breaking bug discovered, missing env var. Quick temporary fix.Gravatar Leon Sandøy2018-03-06-1/+2
|
* Added first / last buttons and max_lines to pagination (#25)Gravatar Runew0lf2018-03-06-137/+248
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Added first / last buttons and max_lines to pagination * Monkey patching methods instead of adding a whole class for pagination lines * Fixed linting errors * Refactored to subclass instead of monkey patching * updated clickup and tags to work with the new subclass * Included pagination.py * Fixed linter issues in pagination.py * Fixed out of scope in __init__.py. Changed pagination to remove an error that can sometimes be caused with pagination * Changed cogs.py to use the new LinePaginator.paginate * Changed line_size to max_lines * Changed readability of the conditions in even_check * Corrected bracketing mistake * Corrected flake8 issues
* Run latexify and calc in a secure subprocess (#26)Gravatar martmists2018-03-06-27/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Update math.py Some annoying whitespace left over from the mobile GitHub editor probably * Update math.py * Finally fix this * Update math.py * Documentation * Un-inline some comments * Capitals and trailing spaces * Fix comment position * Reorder Popen * Fix floating comments I guess * Fix bandit Signed-off-by: Martmists <[email protected]>
* gotta use http for local api requests. Also removed snekrc.Gravatar Leon Sandøy2018-03-06-8/+3
|
* cleaning up constants.py for readability and because I need dynamic API URLs ↵Gravatar Leon Sandøy2018-03-06-8/+11
| | | | for local testing, I need them in my life.
* math broke the bot, redeploying without mathGravatar Leon Sandøy2018-03-04-1/+1
|
* Non-alpha tag names no longer allowed.Gravatar Leon Sandøy2018-03-04-0/+4
|
* Discord.py doesn't support Union type annotations on commands, had to remove ↵Gravatar Leon Sandøy2018-03-04-4/+3
| | | | them.
* Add docstrings for math commandsGravatar Gareth Coles2018-03-03-0/+10
|
* Add cog for turning math expressions into LaTeX (#18)Gravatar martmists2018-03-03-0/+103
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add cog for turning math expressions into LaTeX Note that this does NOT require eval, and does NOT evaluate the expression, and is therefore 100% safe * Fix whitespace * Fix import order Signed-off-by: Martmists <[email protected]> * Enable loading of math cog Signed-off-by: Martmists <[email protected]> * Change size from 300 to 150 * Fix requested issues Signed-off-by: Martmists <[email protected]> * forgot setup() Signed-off-by: Martmists <[email protected]> * Fix spaces being ignored Signed-off-by: Martmists <[email protected]> * Use latex2png instead Signed-off-by: Martmists <[email protected]> * Allow ` to be used in expressions to not make it look odd Signed-off-by: Martmists <[email protected]> * Add safe calc Signed-off-by: Martmists <[email protected]> * Fix flake8 Signed-off-by: Martmists <[email protected]> * Update math.py * Fix Signed-off-by: Martmists <[email protected]>
* Tag feature (#21)Gravatar Leon Sandøy2018-03-02-1/+268
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * [WIP] get_tag() * [WIP] get_tag() * [WIP] get_tag() * [WIP] - tags * [WIP] renamed to docs, tested and verified get and set commands, still need to add cooldowns and delete. * [WIP] get_tag() * [WIP] get_tag() * [WIP] get_tag() * [WIP] - tags * [WIP] renamed to docs, tested and verified get and set commands, still need to add cooldowns and delete. * removed the tag.py file * Refactoring docs to tags * [WIP] polish for the tags bot feature * Added pagination, lots of output polish, input sanitization * seperated out the the API interaction so it can be accessed from other cogs. Added a ton of polish, better documentation, and a help function if you just type bot.tags(). The core functionality should be done now, just missing the cooldown decorator. * Cooldown system per command per channel. Some annotations. Ready for PR! * oops, had left local url in. * removing some out of scope stuff * Using API key from constants * Replacing Union[str, None] with Optional[str] * adding some namespaceless commands * inverting some conditionals with returns in them. * removing some mysterious commas, and adding better error messages if the database operation fails * adhering to the standard set in clickup cog to prevent shadowing. * alphabetized cog load block, moved headers into a class attribute, and fixed punctuation consistency issues.
* adds vagrant file (#14)Gravatar Christopher Baklid2018-03-02-0/+43
| | | | | | * adds vagrant file * reduce memory allocation
* Switch from replace to something elseGravatar JoeBanks132018-03-02-2/+2
|
* Actually syntax highlight the syntax highlight instruction codeGravatar JoeBanks132018-03-02-1/+1
|
* Stop single tick multi line formattingGravatar JoeBanks132018-03-02-0/+4
|
* Cog management #1404e (#19)Gravatar Gareth Coles2018-03-02-1/+275
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Some work towards cog management commands * Constants for chevron emoji * Cogs module should use chevron emoji * Cog reloading command * Small cleanup * Cogs cog is always loaded * Changes for Aperture * Changes for Lemon * Linting * Linting * Make lemon more comfortable * Ability to reload all cogs * Fix format string * Allow reload of cog management cog
* Adding annotations and making things more beautiful in __init__.pyGravatar Leon Sandøy2018-03-02-6/+10
|
* Switching CI linter from snekchek to flake8Gravatar Leon Sandøy2018-03-02-7/+4
|
* Constants for chevron emojiGravatar Gareth Coles2018-02-28-1/+6
|
* [Travis] Only build on masterGravatar Gareth Coles2018-02-27-0/+4
|
* Fix paginator footer display and allow extra footer textGravatar Gareth Coles2018-02-27-7/+26
| | | | | #15b9v: Extend paginator to support extra footer text #15bdr: Fix paginator not showing footer on first page
* Removed cooldown for devtest, fixed typo (#17)Gravatar Jeremiah Boby2018-02-26-2/+2
|
* Patched the grievous error we overlooked (#16)Gravatar Jeremiah Boby2018-02-26-9/+12
| | | | | | | | | | | | | | • Patched the grievous error we overlooked • Past time must be subtracted from current time for cooldowns • Added `DEVTEST_CHANNEL` to constants • Renamed previous times variable, added devtest • Reordered imports to satisfy Travis • For God's sake, Travis
* Adding autocodeblocking (#15)Gravatar Henrik Böving2018-02-26-2/+48
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * autocodeblocking * ast fix better type annotations * ci there you go * line too long ==> remove comment * deleting message + lowercase python * comments * remove docstrings * you may * not sure what you mean with move to a new line maybe this? * descriptive enough? * better explanation of text filtering * rewrite * fstring * pep8 * better comment * discord message length * ok shady * ok shady * "This is still async discord.py" * didnt see josephs comment * minor comment changes * blank and typo * typo.. * embed sending * adding waiting time + embed dont know if this is the correct way to store the field string * forgot await * but now i know * i heard him * pls * more descriptive variable name * comment * and better string formatting * approve me lemon * here we go aperture * there we go again * name error..... damn linter plugins * you get it aperture * ok lemon * ok aperture * constants instead of plain channel ID * forgot one * constants in bot.py * lemons way ftw * flake8 is weird man * aperture 1 * next aperture * dunno * imports * next lemon
* Fixed formatter.py #1rhpqGravatar Sam Wedgwood2018-02-21-3/+24
| | | | | | - fixed multiline docstrings - added newline after docstring - changed full modulename.classname in type hints to only classname - fixed the format of the arguments to do_<command>
* Clickup commands #z20f (#10)Gravatar Gareth Coles2018-02-20-6/+462
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Initial work on ClickUp cog * More listing commands * Fix stray square bracket * Need to await json() calls * Fix tasks call * Fix lists call * list -> task_list * Better error handling and _way_ better tasks command * Pagination convenience function * Pagination for the tasks command * Small fixes * Pagination only paginates with more than one page * Grab lists on startup; use strings for list in tasks command * Provide some embed colours * Clean up embed instantiation a bit * Don't show paginated page number when there's only one page * Finish up ClickUp commands * Update command documentation * Move a comment @Aperture * Fixes for Lemon's review
* Martmists: Fancier IPython-like eval command (#3)Gravatar martmists2018-02-16-48/+166
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Fancier IPython-like eval command - Supports Embeds - Pretty-prints - Shortens - Supports catching stdout * Cache pip to speed up travis in the future * Fix snekchek * Update eval.py * Re-order imports * Comply with mentioned issues * Fix travis * Conform to requested edits * Fix travis again * Update eval.py
* Update `deploy_site` docstringGravatar Gareth Coles2018-02-16-1/+1
|
* Update `redeploy` docstringGravatar Gareth Coles2018-02-16-1/+1
|
* Automatically close aiohttp sessionGravatar Gareth Coles2018-02-16-9/+6
|
* Better output on_ready with role updatesGravatar Gareth Coles2018-02-16-6/+18
|
* Supply correct header nameGravatar Gareth Coles2018-02-16-1/+1
|
* snekchekGravatar Gareth Coles2018-02-16-4/+3
|
* Synchronise roles to the site.Gravatar Gareth Coles2018-02-16-0/+83
| | | | There might be a better way, I just wanted to get this working since it's a blocker.
* Fun cog, limited to the bot channel.Gravatar Gareth Coles2018-02-16-0/+51
| | | | This stuff isn't important. Just easter eggs and fun. But don't make super annoying stuff, please.
* Connected embed (#8)Gravatar Sam Wedgwood2018-02-15-1/+10
| | | Literally just changes the "Connected!" message to an embed so it looks a bit nicer, and the little added bonus that you can click on the Python Bot and it will send you to the bot's repo.
* Give Inver access to chatops.Gravatar Gareth Coles2018-02-15-6/+7
| | | | Also, snekchek.
* Fix object iterationGravatar Gareth Coles2018-02-15-1/+1
|
* Fix silly equality checkGravatar Gareth Coles2018-02-15-3/+5
|
* Actually parse the JSON correctlyGravatar Gareth Coles2018-02-15-1/+3
|
* Merge remote-tracking branch 'origin/master'Gravatar Gareth Coles2018-02-15-3/+110
|\ | | | | | | | | # Conflicts: # bot/constants.py
| * Merge pull request #7 from discord-python/help-formatterGravatar Sam Wedgwood2018-02-13-1/+107
| |\ | | | | | | new HelpFormatter added #1pv7x