Uh oh!
There was an error while loading. Please reload this page.
#391 build test fixes - #392
Conversation
ipv6 idea (not includeded in PR):diff --git a/nginx/testcontainers/nginx/__init__.py b/nginx/testcontainers/nginx/__init__.py
index d0680f1..c4bcbf7 100644
--- a/nginx/testcontainers/nginx/__init__.py+++ b/nginx/testcontainers/nginx/__init__.py@@ -37,5 +37,14 @@ class NginxContainer(DockerContainer):
@wait_container_is_ready(urllib.error.URLError)
def _connect(self, host: str, port: str) -> None:
- url = urllib.parse.urlunsplit(('http', f'{host}:{port}', '', '', ''))+ url = urllib.parse.urlunsplit(('http', self._netloc_of(host, port), '', '', ''))
urllib.request.urlopen(url, timeout=1)
++ @staticmethod+ def _netloc_of(host: str, port: str):+ import ipaddress+ try:+ version = ipaddress.ip_address(host).version+ return f"{host if version == 4 else f'[{host}]'}:{port}"+ except ValueError: # when "localhost" instead of ip+ return f'{host}:{port}' |
alexanderankin
commented
Nov 10, 2023
one other potential failure is the lack of python-dev package as its necessary to compile some c code for oracle db driver, but i think this is easy enough to add once we see that this is why it fails. |
kiview
commented
Nov 10, 2023
We have dabbled with the IPv4 & IPv6 topic in the other Testcontainers languages, and I think we have a robust approach for this. But let's move it out of the scope of this PR 👍 |
kiview
commented
Nov 13, 2023
Great, all tests are green now 👍 @alexanderankin could you please add a description to the PR detailing some of the changes and the rationale behind it, for future documentation? |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
…ose no longer depends on docker-compose
| # via | ||
| # docker-compose | ||
| # testcontainers-core | ||
| docker-compose==1.29.2 |
There was a problem hiding this comment.
I don't think these files should be manually edited, since they contain the following comment:
# This file is autogenerated by pip-compile with Python 3.10
# by the following command:
#
# pip-compile --output-file=requirements.txt --resolver=backtracking
There was a problem hiding this comment.
That is true but I cannot auto generate this with the required os/env.
kiview
commented
Nov 16, 2023
Unfortunately, the build still fails on MacOS because of issues installing |
@kiview@alexanderankin Because of the issue with It's related to the feetds build dependency for I am using MacPorts. This way it works for me: If you use Homebrew you need to point the flags to your library directories. I just pulled the latest main branch and I can install the dependencies. Thanks a lot for your help here. Much appreciated. |
alexanderankin
commented
Nov 28, 2023
it seems like a strong argument to drop the dependency or make it optional |
max-pfeiffer
commented
Dec 2, 2023
Well, isn't it already optional when using the package? You could just install the features you need: As a software engineer I do not mind tackling with these kind of problems when working on the package and/or building it. It's a common problem on MacOs that sometimes dependencies are a bit cumbersome to install and configure. I would advocate to add a wiki section to the project as a go-to place for such problems. Other projects like pyenv do it like this: https://github.com/pyenv/pyenv/wiki/Common-build-problems We still need to fix the tests on MacOs. I noticed a bunch of tests failing when working my pull request #389. This is due to older image versions not supporting ARM CPUs. Is there any chance we can get #357 merged? I would also volunteer to work on it if help is needed there. |
alexanderankin
commented
Dec 12, 2023
i think there are some neat things in this PR we should merge but its no longer productive to keep this open in its current form: closing. |
alexanderankin
commented
Dec 12, 2023
ive also very recently gotten a mac so "excited" ( 🙂 ) to get familiar with those issues and if i can, help/start to document |
this pull request updates the code so that tests are green when code is correct. it was flaky before, and some code outdated, giving false negative result
opened re: #391