ChucK/Bugs/Release

From CSWiki
Revision as of 00:22, 4 November 2009 by Kassen (talk | contribs) (Hopefully these will be fixed for the next release of ChucK)

Jump to: navigation, search

Hopefully these will be fixed for the next release of ChucK

Please enter the bug as descriptively as possible, with the shortly code that shows the symptom. Examples can be found here.

  • LiSa's play loop is a samp shorter than the record loop when both equal the maximum duration. Workaround; set a larger .duration() and explicitly define both instead of relying on the implicit default. (fix by Dan should be in the next version, here for tracking).
  • UGens defined and connected in sporked shreds aren't always disconnected when the Shred or it's mother exits (see the list 8&9 oct 2009.
  • Fractional time cases shreduler issues see here
  • chout.flush() crashes and IO.newline() doesn't properly force a flush. (fix in the works by Ge, here for tracking)
  • chout pipe in the mini causing a delay in printing messages (fix in the works by Spencer, here for tracking)
  • Defining a Shred object, then at a later time assigning a sporked function to it will crash the VM. This used to work.
  • CNoise doesn't correctly set it's colour. Documentation (with speedy fix by Tom which is confirmed to work) on the list, July14 2009
  • Comparing strings to null will crash the VM, see list post on the subject june 24 2009
  • Assignment as it applies to primitives (non-objects) doesn't seem very satisfactory. This may be a bug or a lack of documentation. Debate on the list, starting May 31 2009. Kindly remove this item if the current behaviour is deemed proper.
  • "3 %=> count++;" will crash the VM, should likely give some sort of parser-based error instead (list Feb8 2009).
  • "Bad return signature in pre-constructor leads to null instance", as it's called on the list on may12 2009. Basically there will be issues with null-pointers causing issues later on when a function doesn't properly return.
  • (apparent) over-zealous GC in functions returning non-primitives, leading to crashage. A clear example was posted to the list by Robert Poor on April12 2009;\\
      fun Element allocateElement() {
          if ((_pool.size() => int size) > 0) {
              _pool[size-1] @=> Element @ element;
              size-1 => _pool.size;
              return element;
          }
          return new Element;
      }
  • Array popBack() method returns type void on arrays of Objects:
Object objects[0];
SinOsc s;
objects << s;

SinOsc s1;
objects.popBack() $ SinOsc @=> s1;

On the list Wed, Jan 21, 2009 -- Mike Clemow

  • Associative arrays seem to be limited to a single dimension
int array[3][3];
// This type of assignment gives an exception
3 @=> array["set"]["value"];
// So does this
3 @=> array["set"][0];
// This type of assignment works but...
[1, 2, 3] @=> array["set"];
// ...accessing values causes an exception
<<< array["set"][0] >>>;

documented on the list Nov 21/08 --Stephen

  • This line will crash Chuck;
Class Foo;
  • Array members created with the new append syntax can't be assigned to or there will be a issue about
"chuck_oo.cpp:106: void Chuck_VM_Object::release(): Assertion `m_ref_count > 0' failed."

documented on the list sept 28 --Kassen 14:42, 28 September 2008 (EDT)

  • ChucK will crash at functions that reference a Ugen that was defined above the function when the function is sporked before the UGen is defined. I feel the parser should catch this like it does when we define the function at the top of the file. Details on the list, Sept 25. --Kassen 14:48, 28 September 2008 (EDT)
  • "*=>" cant multiply durations by integers. Details on the list, sept 22. --Kassen 14:48, 28 September 2008 (EDT)
  • Giving Wurley.freq() (and quite likely other UGen member functions) "inf" as a parameter, for example as the result of a floating point div. by 0, will result in the whole VM getting stuck as the UGen starts taking 100% CPU. Quite possibly there are other situations where floats that are "not a number" will result in issues for UGens. One proposed partial solution would be to make sure parameters of type float are numbers before using them. Another topic for consideration would be extending watchdog to cover stuck UGens. Filed as a bug because it can mean losing the whole VM. More detailed debate on the list; sept 19th. --Kassen 13:54, 19 September 2008 (EDT)
  • Divide by 0 in integer math means a complete crash of the VM without notice. Proper behaviour would likely be dropping just the shred with a printed notice for debugging purposes. This has been mentioned before but most recently popped up on the forum, documented by UnderwaterBob, Antimon & Kassen. --Kassen 13:54, 19 September 2008 (EDT)


  • Static primitive class members can't be set to a value at construction/initialisation like this;
class foo
   {
   3 => static int bar;
   }
<<<foo.bar>>>;

As posted to the list. --Kassen 21:31, 9 September 2008 (EDT)

  • Increasing the size of a array that has a home-made class as it's type using .size() doesn't properly instantiate the new object(s). "<<" combined with "new" does. (As mentioned on the list aug10) --Kassen 15:40, 10 August 2008 (EDT)
  • Full out crashage when defining a class within a class, maybe that should simply be illegal like defining a function within a function is? Info with example by Pablo;

[[1]]

  • Sitar.pluck() doesn't work and giving Sitar very low notes results in errors, so many errors that it breaks up audio. I looked into it but had a hard time deciding what the desired functionality should be --Kassen 07:33, 7 December 2007 (EST).
  • .getchar() for the old keyboard interface doesn't adhere to the new (coherent) naming scheme yet, I think it should be .getChar() with the old one getting depreciated --Kassen 07:33, 7 December 2007 (EST).
  • a class that extends Event needs to be defined before it's called or there will be a complaint that the class doesn't have a member named "broadcast" or "signal". Example that will yield a complaint yet should be correct;
Trigger trig;
trig.broadcast();
class Trigger extends Event { int target; }

(as reported on the list March3) --Kassen 14:06, 3 March 2008 (EST)

  • Seg-fault at overloaded functions returning non-identical-type arrays.
better error message, I think, but still seg-faults
  • more seg-faulting at something (probably) involving assignment to arrays in functions that were parameters (as per email, here for tracking) --Kassen 00:33, 27 March 2008 (EDT)


  • <<< 2 => int number >>>; --Kassen 22:33, 22 May 2008 (EDT)
now crashes/aborts in a different way;
chuck: chuck_type.cpp:2727: Chuck_Type* type_engine_check_exp_decl(Chuck_Env*, a_Exp_Decl_*): Assertion `value != __null' failed.
Aborted


  • time and dur aren't evaluated correctly by "&&" if used as one of a multiple clauses for a "if" statement like;
if(second && now && true) <<<"yay">>>;

as debated on the list jul24 --Kassen 15:04, 24 July 2008 (EDT)

  • (add your own)

Fixed in 1.2.1.3

  • calling overloaded functions with most specific match
  • When giving some Stk UGen member functions values outside of their range the error reports a incorrect range that the value should be in (documented on the list sep4 2009)


  • When a shred exits double connections to the dac aren't properly cleaned up, possibly resulting in beeps that can only be stopped by stopping the whole VM. This may or may not also affect inter-UGen connections which could be relevant in double connections to static UGens in public classes, I didn't test those. Example code on the list, posted sept. 15. --Kassen 12:49, 15 September 2008 (EDT) Fix in CVS according to Ge
  • Chuck fails to build using GCC4.3.x. Documented by PopCode and Nomic here; http://electro-music.com/forum/viewtopic.php?t=30859 This is leading to complications in the build process on Linux that will most likely get worse in the near future as more distros switch to the new version. --Kassen 02:40, 22 December 2008 (EST) Affects ChucK up to 1.2.1.1 so this still affects the Mini which lags a version ATM. Workaround is to replace the version of ChucK it uses with the latest before compiling details on the list dec.29 (Kas)
  • Moog.noteOff now works. Probably related to the earlier envelope bug but this was still there in 1.2.1.2 (this wasn't documented in the VERSIONS text)

Fixed in 1.2.1.2

  • Probable typos in the source discovered by Moudi while attempting to build a ASIO MiniAudicle as well as various other issues and potentially questionable bits;

[[2]] (Ah, I just noticed this is already in the works)

  • PulseOsc.width() is write only (should be read-write according to the manual)
  • SqrOsc.width() exists but doesn't do a thing. Manual claims it works, Adam (on the list) suggested it should return .5 but not be writable. this makes sense as PluseOsc has this covered.--Kassen 05:56, 24 April 2008 (EDT)



Fixed in 1.2.1.1

  • Odd Envelope behaviour. Documentation and a suggested fix to be found here; [[3]]


Fixed in 1.2.1.0

  • Make sure members of classes get properly instantiated when the instances of the classes are implicidly defined in a array (as discussed on the list June10 to July7, found by Eduard) (ge: fixed and will be in 1.2.0.9)
  • Arrays of Ugens over 10 locations long inside of classes will crash, like this; (ge: this should now work - part of the above fix)
// I picked this 10 at random, for length 5 it'll crash too
Foo x[10];
class Foo
    {
    // at length 10 it'll run but this will crash(!!??)
    SndBuf array[11];
    }

As posted to the list, July4(Kas.)

  • 1 => rhodey.noteOff (and the same for wurley) cause stuck-notes.(kas.) (ge: bug in ADSR from an earlier fix, oops. now fixed, hopefully and will be in 1.2.0.9)
  • crash because of killing the parent-shred; (ge: bug in VM messaging not quite expected the remove to come from calling shred or his/her parent! fixed, and will be in 1.2.0.9)

me.id() => int my_id; fun void second_shred()

   {
   second => now;
   Machine.remove(my_id);
   }

spork ~ second_shred(); hour => now;