Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

OK, let's do it ... Best Practices!

155 views
Skip to first unread message

Tony Gravagno

unread,
May 12, 2020, 6:14:08 PM5/12/20
to Pick and MultiValue Databases
One of my partners is training new developers (yes, there is such a thing) and today asked me about coding standards, best practices, and policies that can help to keep applications maintainable.

I couldn't remember where I had seen such a document before, but I have a lot of standards that I use and I thought it would be a good time to start documenting them. The plan was then to go find an existing document to see what's different. So I came here, did a search, and found a reference to PickWiki (of course) where Rex Gozar and Ian McGowan have been posting tips since 2007.

As I sat here looking at that doc, and enjoying my humble pie flavored with all of the thing I had simply not considered or forgotten, I figured it might be a good time to open all of this up for public discussion.

So here's the suggested format, which I know won't be followed (can't herd cats with standards about writing about standards) but I'm going to try...

Please pick a topic from the PickWiki page and comment if you have objections, comments, or additions.

CREATE A NEW FORUM THREAD here with title : "BP : x.yy short description", to discuss the topic.
For example: "BP: 1.7 : Equated constants"

With that topic here, all related comments will be in one place.
Use the hard-coded x.y indexing from the doc, not the generated/dynamic indexing at the top of the page.

If you'd like to add a new category to the existing doc (great idea!) feel free to create a new proposed index sequence here with a decent topic heading so that we can all discuss your ideas. For example, section 1, Variable and Constant Naming goes to 1.14. I'd like to add a new idea to that so I might create:
"BP: 1.New : Using bird names as variable prefixes"
Use "1.New" or "1.+" or similar. We don't want to propose "1.15" because if that specific topic doesn't get added as 1.15 then the entire thread will have an invalid ID.

We are all familiar with the concepts here, one person's Best Practice is someone else's grounds for termination. Some OK Ideas are not Best Practices. Some techniques are commonly used standards, or just preferences. That doesn't make them "Best Practices". What we're looking for are well-reasoned practices that developers "should follow" will little argument about why the practices should not be followed. That is, few of us might actually do something, or we might do it slightly differently, but perhaps we can agree that a technique can be a best practice if only more people followed it.

Rather than quibble about such nuances, let's just let the discussions play out and see what people think about various coding techniques.

After some discussion and a few "yeah, this is a good idea" comments, we can edit the wiki page and add a reference back to the related discussion here.

If you feel the urge to mix topics, please create a new thread and reference it. Compare this to "topic stew" which mixes Common and GFEs with the nuances of growing rice in the 1960's. Please don't do that...

Also note: This is about Coding Standards with BASIC. This is not about file creation, backups, correlatives, or the merits of the subvalue. Please do create threads for all of those topics ... just do not confuse those topics with BASIC Coding Standards.

You are encouraged to tag your threads using the tag "best-practices" as I have done with this thread.

If a new suggestion has already been discussed, we can link to the existing discussion and close the new one.

All of this relies on professionals to craft text that conveys a specific concept that means something to other developers. Sure, we can discuss and debate and cajole around the topic, but if we are going to collectively agree that something is a good idea, and copy/paste it into the wiki, we need to have it articulated fairly well. I do plan to volunteer to scrape the forum for accepted best practices and even good ideas as "runner ups", but I am hoping that people don't make that task difficult by hiding concepts in the middle of "topic stew".

So check out the Coding Standards doc on Pick Wiki, click the New button here, and start talking a BASIC Coding Standard that you believe is a Best Practice! I'll do the same soon.

Thanks.
T

Tony Gravagno

unread,
May 14, 2020, 2:42:35 PM5/14/20
to Pick and MultiValue Databases
Thanks to the overwhelming positive response to this thread, and the wealth of new threads to discuss the best practices already proposed, I thought I'd another collection here as a starting point for other threads. This is my "I'll dump it here until I can do it properly".
There is a bit of overlap with the doc created by Rex and Ian.

What do I hope will come of this? That someone will pick a point, create a new thread, and discuss whether it's a good or bad technique, and indeed a "best practice".

More later on this topic... cuz it's obvious that people are dying to get into it.... ;)

T

Llane Rost

unread,
May 15, 2020, 12:07:50 AM5/15/20
to Pick and MultiValue Databases
Why not use Github or something to better highlight the code versus Google Docs. Also fantastic, a lot of the thing you mentioned our company follows, others we do not follow at all. Coming from working with Python, it bugs me a bit. I have only been learning it for the past year, but primary focus is else where still.

Rex Gozar

unread,
May 15, 2020, 10:32:16 AM5/15/20
to mvd...@googlegroups.com
I'll also mention that PickWiki has a "discussion" tab that's intended
for commenting on an article. Its wiki syntax does allow for better
code formatting. I've added a couple of discussion points in the
https://www.pickwiki.com/index.php/Talk:CodingStandards document.

rex
> --
> You received this message because you are subscribed to
> the "Pick and MultiValue Databases" group.
> To post, email to: mvd...@googlegroups.com
> To unsubscribe, email to: mvdbms+un...@googlegroups.com
> For more options, visit http://groups.google.com/group/mvdbms
> ---
> You received this message because you are subscribed to the Google Groups "Pick and MultiValue Databases" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to mvdbms+un...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/mvdbms/c4291230-7950-4d1c-9601-767dbb42d2c8%40googlegroups.com.

Rex Gozar

unread,
May 15, 2020, 12:05:17 PM5/15/20
to mvd...@googlegroups.com
Tony,
Compile-time versus runtime EQUATE's? I'm not familiar with all the
PICK-variants, but I thought all EQUATE's are compile-time, setting
memory pointers as needed.

rex
Reply all
Reply to author
Forward
0 new messages