[issue36872] passing negative values through modules

2019-05-10 Thread David Collins
David Collins added the comment: Sorry for being so abrupt you are correct . The code I was working from was a university professors and not my own, I understood better thanks steve. I wasn’t passing a return value yet and the professors work was overwriting the list. I do apologise.

[issue36872] passing negative values through modules

2019-05-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: Robert, when posting to this tracker by email, please remove the quote of the previous post. It duplicates the post itself. I said exactly what I said, which explained why marking the issue for IDLE was a mistake. (The same error is a weekly occurrence,

[issue36872] passing negative values through modules

2019-05-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: David, the tracker 'component' is intended to be, for bug reports, the component of Python that you think has a bug. When you run your code with IDLE and you get an exception displayed, that almost certainly means that IDLE is working as intended: it ran

[issue36872] passing negative values through modules

2019-05-10 Thread David Collins
: [issue36872] passing negative values through modules Terry J. Reedy added the comment: David, the tracker 'component' is intended to be, for bug reports, the component of Python that you think has a bug. When you run your code with IDLE and you get an exception displayed, that almost certainly means

[issue36872] passing negative values through modules

2019-05-10 Thread Steven D'Aprano
Steven D'Aprano added the comment: David, I'm pretty sure that SilentGhost is correct. You are misreading the error message: it has nothing to do with the negative index. The problem is that your `insert_value` function returns None, not the list. I believe that what you have done is tested

[issue36872] passing negative values through modules

2019-05-09 Thread David Collins
David Collins added the comment: This is an issue with python On Fri, 10 May 2019 at 3:52 pm, SilentGhost wrote: > > Change by SilentGhost : > > > -- > components: -IDLE > > ___ > Python tracker > >

[issue36872] passing negative values through modules

2019-05-09 Thread SilentGhost
SilentGhost added the comment: This bug tracker is for development of CPython, please ask your question on python-help mailing list, IRC or other similar forums. -- nosy: +SilentGhost resolution: -> not a bug stage: -> resolved status: open -> closed type: compile error -> behavior

[issue36872] passing negative values through modules

2019-05-09 Thread David Collins
David Collins added the comment: Not the coding On Fri, 10 May 2019 at 3:53 pm, David Collins wrote: > This is an issue with python > > On Fri, 10 May 2019 at 3:52 pm, SilentGhost > wrote: > >> >> Change by SilentGhost : >> >> >> -- >> components: -IDLE >> >>

[issue36872] passing negative values through modules

2019-05-09 Thread SilentGhost
Change by SilentGhost : -- components: -IDLE ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue36872] passing negative values through modules

2019-05-09 Thread David Collins
David Collins added the comment: I have tested this in the Mac and PC versions of IDLE as well as in Spyder using Ipython. -- ___ Python tracker ___

[issue36872] passing negative values through modules

2019-05-09 Thread David Collins
New submission from David Collins : program_data.py file contains a list import list_function str_list4 = ['i', 't'] str_list4 = list_function.insert_value(str_list4, 's', -1) print(str_list4) list_function.py file def insert_value(my_list, value, insert_position): counter = 0