https://pantsbuild.org/ logo
#general
Title
# general
c

careful-mechanic-89327

04/04/2023, 10:32 AM
Hi guys, I would like to ask for a issue I have in my Mac. Lately I am having this issue when I have try to compile some scala code:
Copy code
12:24:56.74 [ERROR] 1 Exception encountered:

Engine traceback:
  in select
  in pants.core.goals.check.check
  in pants.backend.scala.goals.check.scalac_check (scalac)
  in pants.backend.scala.compile.scalac.compile_scala_source
  in pants.jvm.compile.compile_classpath_entries
  in pants.jvm.resources.assemble_resources_jar
  in pants.engine.process.fallible_to_exec_result_or_raise
Traceback (most recent call last):
  File "/Users/jbenito/.cache/pants/setup/bootstrap-Darwin-x86_64/pants.1Nnv7r/install/lib/python3.9/site-packages/pants/engine/process.py", line 275, in fallible_to_exec_result_or_raise
    raise ProcessExecutionFailure(
pants.engine.process.ProcessExecutionFailure: Process 'Build resources JAR for sdk/transport-security-web-lib/src/test/resources:resources' failed with exit code 1.
stdout:

stderr:
/usr/bin/touch: illegal option -- d
usage:
touch [-A [-][[hh]mm]SS] [-acfhm] [-r file] [-t [[CC]YY]MMDDhhmm[.SS]] file ...
Do you have why this could be happening? Thanks in advance
e

enough-analyst-54434

04/04/2023, 12:44 PM
This looks like it's a bug introduced in Pants 2.15.0.dev3 by: https://github.com/pantsbuild/pants/pull/16950 That PR uses GNU / Linux
touch -d ...
where BSD / Mac need
touch -t ...
.
c

careful-mechanic-89327

04/04/2023, 12:49 PM
🤔 I am using version
2.14.0
e

enough-analyst-54434

04/04/2023, 12:51 PM
Let me look more but it's going to be the same answer. I've filed https://github.com/pantsbuild/pants/issues/18671
c

careful-mechanic-89327

04/04/2023, 12:52 PM
so, I should update to
2.15
?
e

enough-analyst-54434

04/04/2023, 12:55 PM
So only 2.13.0 is safe until that bug is fixed.
so, I should update to 2.15 ?
@careful-mechanic-89327 no. From what I can tell the bug is present in 2.13.1 and newer.
c

careful-mechanic-89327

04/04/2023, 1:00 PM
👍 thanks for the info
e

enough-analyst-54434

04/04/2023, 1:00 PM
It's a very old bug just now discovered by you and so it's still unfixed.
c

careful-mechanic-89327

04/04/2023, 1:02 PM
ok, no problem. At least I know it is not due to some bad configuration from my side
Thanks again
a

ancient-vegetable-10556

04/04/2023, 3:21 PM
@-Javier Benito Hi! Can you type
man touch
into your terminal, and send me me the contents of the
SYNOPSIS
block at the top, and the mac os version date listed at the bottom of the page?
You should see something like:
Copy code
SYNOPSIS
     touch [-A [-][[hh]mm]SS] [-achm] [-r file] [-t [[CC]YY]MMDDhhmm[.SS]]
           [-d YYYY-MM-DDThh:mm:SS[.frac][tz]] file ...
and
Copy code
macOS 12.6                        June 1, 2018                        macOS 12.6
e

enough-analyst-54434

04/04/2023, 3:23 PM
I used this for my research fwiw - not awesome info: https://ss64.com/osx/touch.html
a

ancient-vegetable-10556

04/04/2023, 3:24 PM
(noting that current versions of mac os
touch
supports
-d
as well as `-t`; GNU and BSD
touch
also support obsolescent arguments with a 2-digit year… which will leave us well supported until December 2038 🙄 )
Looks like
-t
is supported on GNU touch, so that’s probably the way to go here.
@careful-mechanic-89327 This will be fixed in Pants 2.14 and 2.15 in the next point release. Thanks for the report!
c

careful-mechanic-89327

04/05/2023, 8:17 AM
Thank you all. for the support