Releases: CXuesong/WikiClientLibrary
Releases · CXuesong/WikiClientLibrary
v0.6-int4
This version has a bug that is fixed in the next pre-release. This version of NuGet package has been unlisted.
If you have any questions or suggestions, feel free to open an issue :-)
New features
- Added two page generators:
BacklinksGenerator
andTranscludedInGenerator
. - MW API requests via
WikiSite.GetJsonAsync
will automatically attempt to re-fetch tokens onbadtoken
error. (#21)
Major interface changes
- Renamed
PageGenerator
toWikiPageGenerator
, andRecentChangesEntry
toRecentChangeItem
. IWikiClientLoggable.SetLoggerFactory
has been replaced with a R/W propertyIWikiClientLoggable.LoggerFactory
.UnauthorizedOperationException
is now a subclass ofOperationFailedException
.- Though for certain locally detected authorization failure,
UnauthorizedOperationException.ErrorCode
will benull
.
- Though for certain locally detected authorization failure,
- Added
WikiRequestMessage
class to contain query parameters.- This class (
WikiFormRequestMessage
, to be more exact) unifiesapplication/x-www-form-urlencoded
andmultipart/form-data
, while enables per request configurations in the future, and a better request-tracing experience. WikiClient.GetJsonAsync
now only acceptsWikiRequestMessage
.WikiSite.PostValuesAsync
is kept for now but is marked as obsolete. It will be removed in the next pre-release. You need to useWikiSite.GetJsonAsync
now. (See usage example.)- See the documentation of
WikiFormRequestMessage
for more information.
- This class (
Bug fix
- Fixed incorrect logic for getting
patrol
token for MW [1.17, 1.20). - Fixed some incorrect logging emissions.
Other changes
- Re-implemented
WikiSite.GetToken(s)Async
. Still the code might need more simplifications.
Unit tests
- Use MSTest adapter for xUnit. Now you can execute unit tests with VS.
- Added xUnit console runner
dotnet-xunit
. Now you can execute unit tests withdotnet xunit
command. - Now the unit test is net452/netcoreapp2.0 multi-targeted.
- Thanks to AArnott, again. Now I have
XUnit.SkippableFact
to take over the originalUnitTestProject1.Utility.Inconclusive
method. (I'm also a fan ofNerdbank.FullDuplexStream
!)
v0.6-int3
New features
- Assume
File:
namespace by default in FilePage.UploadAsyncInternal. (#17)
API changes
- Renamed
PageExtensions
toWikiPageExtensions
. - Removed
PageGeneratorBase.ActualPagingSize
. - Use
Microsoft.Extensions.Logging
for logging; removedWikiClientLibrary.ILogger
. (#14)
Bug fix
- Fixed the letter case of key for
PagePropertyCollection.DisplayTitle
. (633852b)
v0.6-int2
v0.6-int1
v0.6-int0
Bug fix / New features
FilePage.UploadAsync
now supports retry. (#8)- Moved throttling logic from
WikiClient
toWikiSite
- Added a
Throttler
class responsible for the request queuing. - Now throttling supports parallel (edit/move/delete) requests. (#9)
- Added a
- Changed
ContentSectionInfo.Index
fromint
tostring
type. (8e1ab82)- Titles in transcluded templates may have an index of "T-1", "T-2", etc.
- Added
Page.IsSpecialPage
property. (3f52a26)
Major interface changes
Some major API changes (basically changes of names, see #12) are to be involved in v0.6. The changes as listed below are still not complete yet, which will be applied in future pre-releases.
- Moved classes in
WikiClientLibrary
root namespace to the following namespacesWikiClientLibrary.Infrastructures
WikiClientLibrary.Pages
WikiClientLibrary.Sites
- Renamed
WikiClientLibrary.Site
toWikiClientLibrary.Sites.WikiSite
0.5.1
0.5.0
- Add language variant support in
Site.Parse
methods. - Bug fix:
ParsedContentInfo.Interlanguages
is always null. - Do not cache messages in
Site.GetMessagesAsync
. Site.GetTokensAsync
will wait for ongoing token fetching tasks before fetching for tokens.- Before this version, two simultaneous
GetTokensAsync
call for a same token will cause MW API be called twice.
- Before this version, two simultaneous