<html><head><style type="text/css" media="screen">Body{font-family: Verdana;font-size:.75em;}h4{font-size:.9em;}a{color: #3a62a6;}.digest .toc {margin-bottom: 15px; padding-bottom:8px; border-bottom: 1px solid #ccc;}.digest .tocItem {margin-bottom: 15px;}.tocItem a{color:#000;text-decoration: none;}.tocItem a:hover{color: #3a62a6;text-decoration: underline;}.topic{padding-bottom: 8px;margin-bottom: 20px; border-bottom: 1px solid #ccc;}.topicHeader{margin-bottom:10px;}.topicTitle{font-weight: bold;}.replies p{margin:0;padding:0;}.replies hr{width: 15%;text-align: left;margin: 0 auto 5px 0;border: none 0;border-top: 1px solid #ccc;height: 1px;}.reply{margin-bottom: 6px;padding-bottom: 4px;}.anchorMarker{color: #3a62a6;}.footer{color: gray;}</style></head><body><div class="digest"><p>Hi ironpython,</p><p>Here's your Daily Digest of new issues for project "<a href="http://ironpython.codeplex.com/">IronPython</a>".</p><p>In today's digest:</p><h4>ISSUES</h4><div class="toc"><div class="tocItem"><a href="#toc_issue_1">1. <span class="tocTitle">[New issue] Relative import in non-package error</span> <span class="anchorMarker">↓</span></a></div><div class="tocItem"><a href="#toc_issue_2">2. <span class="tocTitle">[New comment] Relative import in non-package error</span> <span class="anchorMarker">↓</span></a></div><div class="tocItem"><a href="#toc_issue_3">3. <span class="tocTitle">[New comment] Relative import in non-package error</span> <span class="anchorMarker">↓</span></a></div><div class="tocItem"><a href="#toc_issue_4">4. <span class="tocTitle">[New comment] Relative import in non-package error</span> <span class="anchorMarker">↓</span></a></div><div class="tocItem"><a href="#toc_issue_5">5. <span class="tocTitle">[New comment] Relative import in non-package error</span> <span class="anchorMarker">↓</span></a></div></div><h4>ISSUES</h4><div class="topic"><a name="toc_issue_1"></a><div class="topicHeader"><span class="topicTitle">1. [New issue] Relative import in non-package error</span> <a href="http://ironpython.codeplex.com/workitem/32916">view online</a></div><p>User loocas has proposed the issue:</p><p>"Hi,<br /><br />I'm having trouble with relative path imports in IronPython 2.7.3.<br /><br />I add paths to the modules in my code (via sys.path.append()) so the modules are accessible. However, one of the modules I'm trying to import contains the following relative path import statement:<br /><br />from .lib.httplib2 import Http, ProxyInfo, socks<br /><br />When IronPython is trying to import the modules it errors out with this stderr:<br /><br />Traceback (most recent call last):<br /> File "<stdin>", line 1, in <module><br /> File "C:\duber\Shotgun\3.0.9b2\shotgun.py", line 52, in <module><br />ValueError: Attempted relative import in non-package<br /><br />As soon as I remove the relative path notation (deleting the first dot from the import statement), all runs smoothly without issues.<br /><br />If you want to try this exact scenario out, here is an article about what is needed in order to run the Shotgun API: http://blog.duber.cz/software/calling-shotgun-api-3-0-9b2-from-ironpython-2-7-3"</p></div><div class="topic"><a name="toc_issue_2"></a><div class="topicHeader"><span class="topicTitle">2. [New comment] Relative import in non-package error</span> <a href="http://ironpython.codeplex.com/workitem/32916">view online</a></div><p>User slide_o_mix has commented on the issue:</p><p>"Can you verify if this works on CPython 2.7.3? From what I have read regarding relative imports, relative imports only work on packages. The blog post you mention shows that you are trying to import from lib\ which is a subdirectory for the shotgun api code, is there an __init__,py in the lib directory?"</p></div><div class="topic"><a name="toc_issue_3"></a><div class="topicHeader"><span class="topicTitle">3. [New comment] Relative import in non-package error</span> <a href="http://ironpython.codeplex.com/workitem/32916">view online</a></div><p>User loocas has commented on the issue:</p><p>"Hi, yes, there is __init__.py in the lib directory.<br /><br />And actually, no, it doesn't seem to be working in CPython 2.7.2 :/ I don't have any other CPython installed here, so I can't verify that on any other version.<br /><br />I got prompted to report this issue here from one of my commenters, so I did. :D I don't have any experience with relative path name imports, to be honest."</p></div><div class="topic"><a name="toc_issue_4"></a><div class="topicHeader"><span class="topicTitle">4. [New comment] Relative import in non-package error</span> <a href="http://ironpython.codeplex.com/workitem/32916">view online</a></div><p>User slide_o_mix has commented on the issue:</p><p>"Is the __init__.py empty? <br /><br />It was me who asked you to report the issue, I saw the info on twitter and wanted to make sure the issue was captured and figured out if possible."</p></div><div class="topic"><a name="toc_issue_5"></a><div class="topicHeader"><span class="topicTitle">5. [New comment] Relative import in non-package error</span> <a href="http://ironpython.codeplex.com/workitem/32916">view online</a></div><p>User loocas has commented on the issue:</p><p>"Yes, the __init__.py under the lib folder is empty."</p></div><div class="footer"><p>You are receiving this email because you subscribed to notifications on CodePlex.</p><p>To report a bug, request a feature, or add a comment, visit <a href="http://ironpython.codeplex.com/workitem/list/basic">IronPython Issue Tracker</a>. You can <a href="https://ironpython.codeplex.com/subscriptions/workitem/project/edit">unsubscribe or change your issue notification settings</a> on CodePlex.com.</p></div></div></body></html>