incalculable-hydrogen-44003
09/13/2022, 11:05 PMDuplicate module named {xxxx}
and it looks like there isn't much of a workaround for itfaint-businessperson-86903
09/13/2022, 11:17 PMflaky-artist-57016
09/14/2022, 1:16 PM./pants lint ::
would succeed locally and then fail on some files on the same branch in CI? This has happened once or twice on my team. Recloning the branch into a new directory and running ./pants fmt ::
properly catches the files that need reformatting. Could it be a local cache issue?quick-apartment-97325
09/14/2022, 7:25 PM2.13.0
I was using a common Dockerfile for multiple targets and referring to it with a relative path:
docker_image(
name="docker",
source="../Dockerfile.prod",
...
)
After upgrading to 2.13.0
I am now getting:
I have tried creating aCopy codeInvalidFieldException: The 'source' field in target xxx:docker should not include `../` patterns because targets can only have sources in the current directory or subdirectories
files
target and including it into docker_image.dependencies
but am not having any luck with that either
Is there another way I should try? Should I open an issue to track on GH?narrow-activity-17405
09/15/2022, 5:57 AM./pants --changed-since=origin/master --changed-dependees=transitive test
but for building images 🙂bumpy-spoon-55438
09/15/2022, 6:56 AMgo generate
before compiling?cold-vr-15232
09/15/2022, 8:35 AMcold-vr-15232
09/15/2022, 8:52 AMcold-vr-15232
09/15/2022, 8:53 AMaverage-balloon-31442
09/15/2022, 9:20 AMExceeded timeout of 600.0 seconds when executing local process: Run Pytest for …
cold-vr-15232
09/15/2022, 9:36 AMpants generate-lockfiles
and it just sits there counting up the time, it's at over 5 minutes now. How can I see what the problem is? -ldebug
shows that the pex command is started, but nothing more than that....cold-vr-15232
09/15/2022, 9:47 AMaverage-balloon-31442
09/15/2022, 9:56 AM./pants test --test-timeout-default=20 --test-output=all ::
12:53:30.71 [WARN] Failed to generate coverage data for python/projects/…/test.py:../integration-tests.
12:53:30.73 [WARN] Failed to generate JUnit XML data for python/projects/…/test.py:../integration-tests.
12:53:30.73 [ERROR] Completed: Run Pytest - python/projects/…/test.py:../integration-tests failed (exit code -15).
Exceeded timeout of 20.0 seconds when executing local process: Run Pytest for python/projects/…/test.py:../integration-tests:../integration-tests
✕ python/projects/…/test.py:integration-tests failed in 20.04s.
So, either using --test-output=all
I cannot see logs 😞average-balloon-31442
09/15/2022, 10:10 AM2.14.0a0
average-balloon-31442
09/15/2022, 10:11 AM./pants test --test-output=all ::
then I’ll see output of all tests. So, test timeout somehow remove the logs?faint-waitress-55925
09/15/2022, 11:21 AM.env
file and get the values with python-dotenv
. Here is a quick example:
import os
from dotenv import load_dotenv
load_dotenv()
if __name__ == "__main__":
print(os.environ["ENVVAR"])
I have a .env
file with ENVVAR=test
. When I run
using Pants 2.12.0 it prints "test"
without problem but I get this in Pants 2.13.0:
File "/tmp/pants-sandbox-9ZiWSR/tasks/helloworld/main.py", line 7, in <module>
print(os.environ["ENVVAR"])
File "/home/soheil/.pyenv/versions/3.10.6/lib/python3.10/os.py", line 679, in __getitem__
raise KeyError(key) from None
KeyError: 'ENVVAR'
Any recommendation?bitter-ability-32190
09/15/2022, 11:45 AMwarn
in it's code. However work done is memoized in the daemon, so realistically you'll see it when you restart daemon or don't use itbitter-ability-32190
09/15/2022, 11:47 AMcold-vr-15232
09/15/2022, 12:17 PMbitter-ability-32190
09/15/2022, 1:02 PMbitter-ability-32190
09/15/2022, 2:26 PMbitter-ability-32190
09/15/2022, 2:28 PMrun
sandbox was under the build root .pants.d
but now it's under /tmp
.
You should declare a file
target for your .env
file and make sure the right targets depend on it, so it shows up in the sandboxfaint-waitress-55925
09/15/2022, 2:32 PM.env
file in the root folder and a tasks/
folder in which I have several Python project which are configured with environment variables. I deploy the PEX files in Amazon ECS in container images, and the environment variables is automatically set in the container in production. But during development I want to rely on an .env
file.faint-waitress-55925
09/15/2022, 2:32 PMbitter-ability-32190
09/15/2022, 2:37 PMmodern-manchester-33562
09/15/2022, 2:54 PMpytorch
. What we would like is to use the regular upstream version e.g. 1.12.1
for all OSes except Linux, where we want to use 1.12.1+cpu
. Our issue being that the upstream Linux wheel is very large and we don't use any of the capabilities included in the Linux wheel. The CPU one would suit us just fine. However, as soon as we add an index that contains any local versions it always only select a suitable package for the current platform (OS), ignoring all the other ones. This results in incompatible dependency error on other platforms than the one that generated the lockfile. The only solution that seems to work is to use the version upstream (pypi) but, as I said, then we unfortunately use the very large wheels for Linux. Any recommendations on how to solve / circumvent this issue?hundreds-father-404
09/15/2022, 3:21 PM[GLOBAL]
unmatched_build_file_globs = "error"
hundreds-father-404
09/15/2022, 3:22 PMbitter-ability-32190
09/15/2022, 3:24 PMcold-vr-15232
09/15/2022, 4:46 PM