Stories
Slash Boxes
Comments

SoylentNews is people

Meta

Log In

Log In

Create Account  |  Retrieve Password


Site News

Join our Folding@Home team:
Main F@H site
Our team page


Funding Goal
For 6-month period:
2022-07-01 to 2022-12-31
(All amounts are estimated)
Base Goal:
$3500.00

Currently:
$438.92

12.5%

Covers transactions:
2022-07-02 10:17:28 ..
2022-10-05 12:33:58 UTC
(SPIDs: [1838..1866])
Last Update:
2022-10-05 14:04:11 UTC --fnord666

Support us: Subscribe Here
and buy SoylentNews Swag


We always have a place for talented people, visit the Get Involved section on the wiki to see how you can make SoylentNews better.

posted by janrinok on Tuesday June 14 2016, @01:23PM   Printer-friendly
from the like-maple-syrup dept.

So, the Islamic Terrorist Opens Fire on Florida Nightclub; 50 Killed, 53 Wounded story is up over 400 comments and loading slower than hell. We finally managed to find ourselves a limit to comments under the current code. There's a fix going to be coming in the upcoming site update but for now there are two workarounds; take your pick.

  1. Change your comment view mode to Nested or Flat.
  2. Change Comment Limit under Preferences to five to ten.

The latter solution gives you 5-10 root level comments and all their children not 5-10 comments total. It also allows you to keep using the javascript expand/collapse buttons if you were.


Original Submission

posted by takyon on Saturday June 04 2016, @03:30PM   Printer-friendly
from the just-a-thought dept.

Not infrequently, we receive a story submission to SoylentNews that consists of a single URL. Or, a story that contains but a single sentence or paragraph along with the URL. During weekends and holidays, the story submission queue tends to run dry. We have an IRC channel (#rss-bot) that gathers RSS links from around the web. Hmm.

It would be really handy if there were an automated way to "scrape" the contents of that page. In some cases, a simple redirect of the output of a text-based browser like Lynx would do the trick. Unfortunately, all too many sites subscribe to the idea that a web page needs to pull in Javascript and libraries from a myriad of other sites. Failing to do so displays a blank page.

There must be a way to do it — search engines like Google and Bing must extract the page text in order to index it. It would be best to have a general-purpose solution; having a custom template for each site is time-consuming to create and maintain (think if the site changes its layout). Our site is powered by Perl, so that would be the obvious preference.

So, fellow Soylentils, what tools and/or techniques have you used? What has worked for you?

Maybe I'm approaching this the wrong way? When all you have is a hammer... what am I missing here? Is there another approach?


Original Submission

posted by cmn32480 on Friday April 01 2016, @02:21PM   Printer-friendly
from the it-is-exec-ptional dept.

Join #soylent @http://chat.soylentnews.org/ to play some asynchronous rock/paper/scissors with other SoylentNews lurkers and staff. Asynchronous rock/paper/scissor is basically a game that records all your rps choices, and as players throw in their next rounds, they get played against your previous turns.

The bot named 'exec' is hosted by one of our (generally) trustworthy editors (cmn32480) and includes the '~rps' command to play.

~rps
Outputs syntax and online help link.

~rps r
Adds rock to your account's sequence.

~rps p
Adds paper to your account's sequence.

~rps s
Adds scissors to your account's sequence.

~rps rank
Outputs current ranking to http://ix.io/nAz

You can also submit multiple turns in one command, which is useful if you're a new player. The script will trim the sequence to the current maximum sequence length of all players, plus one (to gradually advance the available turns). Example: ~rps rrrrpsrpsrpssspss

Note, there is also a random delay requirement between turns, so you can try playing with a bot but you will need to allow for this mandatory delay.

You can play from any channel that 'exec' is currently in, or private message the bot to hide your sequence from prying eyes.

Players are tied to NickServ accounts, so to play you must register with NickServ. This is easy to do and most IRC clients can automagically identify for you with minimal fuss. This is to keep your game from being manipulated when you're offline.

Ranking is based on a handicap that balances the number of wins with the number of turns played. This is so that a new player who gets a win doesn't secure top spot just because they have a 100% win rate.

The script is certainly not perfect and is gradually evolving, but it has reached a point where I think it is at least stable enough to enjoy. There are also lots of other asynchronous rock, paper, scissors games out there on the interwebs.
Check out the source code for the IRC bot game script here if you're curious or would like to contribute: https://github.com/crutchy-/exec-irc-bot/blob/master/scripts/rps.php

When you hop on IRC to play, be sure to say 'hi'. We don't bite... much :p


Original Submission