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

Fix #189: Add initial support for networks #207

Merged
merged 10 commits into from
Mar 19, 2018
Merged

Fix #189: Add initial support for networks #207

merged 10 commits into from
Mar 19, 2018

Conversation

apatrushev
Copy link
Contributor

@apatrushev apatrushev commented Mar 13, 2018

What do these changes do?

Add initial and thin networks support (same as volumes).

Are there changes in behavior for the user?

New attribute available in docker object - networks.

Related issue number

#189

Checklist

  • I think the code is well written
  • Unit tests for the changes exist
  • Documentation reflects the changes
  • If you provide code modification, please add yourself to CONTRIBUTORS.txt
    • The format is <Name> <Surname>.
    • Please keep alphabetical order, the file is sorted by names.
  • Add a new news fragment into the changes folder
    • name it <issue_id>.<type> for example (588.bug)
    • if you don't have an issue_id change it to the pr id after creating the pr
    • ensure type is one of the following:
      • .feature: Signifying a new feature.
      • .bugfix: Signifying a bug fix.
      • .doc: Signifying a documentation improvement.
      • .removal: Signifying a deprecation or removal of public API.
      • .misc: A ticket has been closed, but it is not of interest to users.
    • Make sure to use full sentences with correct case and punctuation, for example: "Fix issue with non-ascii contents in doctest text files."

@apatrushev
Copy link
Contributor Author

Seems that tests are broken by unrelated reasons.

@barrachri
Copy link

Hi @apatrushev, check flake8 aiodocker/networks.py:51:9: F841 local variable 'response' is assigned to but never used

@codecov
Copy link

codecov bot commented Mar 13, 2018

Codecov Report

Merging #207 into master will increase coverage by 0.56%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master    #207      +/-   ##
=========================================
+ Coverage   83.23%   83.8%   +0.56%     
=========================================
  Files          18      19       +1     
  Lines         853     883      +30     
=========================================
+ Hits          710     740      +30     
  Misses        143     143
Impacted Files Coverage Δ
aiodocker/networks.py 100% <100%> (ø)
aiodocker/docker.py 80.48% <100%> (+0.32%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3e84389...dd1a3a3. Read the comment docs.

@apatrushev
Copy link
Contributor Author

Sorry for such long story in this PR - I was not sure about tests organization and how to run them locally. Now everything should be fine.

@barrachri
Copy link

thanks @apatrushev !

do you mind adding the docstrings for each method? Even something short is fine.

@barrachri
Copy link

barrachri commented Mar 13, 2018

also can you add a test for connect and disconnect?

@apatrushev
Copy link
Contributor Author

Sorry, I think that current abstraction is very low level and comments will be useless. Almost all methods in this library are thin wrappers around Docker Engine API calls and best docstring is a link to Docker Engine API.

I will add tests for [dis]connect methods.

@apatrushev
Copy link
Contributor Author

apatrushev commented Mar 15, 2018

Ok. I added the tests for [dis]connect network methods. Now tests definitely was broken by unrelated reasons.

@barrachri
Copy link

Thanks @apatrushev !

@barrachri barrachri merged commit c4c0822 into aio-libs:master Mar 19, 2018
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