Open rwv37 opened 2 years ago
Please do not inherit from WikiPage
class. This class is not intended to be derived unless you know what you are doing.
Also, this class does not take care of Special
pages. Please use QueryPageGenerator
.EnumItemsAsync
if you want to query for WantedPages
.
I'm not sure that I understand your comment about special pages. Like I said: "I received (from the QueryPageGenerator for Wantedpages) a WikiPage object with the title WP:Namespace".
The problem occurred when I then passed that WikiPage object (call it "wp" for the sake of example) to (essentially) new WikiPage(wp.site, wp.title)
.
I have the following class:
It (and other classes like it) have been working fine for me for a while now, but I just found a problem where my program hangs, apparently during the call to the base constructor.
Specifically, I received (from the
QueryPageGenerator
for Wantedpages) aWikiPage
object with the titleWP:Namespace
. One thing that I think might be important to note at this point: I previously added an interwiki to my site to direct "WP:xxxx" to (wikipedia)/WP:xxxx".Anyway, I fed that
WikiPage
to myWantedPage
classes constructor, and it seems to hang there indefinitely: If I stick this...Log.Error($"Made wanted page {this.Title} from wiki page {wikiPage.Title}!");
... inside of the body of the constructor, the log message never happens (for WP:Namespace; it does happen for all titles I've encountered).
Now that I've figured out that this is apparently where my program is hanging, I'll be able to work around it without much trouble, but I wanted to report the bug anyway.