| Commit message (Collapse) | Author | Age | Lines |
| |
|
|
|
| |
The tags need to be processed down the line,
which is not viable on strings.
|
| |
|
|
|
|
|
| |
By getting the signatures without the description we get more
flexibility of parsing different symbol groups and decouple the logic
from the description which can be parsed directly with the new
`find_elements_until_tag` based function.
|
| |
|
|
|
|
|
|
|
| |
Instead of returning None and multiple values, the method now
only returns the string of the description.
Previously the parsing returned None and quit
when appropriate tags for shortening the description
were not found, but the new implementation simply defaults to the
provided start tag if a better alternative is not found.
|
| |
|
|
|
|
|
|
| |
This will allow flexibility in the future when collecting tags
for the description and signature of symbols.
The base is a function which accepts a callable which is called and
iterated over, but 3 names with a partial function that has the callable
supplied are provided to keep the outside interface neater.
|
| |
|
|
| |
"read more" seemed out of place with no permalink over it.
|
| |
|
|
|
|
| |
The permalink serves no functional purpose in the embed,
as it is already included in the title. But it does
add the complexity of passing in the url to the parser.
|
| |
|
|
| |
Parser is a stdlib module name, a rename avoids shadowing it.
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
| |
Package names are now directly used for stats, where
the lowercase a-z characters and _ are used.
|
| |
|
|
|
|
| |
The commands were changed to be greedy, this however made them
required arguments breaking the access to the default listing
of the available inventories
|
| |
|
|
|
|
| |
The `set` command shadowed the `set` symbol, causing the command
to seemingly not work. A suffix was added to all commands to keep
them consistent and future proof; the shorthands were kept unchanged
|
| |
|
|
| |
The code block caused the url to not highlight the title text on mobile
|
| | |
|
| |
|
|
|
|
| |
Moving this part of the logic into a separate method allows us to put a cache on it,
which caches the whole HTML document from the given url,
removing the need to do requests to the same URL for every symbol behind it.
|
| | |
|
| | |
|
| |
|
|
|
| |
The converter does a web request so triggering typing in the command itself
left out a period where the bot seemed inactive.
|
| |
|
|
|
|
| |
An additional variable is added to the DocItem named tuple to accommodate this.
The `_package_name` is separated from `api_package_name` it previously overwrote and is now used
for the stats and renamed symbols because the names are in a friendlier format.
|
| | |
|
| | |
|
| |
|
|
| |
The previous approach didn't work for arbitrary tags with text.
|
| |
|
|
| |
This allows the user to wrap symbols in codeblocks to avoid markdown.
|
| | |
|
| | |
|
| |
|
|
|
|
| |
Before, when a symbol from the group shared the name with a symbol outside of it
the symbol was simply replaced and lost. The new implementation renames the old
symbols to the group_name.symbol format before the new symbol takes their place.
|
| | |
|
| |
|
|
| |
`find_all_text_until_tag` already returns a string so a join is not needed.
|
| | |
|
| |
|
|
| |
`find_next()` only goes to tags, leaving out text outside of them when parsing.
|
| |
|
|
|
|
|
|
| |
When parsing classes, methods would sometimes get included
causing bad looking markdown to be included in the description,
this is solved by collecting all text *up to* the next dt tag.
fixes: #990
|
| | |
|
| |
|
|
|
|
| |
The symbols mostly point to autogenerated pages, and do not link
to specific symbols on their pages and are thus unreachable with
the current implementation.
|
| |
|
|
| |
This allows us to find docs for symbols with spaces in them.
|
| |
|
|
|
|
| |
Most docs will use relative urls to link across their pages,
without resolving them ourselves the links remain unusable in discord's
markdown and break out of codeblocks on mobile.
|
| |\
| |
| | |
Add tests for the antimalware cog
|
| | |\
| |/
|/| |
|
| |\ \
| | |
| | | |
Specify encoding when reading tag files
|
| |/ /
| |
| |
| |
| |
| |
| |
| | |
Not all operating systems use UTF-8 as the default encoding. For systems
that don't, reading tag files with Unicode would cause an unhandled
exception.
(cherry picked from commit adc75ff9bbcf8b905bd78c78f253522ae5e42fc3)
|
| |\ \
| | |
| | | |
Ignore response when posting python news
|
| | |\ \
| |/ /
|/| | |
|
| |\ \ \ |
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Discord has introduced a new, strict rate limit for individual channel
edits that reduces the number of allow channel name/channel topic
changes to 2 per 10 minutes per channel.
Unfortunately, our help channel system frequently goes over that rate
limit as it edits the name and topic of a channel on all three "move"
actions we have: to available, to occupied, and to dormant. In addition,
our "unanswered" feature adds another channel name change on top of
the move-related edits.
That's why I've removed the topic/emoji changing features from the help
channel system. This means we now have a generic topic that fits all
three categories and no status emojis in the channel names.
|
| |/ / /
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The `check_for_answer` method of the HelpChannels cog relies on the
channel->claimant cache being available. However, as this cache is
(currently) lost during bot restarts, this method may fail with a
KeyError exception.
I've used `dict.get` with an `if not claimant: return` to circumvent
this issue.
|
| |/ /
| |
| | |
Sometimes a mailing list user doesn't press respond correctly to the email, and so a response is sent as a separate thread. To keep only new threads in the channel, we need to ignore those.
|
| |\ \
| | |
| | | |
RedisCache - Data Persistence
|