Browse Source

fix #30, among other things

George S. Baugh 4 years ago
parent
commit
41da7a9c76
4 changed files with 18 additions and 1 deletions
  1. 4 0
      Changes
  2. 5 0
      README.md
  3. 1 1
      dist.ini
  4. 8 0
      lib/Playwright.pm

+ 4 - 0
Changes

@@ -1,5 +1,9 @@
 Revision history for Playwright
 
+0.006 2021-04-12 TEODESIAN
+    - Prevent $? from bubbling up in our destructor and invalidating program exit code by localizing $? in quit()
+    - Add a link to the Playwright slack in the documentation.
+
 0.005 2021-03-24 TEODESIAN
     [BUG FIXES]
     - Prevent double destroy in the event of quit() being called

+ 5 - 0
README.md

@@ -49,3 +49,8 @@ dzil listdeps --missing | sudo cpanm
 Actually running stuff:
 
 `perl -Ilib example.pl`
+
+## Questions?
+Hop into the playwright slack, and check out the #playwright-perl channel therein.
+I'm watching that space and should be able to answer your questions.
+https://aka.ms/playwright-slack

+ 1 - 1
dist.ini

@@ -1,5 +1,5 @@
 name = Playwright
-version = 0.005
+version = 0.006
 author = George S. Baugh <george@troglodyne.net>
 license = MIT
 copyright_holder = Troglodyne LLC

+ 8 - 0
lib/Playwright.pm

@@ -70,6 +70,11 @@ All the classes mentioned there will correspond to a subclass of the Playwright
 
 See example.pl for a more thoroughly fleshed-out display on how to use this module.
 
+=head3 Questions?
+
+Feel free to join the Playwright slack server, as there is a dedicated #playwright-perl channel which I, the module author, await your requests in.
+L<https://aka.ms/playwright-slack>
+
 =head3 Why this documentation does not list all available subclasses and their methods
 
 The documentation and names for the subclasses of Playwright follow the spec strictly:
@@ -422,6 +427,9 @@ sub quit ($self) {
     # This should also prevent the waitpid below from deadlocking due to two processes waiting on the same pid.
     return unless $$ == $self->{parent};
 
+    # Make sure we don't mash the exit code of things like prove
+    local $?;
+
     $self->{killed} = 1;
     print "Attempting to terminate server process...\n" if $self->{debug};
     Playwright::Util::request( 'GET', 'shutdown', $self->{port}, $self->{ua} );