Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
nielsm
Jun 1, 2009



Modern Pragmatist posted:

I have an open source software licensing question. I have some software that I use that provided a certain level of functionality. This software was based on the Modified BSD license, and I'm free to modify and distribute it as I please.

I have added some functionality to the software and now want to make my changes freely available. Obviously, part of the license is that I must distribute the original license file along with my modified software. What is the best way to go about doing this?

I can obviously include the original license file (which contains the creator's name and copyright statement) but do I need to create an additional license file to cover my modifications and perhaps add my own copyright line? Or do I just have to include the original license file since I didn't create it myself and thus can't include modified copyright information?

I have searched around but hadn't found any solid information about how to go about doing this.

I am not a lawyer, but this is my interpretation:

The BSD licenses don't require you to distribute your modified source code, as long as you still acknowledge the original author. It also doesn't require your own changes to be under the same license.

If you are distributing your modified source, and you consider your own changes sufficiently significant, then do add to the original license file. I'd suggest putting a horizontal line and then pasting your own, full license text in afterwards. Perhaps identify your changes and additions in the individual source files.

Adbot
ADBOT LOVES YOU

TheReverend
Jun 21, 2005

I need some string help.

I have a list of electronic parts. They are kinda crazy named like "10/20 AC-MR". As Input I'm going to be getting a string from voice recognition that approximates a value (because voice recognition isn't perfect).

My question is, what's a good way to compare an input to a list of string values to return a likely match?

Bognar
Aug 4, 2011

I am the queen of France
Hot Rope Guy
The simplest way is to use something like Levenshtein distance, but you may need something more involved if you're going to have numbers and special characters.

ExcessBLarg!
Sep 1, 2001

Modern Pragmatist posted:

I have added some functionality to the software and now want to make my changes freely available. Obviously, part of the license is that I must distribute the original license file along with my modified software. What is the best way to go about doing this?
Unless there's good reason to do otherwise, it's simplest for everyone to release your modifications under the same license as the original software. The exception is that, for three-clause and (especially) four-clause BSD licenses, I might license any source files solely authored by you under a two-clause BSD license since the other variants are annoying.

Now, the original software should have a copyright statement and a copy of the license at the top of every source file. For any file that you substantially modify, add your copyright statement underneath the original, before the license text. If you're adding new files, copy the existing license with your copyright statement alone.

However, if the original software doesn't actually have copyright statements and license text in each source file, then it gets complicated. The least-effort thing on your part would be to just add a copyright statement in the "license file", but then in absence of revision control history, it's not exactly clear where your modifications lie. If the software is particularly important, I would contact the original author to get each source file correctly licensed first, otherwise whatever.

Modern Pragmatist
Aug 20, 2008

ExcessBLarg! posted:

Unless there's good reason to do otherwise, it's simplest for everyone to release your modifications under the same license as the original software. The exception is that, for three-clause and (especially) four-clause BSD licenses, I might license any source files solely authored by you under a two-clause BSD license since the other variants are annoying.

Now, the original software should have a copyright statement and a copy of the license at the top of every source file. For any file that you substantially modify, add your copyright statement underneath the original, before the license text. If you're adding new files, copy the existing license with your copyright statement alone.

However, if the original software doesn't actually have copyright statements and license text in each source file, then it gets complicated. The least-effort thing on your part would be to just add a copyright statement in the "license file", but then in absence of revision control history, it's not exactly clear where your modifications lie. If the software is particularly important, I would contact the original author to get each source file correctly licensed first, otherwise whatever.

Thanks to both of you for the feedback.

It's a two-clause BSD so I was just going to stick with that for the modified version.

Unfortunately there is not a copyright line or license statement in the header of the files and I'm not really adding completely new files but rather adding functionality within their existing source.

As far as revision history, I was thinking of uploading the original to github and then committing the changes so the changes that I introduced could be determined.

It's nothing particularly important and likely won't be used by too many people. Definitely not going to earn any money. I just wanted to do right by the original author.

pliable
Sep 26, 2003

this is what u get for "180 x 180 avatars"

this is what u fucking get u bithc
Fun Shoe

EDIT: I actually got a lot of help from the IRC channel and so meh, I'm completely rewriting this beast. Thank y'all <3

pliable fucked around with this message at 11:02 on Jul 18, 2014

Sedro
Dec 31, 2008
At a glance, it looks like you're mutating the list as you iterate through it. Each time you remove an item you'll skip an item in the next iteration. Try instead constructing a new list with the items you want to include and return it from your function.

Edit: No, that's not the issue. You'll have to fix the code you posted though because first_initial_name is not defined.

Sedro fucked around with this message at 05:25 on Jul 18, 2014

pliable
Sep 26, 2003

this is what u get for "180 x 180 avatars"

this is what u fucking get u bithc
Fun Shoe

Sedro posted:

At a glance, it looks like you're mutating the list as you iterate through it. Each time you remove an item you'll skip an item in the next iteration. Try instead constructing a new list with the items you want to include and return it from your function.

Edit: No, that's not the issue. You'll have to fix the code you posted though because first_initial_name is not defined.

Oh whoops, I only copied the while loop over, but I'll fix it

ExcessBLarg!
Sep 1, 2001

Modern Pragmatist posted:

It's nothing particularly important and likely won't be used by too many people.
In that case I might just add to the license file and move on with life.

In general though, every source file should have a copyright statement and license (or license pointer in the case of the GPL) at the top. It's a pedantic thing, sure, but law is also pedantic. It's better to err on the side of pedanticism than ambiguity for when something might become important and money is involved.

Newf
Feb 14, 2006
I appreciate hacky sack on a much deeper level than you.
Does the act of creating methods that do nothing except call some other method have a name?

code:
class foo
{
 public void fizz() { /* do things */ }
}

class bar
{
 private foo myFoo;

 public void barVerb()
 {
  // do things
  fuzz();
  //do things
 }

 private void fuzz()
 {
  myFoo.fizz();
 }
}
I'm guessing that this would be considered an anti-pattern? Specifically, there isn't any reason for the fuzz() method to exist, and it could be replaced in the above barVerb() method with a call to myFoo.fizz(), which would remove a layer of indirection for the reader of the code.

LP0 ON FIRE
Jan 25, 2006

beep boop
HTML5 question. I made a button tag with draggle set to true:

code:
<button draggable='true'>My button</button>
Isn't that enough to work in iOS? Because it doesn't, but works on my OS X browsers Safari, Chrome and Firefox.

Mr. Crow
May 22, 2008

Snap City mayor for life
We have some installshield installers that don't clean themselves up properly when you uninstall, so I'm going to be cleaning them up. I'm not super familiar with InstallShield (or windows installation), so any ideas to point me in the right direction?

I can navigate around the existing .ism's and add / remove files or basic scripts to install and that's about the extent of my knowledge. I'm aware there's some sort of install file table which should handle uninstalling things but that's about it, assumed InstallShield would auto-populate that with whatever you're adding to it.

Bognar
Aug 4, 2011

I am the queen of France
Hot Rope Guy

LP0 ON FIRE posted:

HTML5 question. I made a button tag with draggle set to true:

code:
<button draggable='true'>My button</button>
Isn't that enough to work in iOS? Because it doesn't, but works on my OS X browsers Safari, Chrome and Firefox.

Drag and drop with HTML is in a terrible state. The best cross-browser way I've found to make something draggable is to use <a href="#" draggable='true' class='drag'>--content--</a> and place whatever you want to drag inside. Use the drag class to remove default link styling.

pokeyman
Nov 26, 2006

That elephant ate my entire platoon.

LP0 ON FIRE posted:

HTML5 question. I made a button tag with draggle set to true:

code:

<button draggable='true'>My button</button>

Isn't that enough to work in iOS?

Nope.

WebKit DOM Programming Topics posted:


Note: This technology is supported only on desktop versions of Safari. For iOS, use DOM Touch, described in “Handling Events” (part of Safari Web Content Guide) and Safari DOM Additions Reference.

Volmarias
Dec 31, 2002

EMAIL... THE INTERNET... SEARCH ENGINES...

Newf posted:

Does the act of creating methods that do nothing except call some other method have a name?

code:
class foo
{
 public void fizz() { /* do things */ }
}

class bar
{
 private foo myFoo;

 public void barVerb()
 {
  // do things
  fuzz();
  //do things
 }

 private void fuzz()
 {
  myFoo.fizz();
 }
}
I'm guessing that this would be considered an anti-pattern? Specifically, there isn't any reason for the fuzz() method to exist, and it could be replaced in the above barVerb() method with a call to myFoo.fizz(), which would remove a layer of indirection for the reader of the code.

In this particular case, yes, it's useless because fuzz is private, so it can't be overridden nor is it visible to other classes.

If it were protected or public, however, it would potentially be good design, for the reasons above.

LP0 ON FIRE
Jan 25, 2006

beep boop

Bognar posted:

Drag and drop with HTML is in a terrible state. The best cross-browser way I've found to make something draggable is to use <a href="#" draggable='true' class='drag'>--content--</a> and place whatever you want to drag inside. Use the drag class to remove default link styling.

That's too bad. :(

The <a> tag doesn't seem to work iOS, though it works in the OS X browsers. I think I'll just need to make [a] separate implementation that handles touches as pokeyman describes, which is probably different on Android.

fritz
Jul 26, 2003

Newf posted:

Does the act of creating methods that do nothing except call some other method have a name?

There are shims: http://en.wikipedia.org/wiki/Shim_%28computing%29 which aren't too different from your example.

Bognar
Aug 4, 2011

I am the queen of France
Hot Rope Guy

LP0 ON FIRE posted:

That's too bad. :(

The <a> tag doesn't seem to work iOS, though it works in the OS X browsers. I think I'll just need to make [a] separate implementation that handles touches as pokeyman describes, which is probably different on Android.

Using the touch and mouse events is fairly well supported (it's how jQuery UI does drag and drop), but the performance isn't nearly as good as native drag and drop. There are a few libraries that handle this for you if you don't want to have a dependency on jQuery, though I can't remember them off the top of my head.

LP0 ON FIRE
Jan 25, 2006

beep boop

Bognar posted:

Using the touch and mouse events is fairly well supported (it's how jQuery UI does drag and drop), but the performance isn't nearly as good as native drag and drop. There are a few libraries that handle this for you if you don't want to have a dependency on jQuery, though I can't remember them off the top of my head.

Good to know, thanks. So far I haven't depended on jQuery for this project so maybe it would be a good idea for me to look for those.

TrampolineTales
Oct 9, 2012

I detect the presence of scum.
How would one go about finding the size of the stack for an AS3 program?

Strong Sauce
Jul 2, 2003

You know I am not really your father.





What's the most ideal way to load a VM with Windows Desktop environment? AWS/Azure seem to offer some Windows VMs but they seem to all be Enterprise/Windows Server VMs.

All I'm looking for is to load a Windows VM, do some tasks, and then exit the VM.

gariig
Dec 31, 2004
Beaten into submission by my fiance
Pillbug

Strong Sauce posted:

What's the most ideal way to load a VM with Windows Desktop environment? AWS/Azure seem to offer some Windows VMs but they seem to all be Enterprise/Windows Server VMs.

All I'm looking for is to load a Windows VM, do some tasks, and then exit the VM.

Azure can do that. Just create a VM and you can pick one from the Gallery which has Windows 8.1 Enterprise and Windows 7 SP1. There's a 30 day trial which gives you like $150 in Azure fun bucks. I haven't tried this with AWS and their desktop virtualization stuff

Thermopyle
Jul 1, 2003

...the stupid are cocksure while the intelligent are full of doubt. —Bertrand Russell

There's a project that serves a similar purpose to AutoIT/AutoHotKey that uses image recognition or something to find GUI elements to click on.

I can't remember the name. Does anyone know what I'm talking about?

edit: Found it. http://www.sikulix.com/

Thermopyle fucked around with this message at 17:13 on Jul 23, 2014

Comfy Fleece Sweater
Apr 2, 2013

You see, but you do not observe.

belle of my ballz posted:

Anybody here have experience with either OpenBravo or OpenERP
How easy is it to find modules and solid coders
How hardcore is the installation, is it worth paying someone
Any reasons why I should run away?

Same questions. Anyone? This is from 2010 and I haven't found any mention of this software. It's either this or SAP.

edit: Is there a SAP thread? I mean Openbravo is about 70% cheaper to implement up front, although the yearly fees are about the same. It's for a retail business.

Comfy Fleece Sweater fucked around with this message at 01:51 on Jul 24, 2014

KoRMaK
Jul 31, 2012



I have a Ruby on Rails app that is using google maps 3 api. In development, when I view the map from my iphone using chrome, all the infowindows show up. When I push to heroku the infowindows suddenly stop showing.

So, infowindows work in development, not in production. I looked through what I could on google, and there's nothing that worked. If I zoom out to a really high level on the map they suddenly show up. At a closer zoom level, I can see them being drawn, but then they disappear.

Why would this work locally in dev rather than heroku?

Bognar
Aug 4, 2011

I am the queen of France
Hot Rope Guy

KoRMaK posted:

I have a Ruby on Rails app that is using google maps 3 api. In development, when I view the map from my iphone using chrome, all the infowindows show up. When I push to heroku the infowindows suddenly stop showing.

So, infowindows work in development, not in production. I looked through what I could on google, and there's nothing that worked. If I zoom out to a really high level on the map they suddenly show up. At a closer zoom level, I can see them being drawn, but then they disappear.

Why would this work locally in dev rather than heroku?

Are you using HTTPS on production and HTTP on dev? If you connect to the Google Maps API through HTTP, it won't load on an HTTPS page.

Strong Sauce
Jul 2, 2003

You know I am not really your father.





gariig posted:

Azure can do that. Just create a VM and you can pick one from the Gallery which has Windows 8.1 Enterprise and Windows 7 SP1. There's a 30 day trial which gives you like $150 in Azure fun bucks. I haven't tried this with AWS and their desktop virtualization stuff

Thanks. I'll take a close look at Azure. Not sure why I thought Enterprise wouldn't work since it still is just Windows Desktop.

KoRMaK
Jul 31, 2012



KoRMaK posted:

I have a Ruby on Rails app that is using google maps 3 api. In development, when I view the map from my iphone using chrome, all the infowindows show up. When I push to heroku the infowindows suddenly stop showing.

So, infowindows work in development, not in production. I looked through what I could on google, and there's nothing that worked. If I zoom out to a really high level on the map they suddenly show up. At a closer zoom level, I can see them being drawn, but then they disappear.

Why would this work locally in dev rather than heroku?

The things started working when I traveled to a marker that was way far away from the others. So I realized there was probably some bug with bad lat/lng data on one of the users. I logged into the console and reset all the user's lat/lng to nil and NOW IT WORKS!

So, the issue was production data had some buggy poo poo in it that dev didn't. Should have thought of that earlier on.



Is there a reputable free way to get a ssl cert?

KoRMaK fucked around with this message at 01:57 on Jul 25, 2014

Volmarias
Dec 31, 2002

EMAIL... THE INTERNET... SEARCH ENGINES...

KoRMaK posted:

Is there a reputable free way to get a ssl cert?

You mean one that isn't self signed? If so, probably not.

fletcher
Jun 27, 2003

ken park is my favorite movie

Cybernetic Crumb

KoRMaK posted:

Is there a reputable free way to get a ssl cert?

If you're not even willing to pay money for a cert how much are you investing in the rest of your security?

I thought most registrars give you a 1 year cert if you buy a domain anyways.

krk
Nov 14, 2011

KoRMaK posted:

Is there a reputable free way to get a ssl cert?

At least StartSSL offers free Class 1 certificates for free.

Using this service was discussed in the recent Ars' article http://arstechnica.com/information-technology/2012/11/securing-your-web-server-with-ssltls/ .

SalTheBard
Jan 26, 2005

I forgot to post my food for USPOL Thanksgiving but that's okay too!

Fallen Rib
I have a limited amount of experience with programming and I've been tasked at work to create an "interactive" checklist of a screenshot.

I'll explain the backstory on this. I work for a big insurance company and one thing that the new people constantly fail on is making sure all the contact information is entered into a claim. The idea is that they would have a screenshot of the contact screen up and as they entered in information they could check a box that would then color in that portion of the screenshot. Is this something thats possible? Also would there be a way to set conditions, for example we only have to collect date of birth if someone is injured, there is a question that says "Was this person injured Yes / No / Unknown" I would like that if you clicked "Yes" that a box would pop up and say "GET DATE OF BIRTH".

I appreciate any help that could be provided.

JawnV6
Jul 4, 2004

So hot ...
You're trying to bolt this onto an existing system where people enter information? This can't just get baked into the existing application? That's a completely understandable situation, just making sure I understand.

Take a look at Sikuli: http://www.sikuli.org/

It's not a perfect fit, but you could probably bang something functional out of it.

bobua
Mar 23, 2003
I'd trade it all for just a little more.

edit: well gently caress that's cool ^^^

That could certainly be done, but sounds like it needs to be done on the forms side. If you really had to do it on a screenshot it goes from something someone could do in a pdf form in a few minutes to some hefty image recognition work.

If you're not a programmer at all and your first program is image recognition you're going to have a bad time.

SalTheBard
Jan 26, 2005

I forgot to post my food for USPOL Thanksgiving but that's okay too!

Fallen Rib

JawnV6 posted:

You're trying to bolt this onto an existing system where people enter information? This can't just get baked into the existing application? That's a completely understandable situation, just making sure I understand.

Take a look at Sikuli: http://www.sikuli.org/

It's not a perfect fit, but you could probably bang something functional out of it.

It's not something bolted into the current system, because honestly our current system is cobbled together with duct tape and fishing wire. I attached a screen shot to give a better idea of what I'm talking about. All of our computers have dual screens so I'm thinking it's something visual that could be pulled up on a 2nd screen. It might be impossible and if thats the case I'm fine with that, I'll just have to go back to the drawing board.

bobua posted:

edit: well gently caress that's cool ^^^

That could certainly be done, but sounds like it needs to be done on the forms side. If you really had to do it on a screenshot it goes from something someone could do in a pdf form in a few minutes to some hefty image recognition work.

If you're not a programmer at all and your first program is image recognition you're going to have a bad time.

Haha. My boss isn't expecting miracles from me. His exact description is "Something like a word document that has "post it" notes on it that could be "ripped off" when you asked that question and then easily refreshed for the next call!"

Only registered members can see post attachments!

SalTheBard fucked around with this message at 00:17 on Jul 26, 2014

Newf
Feb 14, 2006
I appreciate hacky sack on a much deeper level than you.
Why isn't there any syntax highlighting in the [code] blocks on this forum? Anyone feel like this is something worth fixing?

Jewel
May 2, 2009

There is but you have to use [code=<LANGUAGE>]

Ie [code=cpp]

C++ code:
#include <iostream>
using namespace std;

int main()
{
  int length, width;
  int perimeter, area;              // declarations
  cout <<  "Length = ";             // prompt user
  cin >> length;                    // enter length
  cout << "Width = ";               // prompt user
  cin >> width;                     // input width
  perimeter = 2*(length+width);     // compute perimeter
  area = length*width;              // compute area
  cout << endl
       << "Perimeter is " << perimeter;
  cout << endl
       << "Area is " << area
       << endl;                    // output results
}
And for some reason php has it's own tag [php]

php:
<?php
$last_modified filemtime("example7.php3");
print("Last Modified ");
print(date("m/j/y h:i"$last_modified));
?>
Edit: And a list of supported syntax:
  • C# (cs, csharp)
  • Ruby (rb, ruby)
  • JavaScript (javascript, js)
  • Markdown (md, markdown)
  • ActionScript (as, as2, as3, actionscript)
  • Visual Basic (vb, vbscript)
  • Objective-C (objc, objectivec)
  • Batch Files (dos, bat)
  • C++ (cpp)
  • PHP
  • XML
  • CSS
  • SQL
  • INI
  • SmallTalk
  • CoffeeScript
  • GO
  • Bash
  • Diff
  • Lua
  • Lisp
  • Java
  • Python
  • Perl
  • Django
  • Delphi
  • Apache

Jewel fucked around with this message at 03:15 on Jul 27, 2014

Newf
Feb 14, 2006
I appreciate hacky sack on a much deeper level than you.

Jewel posted:

There is but you have to use [code=<LANGUAGE>]

Well then.

KoRMaK
Jul 31, 2012



fletcher posted:

If you're not even willing to pay money for a cert how much are you investing in the rest of your security?

I thought most registrars give you a 1 year cert if you buy a domain anyways.
I didn't say I'm not willing. The domain is past the 1 year mark.


krk posted:

At least StartSSL offers free Class 1 certificates for free.

Using this service was discussed in the recent Ars' article http://arstechnica.com/information-technology/2012/11/securing-your-web-server-with-ssltls/ .
Cool thanks.

Is there a goon recommended pay service? I'm doing this on a heroku free app which seems like it has its own considerations. It's a hobby project now, but I'm getting it prepped for people to start using it. My main domain is hosted on lithium, and this app has a subdomain handled by lithiums dns.

KoRMaK fucked around with this message at 04:23 on Jul 27, 2014

Adbot
ADBOT LOVES YOU

Narqulie
Oct 25, 2011
I'm not sure if Excel counts, but maybe someone can help me.

I'm making a quick points-calculator for a board game, The Cave.



I need to award the top two players of a category (row) with 8 and 4 points respectively. In the screen I posted, Player 5 would be given 8 points, and P4 4 points. I have other calculations on a separate sheet, so I could output these on there as well and then sum things up later.

So I need a =Vlookup(Max(B3:B7;A3:A7;1)for the top scoring player, but this returns an error. Also, how would I choose the second highest value and match that up to the corresponding player in row A?
Anyone have any insight into this? My brain just isn't cutting it!

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply