Netbeans plugin and Python 3

Nitin Pawar nitinpawar432 at gmail.com
Fri Jul 9 12:27:14 EDT 2010


Hi,

I never tried python3.0 with netbeans but I use python 2.6.5 with netbean
6.7.1

Here is how I managed to change from python 2.5 (netbeans default) to 2.6.5

1) From the tools-> plugins section install python plugin
2) Once plugin is installed just restart netbeans so that plugin is
activated
3) After plugin is activated, you can edit default python version by tools->
python platform
4) It will open a configure window, where you can point python to newly
installed 3.0 version.

I hope that helps.

Thanks,
nitin


On Fri, Jul 9, 2010 at 9:30 PM, <python-list-request at python.org> wrote:

> Send Python-list mailing list submissions to
>        python-list at python.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
>        http://mail.python.org/mailman/listinfo/python-list
> or, via email, send a message with subject or body 'help' to
>        python-list-request at python.org
>
> You can reach the person managing the list at
>        python-list-owner at python.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Python-list digest..."
>
> Today's Topics:
>
>   1. python instructor (Greg)
>   2. Re: ipython problem in opening a file (Youngung Jeong)
>   3. Netbeans plugin and Python 3 (Chrix)
>   4. Re: python instructor (Ed Keith)
>   5. Last day to submit your Surge 2010 CFP! (Jason Dixon)
>   6. SqlAlchemy: remote connection on problem on mysql database (Massi)
>   7. do (Robin)
>   8. Re: Opinions please -- how big should a single module grow?
>      (Tomasz Rola)
>   9. Re: Python -- floating point arithmetic (Aahz)
>  10. Re: 'reload M' doesn't update 'from M inport *' (Aahz)
>  11. Cpp + Python: static data dynamic initialization in *nix
>      shared lib? (Alf P. Steinbach /Usenet)
>  12. Why there is no "setdefaultencoding" in sys module? (crow)
>
>
> ---------- Forwarded message ----------
> From: Greg <gfiske at gmail.com>
> To: python-list at python.org
> Date: Fri, 9 Jul 2010 07:09:13 -0700 (PDT)
> Subject: python instructor
> We're looking for a first-rate python trainer to come to our
> organization for a day or two.  We are a small group of geospatial/
> remote sensing scientists whose research spans the gap between
> environmental accounting/monitoring and policy and human interaction.
> We have about 5-10 (or so) python users (and potential python users)
> who could potentially apply new skills to several in-house projects.
> The difficulty for the teacher would be covering breadth of experience
> we have currently.
>
> Any thoughts or advice would be greatly appreciated.  Thanks very
> much,
>
> Greg
>
>
>
> ---------- Forwarded message ----------
> From: Youngung Jeong <youngung.jeong at gmail.com>
> To: Eli Bendersky <eliben at gmail.com>
> Date: Fri, 9 Jul 2010 23:27:08 +0900
> Subject: Re: ipython problem in opening a file
> Thanks a lot!
>
> Youngung
>
>
> On Fri, Jul 9, 2010 at 10:17 PM, Eli Bendersky <eliben at gmail.com> wrote:
>
>> On Fri, Jul 9, 2010 at 16:07, Youngung Jeong <youngung.jeong at gmail.com>
>> wrote:
>> > Thank you for your kindness.
>> > I found you're right. It's running in that folder.
>> > What should I do for making this work?
>> > Could you please tell me a bit more...
>> >
>> > Youngung
>>
>> You can change the "current directory" ipython executes in, by either
>> executing it directly (from the command line) in the directory of your
>> choice, or calling the os.chdir function with the path of your choice.
>>
>> Eli
>>
>
>
>
> ---------- Forwarded message ----------
> From: Chrix <christian.sperandio at gmail.com>
> To: python-list at python.org
> Date: Fri, 9 Jul 2010 07:26:24 -0700 (PDT)
> Subject: Netbeans plugin and Python 3
> Hi,
>
> Someone knows if Netbeans will support Python 3 language features?
> Nowadays, I tried Netbeans 6.9 but it only supports Python 2.5 :(
> And I'd like really to develop with Python 3.
>
> Thanks.
>
>
>
> ---------- Forwarded message ----------
> From: Ed Keith <e_d_k at yahoo.com>
> To: python-list at python.org, Greg <gfiske at gmail.com>
> Date: Fri, 9 Jul 2010 07:49:05 -0700 (PDT)
> Subject: Re: python instructor
> Where are you located?
>
>   -EdK
>
> Ed Keith
> e_d_k at yahoo.com
>
> Blog: edkeith.blogspot.com
>
>
> --- On Fri, 7/9/10, Greg <gfiske at gmail.com> wrote:
>
> > From: Greg <gfiske at gmail.com>
> > Subject: python instructor
> > To: python-list at python.org
> > Date: Friday, July 9, 2010, 10:09 AM
> > We're looking for a first-rate python
> > trainer to come to our
> > organization for a day or two.  We are a small group
> > of geospatial/
> > remote sensing scientists whose research spans the gap
> > between
> > environmental accounting/monitoring and policy and human
> > interaction.
> > We have about 5-10 (or so) python users (and potential
> > python users)
> > who could potentially apply new skills to several in-house
> > projects.
> > The difficulty for the teacher would be covering breadth of
> > experience
> > we have currently.
> >
> > Any thoughts or advice would be greatly appreciated.
> > Thanks very
> > much,
> >
> > Greg
> > --
> > http://mail.python.org/mailman/listinfo/python-list
> >
>
>
>
>
>
>
> ---------- Forwarded message ----------
> From: Jason Dixon <jdixon at omniti.com>
> To: python-list at python.org
> Date: Fri, 9 Jul 2010 11:08:19 -0400
> Subject: Last day to submit your Surge 2010 CFP!
> Today is your last chance to submit a CFP abstract for the 2010 Surge
> Scalability Conference.  The event is taking place on Sept 30 and Oct 1,
> 2010 in Baltimore, MD.  Surge focuses on case studies that address
> production failures and the re-engineering efforts that led to victory
> in Web Applications or Internet Architectures.
>
> You can find more information, including suggested topics and our
> current list of speakers, online:
>
> http://omniti.com/surge/2010
>
> The final lineup should be available on the conference website next
> week.  If you have questions about the CFP, attending Surge, or having
> your business sponsor/exhibit at Surge 2010, please contact us at
> surge at omniti.com.
>
> Thanks!
>
> --
> Jason Dixon
> OmniTI Computer Consulting, Inc.
> jdixon at omniti.com
> 443.325.1357 x.241
>
>
>
> ---------- Forwarded message ----------
> From: Massi <massi_srb at msn.com>
> To: python-list at python.org
> Date: Fri, 9 Jul 2010 08:07:23 -0700 (PDT)
> Subject: SqlAlchemy: remote connection on problem on mysql database
> Hi everyone,
>
> in my script I'm trying to connect to a remote database using
> sqlalchemy. Since I'm pretty new to this library I'm not really sure
> of what I am doing :-). Up to now what I'm doing to connect to the
> database is this:
>
> engine = create_engine("mysql://
> my_username:my_password at phpmyadmin.myhost.com/my_db_name")
> metadata = MetaData(engine, reflect=True)
>
> If I run this script I get the following error:
>
> Traceback (most recent call last):
>  File "C:\Documents and Settings\pc2\Desktop\prova.py", line 9, in
> <module>
>    metadata = MetaData(engine, reflect=True)
>  File "C:\Python25\lib\site-packages\sqlalchemy-0.6.0-py2.5.egg
> \sqlalchemy\schema.py", line 1770, in __init__
>    self.reflect()
>  File "C:\Python25\lib\site-packages\sqlalchemy-0.6.0-py2.5.egg
> \sqlalchemy\schema.py", line 1879, in reflect
>    connection=conn))
>  File "c:\python25\lib\site-packages\SQLAlchemy-0.6.0-py2.5.egg
> \sqlalchemy\engine\base.py", line 1604, in table_names
>    conn = self.contextual_connect()
>  File "c:\python25\lib\site-packages\SQLAlchemy-0.6.0-py2.5.egg
> \sqlalchemy\engine\base.py", line 1592, in contextual_connect
>    return self.Connection(self, self.pool.connect(),
> close_with_result=close_with_result, **kwargs)
>  File "c:\python25\lib\site-packages\SQLAlchemy-0.6.0-py2.5.egg
> \sqlalchemy\pool.py", line 154, in connect
>    return _ConnectionFairy(self).checkout()
>  File "c:\python25\lib\site-packages\SQLAlchemy-0.6.0-py2.5.egg
> \sqlalchemy\pool.py", line 318, in __init__
>    rec = self._connection_record = pool.get()
>  File "c:\python25\lib\site-packages\SQLAlchemy-0.6.0-py2.5.egg
> \sqlalchemy\pool.py", line 173, in get
>    return self.do_get()
>  File "c:\python25\lib\site-packages\SQLAlchemy-0.6.0-py2.5.egg
> \sqlalchemy\pool.py", line 665, in do_get
>    con = self.create_connection()
>  File "c:\python25\lib\site-packages\SQLAlchemy-0.6.0-py2.5.egg
> \sqlalchemy\pool.py", line 134, in create_connection
>    return _ConnectionRecord(self)
>  File "c:\python25\lib\site-packages\SQLAlchemy-0.6.0-py2.5.egg
> \sqlalchemy\pool.py", line 209, in __init__
>    self.connection = self.__connect()
>  File "c:\python25\lib\site-packages\SQLAlchemy-0.6.0-py2.5.egg
> \sqlalchemy\pool.py", line 271, in __connect
>    connection = self.__pool._creator()
>  File "c:\python25\lib\site-packages\SQLAlchemy-0.6.0-py2.5.egg
> \sqlalchemy\engine\strategies.py", line 76, in connect
>    return dialect.connect(*cargs, **cparams)
>  File "c:\python25\lib\site-packages\SQLAlchemy-0.6.0-py2.5.egg
> \sqlalchemy\engine\default.py", line 227, in connect
>    return self.dbapi.connect(*cargs, **cparams)
>  File "C:\Python25\lib\site-packages\MySQLdb\__init__.py", line 74,
> in Connect
>    return Connection(*args, **kwargs)
>  File "C:\Python25\lib\site-packages\MySQLdb\connections.py", line
> 170, in __init__
>    super(Connection, self).__init__(*args, **kwargs2)
> OperationalError: (OperationalError) (2003, "Can't connect to MySQL
> server on 'phpmyadmin.myhost.com' (10060)") None None
>
> Is there something I am missing? thanks in advance for the help!
>
>
>
> ---------- Forwarded message ----------
> From: Robin <robin1 at cnsp.com>
> To: python-list at python.org
> Date: Fri, 9 Jul 2010 08:30:31 -0700 (PDT)
> Subject: do
> please, please post a link to my site, http://offlame.thevoid1.net/
>
> also, post free for all links at www.thevoid1.net/ffa
>
> -Robin
>
>
>
> ---------- Forwarded message ----------
> From: Tomasz Rola <rtomek at ceti.com.pl>
> To: python-list at python.org
> Date: Fri, 9 Jul 2010 17:21:15 +0200
> Subject: Re: Opinions please -- how big should a single module grow?
> On Fri, 9 Jul 2010, Tomasz Rola wrote:
>
> > On Fri, 9 Jul 2010, Steven D'Aprano wrote:
> >
> > > This is a style question rather than a programming question.
> > >
> > > How large (how many KB, lines, classes, whatever unit of code you like
> to
> > > measure in) should a module grow before I should break it up into a
> > > package? I see that, for example, decimal.py is > 3000 lines of code,
> so
> > > I can assume that 3 KLOC is acceptable. Presumably 3000 KLOC is not.
> > > Where do you draw the line?
> > >
> > > For the purposes of the discussion, you should consider that the code
> in
> > > the module really does belong together, and that splitting it into sub-
> > > modules would mean arbitrarily separating code into separate files.
> >
> > Myself, I would draw "the line" somewhere between 20-50 KLOC&C (code with
> > comments) - if something takes a lot of place to comment, then maybe it
> > should go to a separate unit.
>
> I meant 2-5 KLOC&C. Oups...
>
> Regards,
> Tomasz Rola
>
> --
> ** A C programmer asked whether computer had Buddha's nature.      **
> ** As the answer, master did "rm -rif" on the programmer's home    **
> ** directory. And then the C programmer became enlightened...      **
> **                                                                 **
> ** Tomasz Rola          mailto:tomasz_rola at bigfoot.com             **
>
>
>
> ---------- Forwarded message ----------
> From: aahz at pythoncraft.com (Aahz)
> To: python-list at python.org
> Date: 9 Jul 2010 08:41:57 -0700
> Subject: Re: Python -- floating point arithmetic
> In article <mailman.426.1278606698.1673.python-list at python.org>,
> Chris Rebert  <clp2 at rebertia.com> wrote:
> >On Thu, Jul 8, 2010 at 8:52 AM, Giacomo Boffi <giacomo.boffi at polimi.it>
> wrote:
> >> "Zooko O'Whielacronx" <zooko at zooko.com> writes:
> >>>
> >>> I'm starting to think that one should use Decimals by default and
> >>> reserve floats for special cases.
> >>
> >> would you kindly lend me your Decimals ruler? i need to measure the
> >> sides of the triangle whose area i have to compute
> >
> >If your ruler doesn't have a [second] set of marks for centimeters and
> >millimeters, that's really one cheap/cruddy ruler you're using.
>
> Unless I'm badly mistaken, Giacomo was making a funny about Greek
> geometers.
> --
> Aahz (aahz at pythoncraft.com)           <*>
> http://www.pythoncraft.com/
>
> "....Normal is what cuts off your sixth finger and your tail..."  --Siobhan
>
>
>
> ---------- Forwarded message ----------
> From: aahz at pythoncraft.com (Aahz)
> To: python-list at python.org
> Date: 9 Jul 2010 08:47:51 -0700
> Subject: Re: 'reload M' doesn't update 'from M inport *'
> In article <mailman.465.1278680555.1673.python-list at python.org>,
> Frederic Rentsch  <anthra.norell at bluewin.ch> wrote:
> >
> >Module M says 'from service import *'.
> >Next I correct a mistake in function 'service.f'.
> >Now 'service.f' works fine.
> >
> >I do 'reload (service); reload (M)'.
> >The function 'M.f' still misbehaves.
>
> Absolutely!
>
> >'print inspect.getsource (service.f)' and
> >'print inspect.getsource (M.f)' shows the same
> >corrected code.
> >
> >'print service.f' and 'print M.f' show different ids.
> >
> >So I do 'del M; reload (M)'. Nothing changes.
> >
> >I delete M again and run gc.collect () to really clean house. I reload
> >M again and still nothing changes.  The id of the reloaded function
> >'M.f' is still the same as it was before the purge and so M.f still
> >isn't fixed.
> >
> >I know I have more radical options, such as starting a new IDLE
> >window. That would save me time, but I'd like to take the opportunity
> >to understand what is happening. Surely someone out there knows.
>
> Take a look at sys.modules to get a better idea of what's happening.
> (Maybe someone else will have time to write a longer answer.)
>
> But really, relying on reload() is foolish in the general case because
> it's nearly impossible to track down every single reference.
> --
> Aahz (aahz at pythoncraft.com)           <*>
> http://www.pythoncraft.com/
>
> "....Normal is what cuts off your sixth finger and your tail..."  --Siobhan
>
>
>
> ---------- Forwarded message ----------
> From: "Alf P. Steinbach /Usenet" <alf.p.steinbach+usenet at gmail.com<alf.p.steinbach%2Busenet at gmail.com>
> >
> To: python-list at python.org
> Date: Fri, 09 Jul 2010 17:52:14 +0200
> Subject: Cpp + Python: static data dynamic initialization in *nix shared
> lib?
> [Cross-posted comp.lang.python and comp.lang.c++]
>
> I lack experience with shared libraries in *nix and so I need to ask...
>
> This is about "cppy", some support for writing Python extensions in C++
> that I just started on (some days ago almost known as "pynis" (not funny
> after all)).
>
> For an extension module it seems that Python requires each routine to be
> defined as 'extern "C"'. And although e.g. MSVC is happy to mix 'extern "C"'
> and C++ linkage, using a routine declared as 'static' in a class as a C
> callback, formally they're two different kinds, and I seem to recall that
> /some/ C++ compiler balks at that kind of mixing unless specially instructed
> to allow it. Perhaps it was the Sun compiler?
>
> Anyway, to be formally correct I cannot generate the required C routines
> via templating, and I ended up using macros that the user must explicitly
> invoke, like, here the Py doc's first extension module example recoded using
> cppy,
>
>
> ------------------------------------------------------------------
> <code file="spam.cpp">
> #include <progrock/cppx/devsupport/better_experience.h>
> #include <progrock/cppy/Module.h>
> using namespace progrock;
>
> class Spam: public cppy::Module
> {
> public:
>    Spam(): cppy::Module( "spam" )
>    {
>        setDocString( L"blåbærsyltetøy er blått" );
>    }
>
>    PyObject* system( PyObject* args )
>    {
>        const char *command;
>        int sts;
>
>        if( !PyArg_ParseTuple( args, "s", &command ) )
>        {
>            return NULL;
>        }
>        sts = ::system( command );
>        return Py_BuildValue( "i", sts );
>    }
> };
>
> CPPY_MODULE_CROUTINE( Spam, system, "Execute a shell command" )
>
> PyMODINIT_FUNC PyInit_spam()
> {
>    return cppy::init< Spam >();
> }
> </code>
> ------------------------------------------------------------------
>
>
> It works in Windows.
>
> But here CPPY_MODULE_CROUTINE does three things:
>
>  A Defining the 'extern "C"' routine.
>    I cannot think of any problem here.
>
>  B Defining installation data for that routine.
>    Possible problem: initializing a static with address of routine?
>
>  C -> Adding that install data record into a linked list!
>    Possible problem: are dynamic initialization actions guaranteed
>    to be performed in *nix shared library?
>
> Problem (C) is outside the realm of the C++ standard, since the C++
> standard doesn't support shared libraries, and I've never actually used *nix
> shared libraries so I don't /know/...
>
> Is such dynamic initialization guaranteed?
>
> For completeness, the macro definition (the 0 in there is a list
> next-pointer):
>
>
> <code>
> #define CPPY_MODULE_CROUTINE_DEF( cppClassName, name )                  \
>    extern "C"                                                          \
>    static PyObject* cppClassName##_##name( PyObject*, PyObject* args ) \
>    {                                                                   \
>        return ::progrock::cppy::module<cppClassName>().name( args );   \
>    }
>
> #define CPPY_MODULE_CROUTINE_INSTALLDATA( cppClassName, name, docString )
> \
>    static ::progrock::cppy::detail::ModuleRoutineDescriptor
>  \
>    cppClassName##_##name##_descriptor = {
>  \
>        0,
>  \
>        #name,
>  \
>        docString,
>  \
>        &cppClassName##_##name
>  \
>        };
>  \
>
>  \
>    static bool cppClassName##_##name##_descriptor_installed =
>  \
>        ::progrock::cppy::detail::addToList< cppClassName >(
>  \
>            cppClassName##_##name##_descriptor
>  \
>            );
>
> #define CPPY_MODULE_CROUTINE( cppClassName, name, docString )
> \
>    CPPY_MODULE_CROUTINE_DEF( cppClassName, name )
>  \
>    CPPY_MODULE_CROUTINE_INSTALLDATA( cppClassName, name, docString )
> </code>
>
>
> TIA.,
>
> - Alf
>
> --
> blog at <url: http://alfps.wordpress.com>
>
>
>
> ---------- Forwarded message ----------
> From: crow <wentlv at gmail.com>
> To: python-list at python.org
> Date: Fri, 9 Jul 2010 08:58:35 -0700 (PDT)
> Subject: Why there is no "setdefaultencoding" in sys module?
> Hi, everyone
>
> I'm a new hand at python.
>
> I tried to set system default encoding by using
>
>    "import sys; sys.setdefaultencoding('utf-f')",
>
> but I got error message:
>
> >>> sys.setdefaultencoding('utf-8')
> Traceback (most recent call last):
>  File "<stdin>", line 1, in <module>
> AttributeError: 'module' object has no attribute 'setdefaultencoding'
>
> Then I checked dir(sys), seems there was no function named
> "setdefaultencoding" in "sys" module. But in python's document, it
> said I should use sys.setdefaultencoding.
>
> So, my questions: why there is no setdefaultencoding in sys module? if
> I want to change system's default encoding, what should I do?
>
> Thanks in advance
>
>
> --
> http://mail.python.org/mailman/listinfo/python-list
>



-- 
Nitin Pawar
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20100709/5c6571f3/attachment.html>


More information about the Python-list mailing list