0

What is prefered version on handling 'serialized' code snippets, with features added to previous post? I have posted a polynomial expression snippet to which I could not include the division part because original poster whose thread inspired me to start, have not proved finding his solution to the problem.

Should I post new thread and include all code, considering that parts of earlier functionality has also changed in this version?

Should I post the new version as answer to my earlier snippet, or just include link to the more limited version posted earlier.

I also refered my earlier snippet in my new code snippet, however including the direct link to that Code Snippet thread. Is that according to rules, as I remember reading something about self contained in the recent posts about the competition. I also encouraged to use publicly available libraries in code snippets to others instead of reinventing the wheel. How you think about that?

Edited by pyTony

2
Contributors
3
Replies
7
Views
5 Years
Discussion Span
Last Post by pyTony
0

In your case (being a moderator with unlimited edit permissions), I'd say just keep a running update on the code for the snippet and make sure to include an easily seen comment in the message that says the code snippet is evolving. You might also link to the thread in question that keeps you from posting hte complete code.

For those who aren't moderators, I'd say to organize the snippet so that it's modular enough to support additions through replies to the thread. Then as it evolves, add another "module". The message should also contain a note that the snippet is evolving and to refer to replies for pieces that weren't in the original code.

0

In this case maybe most appropriate, I agree. Could be only that earlier versions too in some cases should be visible, as idea is to build gradually bigger program, step by strep.

Other point of Code Snippets is that not all code snippets are in Code Snippet s. In Python forum there is probably more code snippets in the Readme stickies than in Code snippet part. For example how to do timing and memoization. Many of those snippets were even added just now during Code Snippet competition time. I feel that pedagogic messages in these threads should be also considered Code snippets participating to the competition. Another problem is that these snippets cover some topics, which are important, but these readme threads are difficult to search as each post has not their own title.

I think we need one index of sticky thread code snippets and post it to code snippet section as sticky message.

update I ended up copying the old version as follow up message and updating the original posts making break to old description / change history by line. How it works for you? http://www.daniweb.com/software-development/python/code/425151/class-based-polynomials-with-magic-methods#post1817526

Edited by pyTony

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.