aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeLines
* Restructure doc cache to handle caches of whole pagesGravatar Numerlor2020-12-11-61/+37
| | | | | | | | | | | | | | | Previously we used packages as the top level keys and fields contained the url and the symbol id, however if we want to store all symbols from fetched pages instead of only the ones that were fetched by the users this comes worse off than using the page url in the field and setting EXPIREs for them instead of doing it manually in python. The new implementation uses package:url as the redis key and only the symbol id for field names, with the expire being set to a week on the key, this means we have to pattern match the keys when deleting the cache for a package but that's being done far less than the expire checking done previously.
* Create a generator instead of returning a listGravatar Numerlor2020-12-09-6/+4
| | | | | | The result of _split_parameters is only iterated over, so a list is not needed. Making it lazy may also save some time in cases where we don't use all parameters
* Merge current_search and expected_end inGravatar Numerlor2020-12-09-10/+11
| | | | | The two variables were initialized and cleared together and contained related information
* Improve handling of stringsGravatar Numerlor2020-12-09-7/+28
| | | | | | | Previously the code assumed ' and " can be used interchangeably, and strings that were inside of brackets were ignored for depth but their contents weren't causing strings like "ab[cd" to increase the depth
* Remove redundant suppressGravatar Numerlor2020-11-29-2/+2
|
* Various grammar and sentence structure changesGravatar Numerlor2020-11-29-13/+14
| | | | Co-authored-by: MarkKoz <[email protected]>
* Clear up docstring so it doesn't rely on private attributeGravatar Numerlor2020-11-29-1/+1
| | | | Co-authored-by: MarkKoz <[email protected]>
* Use pop instead of getitem and delGravatar Numerlor2020-11-29-2/+1
| | | | Co-authored-by: MarkKoz <[email protected]>
* Use timedelta instead of constructing duration manuallyGravatar Numerlor2020-11-29-2/+3
| | | | | A newline was also added to set to keep it consistent with set_if_exists
* Ensure packages from PRIORITY_PACKAGES are directly accessibleGravatar Numerlor2020-11-15-0/+7
| | | | | | | Some packages (currently only python) should be prioritised to others, the previous cleanup didn't account for other packages loading before it which resulted in duplicate symbols getting the python prefix and the original symbols linking to most probably undesired pages
* Add command for clearing the cache of packagesGravatar Numerlor2020-11-15-0/+8
| | | | We also clear the cache when removing a package
* Update existing redis values when parsing pagesGravatar Numerlor2020-11-15-6/+25
| | | | | | If we're parsing a page for a symbol that's out of the cache and encounter a symbol that was already cached we can update that symbol to keep it up to date without additional requests
* Rework the doc redis cache to work with hashesGravatar Numerlor2020-11-15-12/+56
| | | | | | | | This rework requires us to delete packages caches easily with deleting the package hash instead of having to pattern match all keys and delete those. The interface was also updated to accept DocItems instead of requiring callers to construct the keys
* Limit newlines in doc descriptionsGravatar Numerlor2020-11-15-16/+32
|
* Intern relative url pathsGravatar Numerlor2020-11-15-4/+9
| | | | | Group name interning was also moved to the DocItem creation to group the behaviour
* Cancel scheduled inventory updates on all refreshesGravatar Numerlor2020-11-15-6/+2
|
* Adjust unparseable symbol behaviourGravatar Numerlor2020-11-15-3/+6
| | | | | | | With redis we need to make sure we don't send the "error" string into the cache, returning None instead of the string and then setting it manually in the caller makes this nicer compared to checking against a string
* Update outdated docstringGravatar Numerlor2020-11-15-1/+1
|
* Rename variables for clarityGravatar Numerlor2020-11-15-11/+11
|
* Generalise tag filter hint to accept all containersGravatar Numerlor2020-11-10-5/+5
|
* Relock Pipfile.lockGravatar Numerlor2020-11-10-298/+136
|
* Merge remote-tracking branch 'upstream/master' into doc-impGravatar Numerlor2020-11-10-782/+2177
|\ | | | | | | | | | | # Conflicts: # LICENSE-THIRD-PARTY # bot/exts/info/doc.py
| * Merge pull request #1273 from ↵Gravatar Dennis Pham2020-11-08-1/+1
| |\ | | | | | | | | | | | | python-discord/sebastiaan/bugs/codeblock-language-detection Detect codeblock language specifiers with special characters
| | * Merge branch 'master' into sebastiaan/bugs/codeblock-language-detectionGravatar Dennis Pham2020-11-08-1/+5
| | |\ | | |/ | |/|
| * | Merge pull request #1148 from Jack92829/masterGravatar Senjan212020-11-07-0/+3
| |\ \ | | | | | | | | New guilds tag
| | * | Update guilds.mdGravatar Jack928292020-09-29-3/+2
| | | | | | | | | | | | Not to sure of the title to give it but I think the content is a bit more in line with the servers other tags
| | * | Update guilds.mdGravatar Jack928292020-09-26-4/+3
| | | |
| | * | Merge branch 'master' into masterGravatar Matteo Bertucci2020-09-23-2462/+2436
| | |\ \
| | * | | Update guilds.mdGravatar Jack928292020-09-06-1/+1
| | | | |
| | * | | Update and rename ServersTag.md to guilds.mdGravatar Jack928292020-09-06-5/+5
| | | | |
| | * | | Add files via uploadGravatar Jack928292020-09-06-0/+5
| | | | |
| * | | | Merge pull request #1219 from python-discord/bug/ci/cache-continue-on-errorGravatar Senjan212020-11-07-1/+2
| |\ \ \ \ | | | | | | | | | | | | CI: avoid failing whole job if a cache task fails
| | * | | | CI: avoid failing whole job if a cache task failsGravatar MarkKoz2020-10-06-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Restoring from cache is non-critical. The CI can recover if cache tasks fail.
| | | | | * Detect codeblock language with special charactersGravatar Sebastiaan Zeeff2020-11-06-1/+1
| | |_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The regex we use to detect codeblocks did not recognize language specifiers that use a dash, a plus, or a dot in their name. As there are valid language specifiers, such as python-repl and c++, that use those characters, I've changed the regex to reflect that. The character set used now reflects the characters used in language specifiers in highlight.js. Signed-off-by: Sebastiaan Zeeff <[email protected]>
| * | | | Merge pull request #1271 from spacecraft1013/code_instructionsGravatar Dennis Pham2020-11-06-2/+2
| |\ \ \ \ | | | | | | | | | | | | ```py convention in code block instructions
| | * \ \ \ Merge branch 'master' into code_instructionsGravatar Dennis Pham2020-11-06-105/+169
| | |\ \ \ \ | | |/ / / / | |/| | | |
| * | | | | Merge pull request #1266 from zachgates/patch-1Gravatar Senjan212020-11-06-1/+1
| |\ \ \ \ \ | | | | | | | | | | | | | | Updated langs to include python-repl
| | * | | | | Reinsert python-repl in PY_LANG_CODESGravatar Zach Gates2020-11-01-1/+1
| | | | | | |
| | * | | | | Updated langs to include python-replGravatar Zach Gates2020-11-01-1/+1
| | | | | | |
| * | | | | | Merge pull request #901 from ks129/pep-improvisationsGravatar Senjan212020-11-05-104/+168
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | PEP command improvements
| | * | | | | | Fix argument offsetGravatar ks1292020-10-18-1/+1
| | | | | | | |
| | * | | | | | Refactor PEP error embed sendingGravatar ks1292020-10-18-23/+24
| | | | | | | |
| | * | | | | | Merge remote-tracking branch 'up/master' into pep-improvisationsGravatar ks1292020-10-18-642/+1078
| | |\ \ \ \ \ \
| | * \ \ \ \ \ \ Merge branch 'master' into pep-improvisationsGravatar ks1292020-10-04-943/+553
| | |\ \ \ \ \ \ \
| | * | | | | | | | Move AsyncCache max_size argument to __init__ from decoratorGravatar ks1292020-10-04-3/+4
| | | | | | | | | |
| | * | | | | | | | Make AsyncCache key tuple instead stringGravatar ks1292020-10-04-1/+1
| | | | | | | | | |
| | * | | | | | | | Move PEP URLs to class constantsGravatar ks1292020-10-04-7/+6
| | | | | | | | | |
| | * | | | | | | | Rename async cache instancesGravatar ks1292020-10-04-7/+5
| | | | | | | | | |
| | * | | | | | | | Fix lintingGravatar ks1292020-09-26-3/+2
| | | | | | | | | |
| | * | | | | | | | PEP: Split get_pep_embed to smaller partsGravatar ks1292020-09-26-22/+34
| | | | | | | | | |