Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing __init__.py files & let setup.py find all importable packages on its own #879

Merged
merged 3 commits into from
Oct 21, 2022

Conversation

da-h
Copy link
Contributor

@da-h da-h commented Oct 20, 2022

Description

In the recent refactoring in #858 I've missed to tell setup.py about the new python directories.
This results in visdom to be effectively broken when installed from pip or setup.py.

The solution is quite easy:

  • adding all missing __init__.py files
  • tell setup.py about the new directories. I have solved this by using the automatic setuptools.find_packages method.

This should also solve #878, who has pointed out the error.

How Has This Been Tested?

Running locally python setup.py install --user works now as expected.

Note

Maybe it would be best to install visdom using setup.py for all tests so this does not happen again?

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Code refactor or cleanup (changes to existing code for improved readability or performance)

Checklist:

  • I adapted the version number under py/visdom/VERSION according to Semantic Versioning
    A nothing has changed really, I added a .post1 to the version.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.

@JackUrb
Copy link
Contributor

JackUrb commented Oct 20, 2022

The visual regression test is failing as we need to update that to no longer reference server.py. We should do a check to see if that string exists anywhere in the codebase before merging.

@da-h
Copy link
Contributor Author

da-h commented Oct 20, 2022

Thx for looking into this. I have submitted a PR (#880) to fix this error.

Also, regarding all the warnings below recent github-actions, it seems there are some more things to be done to modernize workflows to newer github apis.
I will submit a separate PR to tackle the warnings soon.

@da-h da-h changed the title Fix missing init file & let setup.py find all importable packages on its own Fix missing inits file & let setup.py find all importable packages on its own Oct 20, 2022
@da-h da-h changed the title Fix missing inits file & let setup.py find all importable packages on its own Add missing inits files & let setup.py find all importable packages on its own Oct 20, 2022
@da-h da-h changed the title Add missing inits files & let setup.py find all importable packages on its own Add missing __ files & let setup.py find all importable packages on its own Oct 21, 2022
@da-h da-h changed the title Add missing __ files & let setup.py find all importable packages on its own Add missing __init__.py files & let setup.py find all importable packages on its own Oct 21, 2022
@JackUrb JackUrb merged commit 8a10c78 into fossasia:master Oct 21, 2022
@da-h da-h deleted the fix_missing_init_file branch October 21, 2022 14:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants