
GITHUB . COM {
}
Detected CMS Systems:
- Wordpress (2 occurrences)
Title:
ImportWarning: can't resolve package from __spec__ or __package__ Β· Issue #3061 Β· pytest-dev/pytest
Description:
Given the following directory structuce: . βββ tests βββ conftest.py βββ __init__.py βββ relative.py βββ test_foo.py With tests/conftest.py: from .relative import relative print("conftest") tests/relative.py: relative = 1 tests/test_foo....
Website Age:
17 years and 8 months (reg. 2007-10-09).
Matching Content Categories {π}
- Shopping
- Business & Finance
- Technology & Computing
Content Management System {π}
What CMS is github.com built with?
Github.com relies on WORDPRESS.
Traffic Estimate {π}
What is the average monthly size of github.com audience?
ππ Tremendous Traffic: 10M - 20M visitors per month
Based on our best estimate, this website will receive around 10,000,019 visitors per month in the current month.
However, some sources were not loaded, we suggest to reload the page to get complete results.
check SE Ranking
check Ahrefs
check Similarweb
check Ubersuggest
check Semrush
How Does Github.com Make Money? {πΈ}
Subscription Packages {π³}
We've located a dedicated page on github.com that might include details about subscription plans or recurring payments. We identified it based on the word pricing in one of its internal links. Below, you'll find additional estimates for its monthly recurring revenues.How Much Does Github.com Make? {π°}
Subscription Packages {π³}
Prices on github.com are in US Dollars ($).
They range from $4.00/month to $21.00/month.
We estimate that the site has approximately 4,989,889 paying customers.
The estimated monthly recurring revenue (MRR) is $20,957,532.
The estimated annual recurring revenues (ARR) are $251,490,385.
Wordpress Themes and Plugins {π¨}
What WordPress theme does this site use?
It is strange but we were not able to detect any theme on the page.
What WordPress plugins does this website use?
It is strange but we were not able to detect any plugins on the page.
Keywords {π}
package, importwarning, relative, import, resolve, spec, pytest, commented, plugin, issue, falling, back, path, nicoddemus, warnings, asottile, related, tests, member, sign, blueyed, ignore, collection, builtin, debugging, projects, pythonwarningsall, deprecationwarning, deprecated, contributor, added, importwarnings, resolution, cpythonlibsitepackagespytestcovpluginpy, navigation, pull, requests, actions, security, opened, testsconftestpy, teststestfoopy, shows, imp, module, platform, python, pluggy, pytestdevpytestdjango, comment,
Topics {βοΈ}
οΏ½/pyenv/tmp-system-importwarning-znifie/lib/python3 import imp β¦/vcs/pytest/importwarning/tests/conftest /tmp/foo/venv/lib/python3 5\lib\site-packages\pytest_cov\plugin οΏ½/vcs/pytest/_pytest/assertion/rewrite 5\lib\site-packages\pytest_cov\engine 6/site-packages/_pytest/fixtures +/tmp/foo/tests/conftest relative import relative compat import stringio activity blueyed mentioned explicit relative imports 4af623e nicoddemus mentioned assigned labels plugin pytest-django pytest-cov issue personal information importwarning proper fix import engine py36-xdist suite οΏ½/vcs/pytest nicoddemus added building module objects comment metadata assignees collection phase type type projects test tests projects milestone import embed tests/relative contributor tests/conftest pytest tests pytest-xdist imp module warnings related similar warnings = open package resolution separate issue debugging related def test_foo ignore importwarnings assert rewriting collection related resolve package 6/site txt --- assert_plain directory structuce conftest
Payment Methods {π}
- Braintree
Questions {β}
- Already have an account?
- Anybody knows what's the proper fix here?
- Ping @flub - any idea?
Schema {πΊοΈ}
DiscussionForumPosting:
context:https://schema.org
headline:ImportWarning: can't resolve package from __spec__ or __package__
articleBody:Given the following directory structuce:
```
.
βββ tests
βββ conftest.py
βββ __init__.py
βββ relative.py
βββ test_foo.py
```
With `tests/conftest.py`:
```python
from .relative import relative
print("conftest")
```
`tests/relative.py`:
```python
relative = 1
```
`tests/test_foo.py`:
```python
def test_foo():
pass
```
Running `PYTHONWARNINGS=all pytest tests -s` shows:
```
β¦/pyenv/tmp-system-ImportWarning-ZniFiE/lib/python3.6/site.py:165: DeprecationWarning: 'U' mode is deprecated
f = open(fullname, "rU")
β¦/Vcs/pytest/_pytest/assertion/rewrite.py:7: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses
import imp
β¦/Vcs/pytest/ImportWarning/tests/conftest.py:1: ImportWarning: can't resolve package from __spec__ or __package__, falling back on __name__ and __path__
from .relative import relative
conftest
==================================== test session starts ====================================
platform linux -- Python 3.6.3, pytest-3.3.2.dev14+gd3b54d03.d20171225, py-1.5.2, pluggy-0.6.0
rootdir: β¦/Vcs/pytest, inifile: tox.ini
collected 1 item
tests/test_foo.py . [100%]
================================= 1 passed in 0.01 seconds ==================================
```
The ImportWarning is:
> tests/conftest.py:1: ImportWarning: can't resolve package from __spec__ or __package__, falling back on __name__ and __path__
> from .relative import relative
>
It only shows up when using `-s`.
This came up for pytest-django.
See https://github.com/pytest-dev/pytest-django/pull/546#issuecomment-353873511.
Defining `__package__` explicitly fixes it, but it looks like this should not be necessary.
author:
url:https://github.com/blueyed
type:Person
name:blueyed
datePublished:2017-12-25T15:13:28.000Z
interactionStatistic:
type:InteractionCounter
interactionType:https://schema.org/CommentAction
userInteractionCount:13
url:https://github.com/3061/pytest/issues/3061
context:https://schema.org
headline:ImportWarning: can't resolve package from __spec__ or __package__
articleBody:Given the following directory structuce:
```
.
βββ tests
βββ conftest.py
βββ __init__.py
βββ relative.py
βββ test_foo.py
```
With `tests/conftest.py`:
```python
from .relative import relative
print("conftest")
```
`tests/relative.py`:
```python
relative = 1
```
`tests/test_foo.py`:
```python
def test_foo():
pass
```
Running `PYTHONWARNINGS=all pytest tests -s` shows:
```
β¦/pyenv/tmp-system-ImportWarning-ZniFiE/lib/python3.6/site.py:165: DeprecationWarning: 'U' mode is deprecated
f = open(fullname, "rU")
β¦/Vcs/pytest/_pytest/assertion/rewrite.py:7: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses
import imp
β¦/Vcs/pytest/ImportWarning/tests/conftest.py:1: ImportWarning: can't resolve package from __spec__ or __package__, falling back on __name__ and __path__
from .relative import relative
conftest
==================================== test session starts ====================================
platform linux -- Python 3.6.3, pytest-3.3.2.dev14+gd3b54d03.d20171225, py-1.5.2, pluggy-0.6.0
rootdir: β¦/Vcs/pytest, inifile: tox.ini
collected 1 item
tests/test_foo.py . [100%]
================================= 1 passed in 0.01 seconds ==================================
```
The ImportWarning is:
> tests/conftest.py:1: ImportWarning: can't resolve package from __spec__ or __package__, falling back on __name__ and __path__
> from .relative import relative
>
It only shows up when using `-s`.
This came up for pytest-django.
See https://github.com/pytest-dev/pytest-django/pull/546#issuecomment-353873511.
Defining `__package__` explicitly fixes it, but it looks like this should not be necessary.
author:
url:https://github.com/blueyed
type:Person
name:blueyed
datePublished:2017-12-25T15:13:28.000Z
interactionStatistic:
type:InteractionCounter
interactionType:https://schema.org/CommentAction
userInteractionCount:13
url:https://github.com/3061/pytest/issues/3061
Person:
url:https://github.com/blueyed
name:blueyed
url:https://github.com/blueyed
name:blueyed
InteractionCounter:
interactionType:https://schema.org/CommentAction
userInteractionCount:13
interactionType:https://schema.org/CommentAction
userInteractionCount:13
External Links {π}(4)
Analytics and Tracking {π}
- Site Verification - Google
Libraries {π}
- Clipboard.js
- D3.js
- Lodash
Emails and Hosting {βοΈ}
Mail Servers:
- aspmx.l.google.com
- alt1.aspmx.l.google.com
- alt2.aspmx.l.google.com
- alt3.aspmx.l.google.com
- alt4.aspmx.l.google.com
Name Servers:
- dns1.p08.nsone.net
- dns2.p08.nsone.net
- dns3.p08.nsone.net
- dns4.p08.nsone.net
- ns-1283.awsdns-32.org
- ns-1707.awsdns-21.co.uk
- ns-421.awsdns-52.com
- ns-520.awsdns-01.net