473,394 Members | 1,951 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Re: Relative imports and "import X as Y"

So, will relative imports in Python 3.0 allow things like "import
..relative.importing.path as prettyname"? If not, why not?
Download the latest beta for your system and give it a try.

Aug 30 '08 #1
4 935
Terry Reedy wrote:
>
> So, will relative imports in Python 3.0 allow things like
"import
..relative.importing.path as prettyname"? If not, why not?

Download the latest beta for your system and give it a try.
Thanks for the advice, but I'd really rather not deal with
installing the entire thing alongside my existing version, possibly
causing conflicts in who knows what ways.

--
--OKB (not okblacke)
Brendan Barnwell
"Do not follow where the path may lead. Go, instead, where there is
no path, and leave a trail."
--author unknown
Aug 31 '08 #2
On Sun, 31 Aug 2008 06:40:35 GMT, OKB (not okblacke) wrote:
>Download the latest beta for your system and give it a try.

Thanks for the advice, but I'd really rather not deal with
installing the entire thing alongside my existing version, possibly
causing conflicts in who knows what ways.
Then you can download tar.gz package, compile it, and try it
without installing :-)

--
Regards,
Wojtek Walczak,
http://tosh.pl/gminick/
Aug 31 '08 #3
En Sun, 31 Aug 2008 07:27:12 -0300, Wojtek Walczak <gm*****@bzt.bztescribió:
On Sun, 31 Aug 2008 06:40:35 GMT, OKB (not okblacke) wrote:
>>Download the latest beta for your system and give it a try.

Thanks for the advice, but I'd really rather not deal with
installing the entire thing alongside my existing version, possibly
causing conflicts in who knows what ways.

Then you can download tar.gz package, compile it, and try it
without installing :-)
Or use a virtual machine, or a live CD.

--
Gabriel Genellina

Sep 2 '08 #4
Gabriel Genellina wrote:
En Sun, 31 Aug 2008 07:27:12 -0300, Wojtek Walczak
<gm*****@bzt.bztescribió:
>On Sun, 31 Aug 2008 06:40:35 GMT, OKB (not okblacke) wrote:
>>>Download the latest beta for your system and give it a try.

Thanks for the advice, but I'd really rather not deal
with
installing the entire thing alongside my existing version,
possibly causing conflicts in who knows what ways.

Then you can download tar.gz package, compile it, and try it
without installing :-)

Or use a virtual machine, or a live CD.
Gosh, thanks, everyone, for being so helpful!

--
--OKB (not okblacke)
Brendan Barnwell
"Do not follow where the path may lead. Go, instead, where there is
no path, and leave a trail."
--author unknown
Sep 2 '08 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: peter | last post by:
Hello all, I've read all the posts concerning relative imports of modules and I am glad I saw some consensus on a syntax. At this moment I am however bound to python 2.3. Does anyone know a...
2
by: LesleyW | last post by:
I'm using a public set of schemas for GML, avaiable at www.opengis.net/gml. They all include or import each other but live in a folder hierarchy, so the import statement includes...
0
by: Anders J. Munch | last post by:
Now 2.5 is out, and we have a syntax for explicit relative imports (PEP 328, http://www.python.org/dev/peps/pep-0328/, in case anyone wasn't paying attention). The long-term plan is that the...
1
by: Alexey Borzenkov | last post by:
After reading PEP-0328 I wanted to give relative imports a try: # somepkg/__init__.py <empty> # somepkg/test1.py from __future__ import absolute_import from . import test2 if __name__ ==...
0
by: Alan Isaac | last post by:
I'm new to relative imports and having a problem. (ValueError: Attempted relative import in non-package) I noticed this: http://www.thescripts.com/forum/thread549516.html Is this behavior...
12
by: Alan Isaac | last post by:
Are relative imports broken in 2.5? Directory ``temp`` contains:: __init__.py test1.py test2.py File contents: __init__.py and test2.py are empty test1.py contains a single line::
0
by: Alan Isaac | last post by:
What is the recommended packaging of demo scripts or test scripts for a package that has modules that use relative imports? Example: Suppose I have the package structure: package/...
0
by: Stef Mientki | last post by:
hello, I'm running Python 2.5 and want my programs to run at least under Windows and Linux (preferable also Mac). So I guess I should always use relative paths. From most modules I can call a...
0
by: Gabriel Genellina | last post by:
En Sat, 18 Oct 2008 05:52:04 -0300, Stef Mientki <stef.mientki@gmail.com> escribió: Why don't you let the caller tell you its own location, using __file__? The above code is too much magic for...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.