Commit Graph

17847 Commits

Author SHA1 Message Date
Alexandre Archambault 90c80c1959 Update sbt-coursier to 2.0.0-RC6-4 2020-05-12 14:49:14 +02:00
Adrien Piquerez 255a0a6ea6 send response to the source channel only 2020-05-12 14:44:10 +02:00
Alexandre Archambault d38e523663
Merge pull request #228 from alexarchambault/remove-sbt-shading
Remove sbt-shading sources
2020-05-12 10:50:24 +02:00
Adrien Piquerez df293fbfd5 prevent multiple response to a single request 2020-05-12 10:38:47 +02:00
Adrien Piquerez e040eebd21 "add failing json rpc response tests" 2020-05-12 10:37:48 +02:00
Alexandre Archambault e43be3d52d Update sbt-shading to 2.0.0 2020-05-12 01:00:40 +02:00
Alexandre Archambault 9694d32083 Remove sbt-shading sources
It now lives at https://github.com/coursier/sbt-shading.
2020-05-12 01:00:09 +02:00
Scala Steward bbcce56b4a
Update coursier to 2.0.0-RC6-15 (#225) 2020-05-12 00:54:15 +02:00
Scala Steward dc907dbf0d
Update scalatest to 3.1.2 (#226) 2020-05-12 00:54:07 +02:00
Adrien Piquerez 781584d137 id is mandatory in json rpc responses 2020-05-11 16:51:34 +02:00
eugene yokota e84e414328
Merge pull request #5546 from eed3si9n/wip/bumpio
IO 1.4.0-M6
2020-05-09 17:08:28 -04:00
Eugene Yokota e8ad695623 IO 1.4.0-M6 2020-05-09 15:53:33 -04:00
eugene yokota 9eedbce815
Merge pull request #5545 from eed3si9n/fport/duplicated-strings
[fport] Avoid tens of thousands of duplicated "TypeFuntions.const(())" strings
2020-05-09 15:04:46 -04:00
Jason Zaugg 43cc55a24c Avoid tens of thousands of duplicated "TypeFuntions.const(())" strings 2020-05-09 13:02:16 -04:00
Brice Jaglin 331ca6ec9b enable ServiceLoader discovery across classloader layers
java.util.ServiceLoader uses findResources(), which was not
overriden in ReverseLookupClassLoader, causing resources available
in the descendant classloader not to be discovered when a service
loader instance was using the top classloader.
2020-05-08 12:41:44 +02:00
eugene yokota f5eae27c69
Merge pull request #5531 from eatkins/optimize-task-progress
Optimize task progress performance
2020-05-06 23:07:39 -04:00
eugene yokota d2fa0f100e
Merge pull request #5533 from eatkins/ivy-xml
Make IvyXml.writeFiles private[sbt]
2020-05-06 11:46:29 -04:00
eugene yokota f6e64b0a14
Merge pull request #5530 from eatkins/build-sources
Rework build source monitoring
2020-05-06 11:31:56 -04:00
Ethan Atkins e3e53df797 Make IvyXml.writeFiles private[sbt]
I got confused an changed the access for the wrong method to support
https://github.com/sbt/sbt/pull/5364.

Partially reverts 5c55393f1b.
2020-05-06 07:43:22 -07:00
Ethan Atkins 9b2bbdd4cc Report progress on background thread
Having the progress reports directly generated in beforeWork delays the
task from being submitted to the executor. This commit moves all of the
reporting onto the background thread to avoid these delays since
progress is less important than task evaluation.
2020-05-05 21:28:08 -07:00
Ethan Atkins f4c11a63ab Re-implement meta build source checking
The old implementation of checkBuildSources can easily take 20ms to run
when called in MainLoop.processCommand. It is rarely faster than 4-5ms.
To reduce this overhead, I stopped using the checkBuildSources task in
processCommand. Instead, I manually cache the build source hashes in a
global state variable and add a file monitor that invalidate the entire
set of source hashes if any changes are detected. This could probably be
more efficient, but I figure that build sources change infrequently
enough that it's fine to just invalidate the entire list of source
hashes.

Because the CheckBuildSources instance is already watching the meta
build, I reworked Continuous to use that FileTreeRepository for the
build sources if it is available.

Bonus: fixes https://github.com/sbt/sbt/issues/5482
2020-05-05 21:26:04 -07:00
Ethan Atkins b829ac9796 Remove FileManagement
This was unused.
2020-05-05 21:25:56 -07:00
Ethan Atkins 0a06bfe2d5 Optimize TaskProgress.containsSkipTasks
I was surprised to find this method in a flamegraph* so I optimized it.
TaskProgress was actually on the hotpath of task evaluation so every
single task was slower to be enqueued with the CompletionService. After
this change, containsSkipTasks dropped out of the flamegraph.

*The flamegraph was for a compile loop where sbt constantly modified a
single source file and re-compiled it. The containsSkipTasks method
appeared in over 2% of the method calls.
2020-05-05 21:04:09 -07:00
eugene yokota 77cc7285ae
Merge pull request #5517 from eed3si9n/wip/js_workaround
Revert "Mark scala-js-macro pending"
2020-05-05 22:26:32 -04:00
Eugene Yokota de098b94d2 IO 1.4.0-M4 2020-05-05 21:47:48 -04:00
Eugene Yokota 5dfbcfb112 0.5.3-SNAPSHOT 2020-05-05 17:42:33 -04:00
eugene yokota 6c5e5334ef
Merge pull request #26 from sbt/wip/dir
Use .sbt/matrix/foo as base directory
2020-05-05 17:36:35 -04:00
Eugene Yokota 1c7615c992 Use .sbt/matrix/foo as base directory
Fixes #25
2020-05-05 14:45:55 -04:00
Alexandre Archambault 33af97d81e
Warn if legacy cache location ~/.coursier/cache is found (#222) 2020-05-05 19:59:59 +02:00
eugene yokota c39ed52112
Merge pull request #5529 from eatkins/dead-contra
Remove TaskProgressFormats autogenerated file
2020-05-05 12:58:24 -04:00
eugene yokota 0047a9803b
Implement missingOk (#212)
Ref https://github.com/coursier/coursier/issues/1541
Ref https://github.com/sbt/sbt/issues/4707

This adds `missingOk` setting to `CoursierConfiguration`, forwarding the `missingOk` setting in `UpdateConfiguration` from LM API. lmcoursier _not_ respecting this setting is causing various issues on sbt side since the expected behavior of some plugins (including IntelliJ import feature) is that the source JARs missing would not fail the entire operation.
Ideally we should return a partially resolved graph (for example if one out of 20 depdencies are missing source JARs it's still useful), but for now I'm going to return an empty `UpdateReport`.

Co-authored-by: Alexandre Archambault <alexandre.archambault@gmail.com>
2020-05-05 17:35:12 +02:00
Ethan Atkins ae978b9337 Remove TaskProgressFormats autogenerated file
This file somehow got stuck in the repo although it wasn't actually
used. In fact, it fails to compile at all because
sbt.internal.util.TaskProgress is defined in main, not util-logging. I
noticed this because metals wasn't working well because it was failing
to compile util-logging because of this file. I think the file was
checked in by accident in e28e052b5b.
2020-05-05 08:23:56 -07:00
eugene yokota 5d97d643b4
Merge pull request #5527 from frosforever/tag-fork-groups
Add user defined tags to Tests.Group to allow for better concurrency control
2020-05-04 11:50:47 -04:00
frosforever d1cf37b2ca Update Tests.Group to be bin compat by manually implementing case class methods 2020-05-04 09:29:31 -04:00
frosforever 2e4e3bbe13 Add scripted tests 2020-05-04 09:29:31 -04:00
frosforever 18d51eac58 Add tags to inProccess group as well 2020-05-04 09:29:31 -04:00
frosforever b2942f6321 Add user defined tags to Tests.Group 2020-05-04 09:29:31 -04:00
Scala Steward b1b8f2c441
Update sbt-ci-release to 1.5.3 (#216) 2020-05-04 12:40:13 +02:00
Scala Steward 38518561f3
Update coursier to 2.0.0-RC6-14 (#221) 2020-05-04 12:39:34 +02:00
Alexandre Archambault f336c89561
Merge pull request #220 from alexarchambault/header-based-auth
Allow authenticating via custom HTTP headers
2020-05-04 12:38:31 +02:00
Alexandre Archambault f37dd6af0f Support missing coursier.core.Authentication fields 2020-05-03 18:14:32 +02:00
richardgilmore e2876fb23e Allow authenticating via custom HTTP headers 2020-05-03 18:14:28 +02:00
richardgilmore 8c2d660434 Add IntelliJ and metals entries in .gitignore 2020-05-03 18:13:21 +02:00
Erwan Queffelec 23fdb324cb Fix coursierint NPE when credential realm is null
As stated in #5492 and #2366 some artifact hosting services (at least
Azure Artifacts, seems to affect GCP as well) do not offer a stable HTTP
Auth realm that can be safely set in SBT credentials, hence the need to
support null or empty Credentials.

The Ivy (publishing) side of the issue was fixed in sbt/ivy#36

As to the resolving side, This commit is only part of the solution as it
just prevents an NPE and does not consider if coursier itself will fall
back to finding credentials with a null realm that matches the server
hostname.

Related-to: #5492
Related-to: #2366
Signed-off-by: Erwan Queffelec <erwan.queffelec@gmail.com>
2020-05-03 15:53:19 +02:00
eugene yokota 5a529bf10c
Merge pull request #5319 from eatkins/terminal
Overhaul terminal io
2020-05-01 22:36:47 -04:00
Ethan Atkins a1ea5b72f3 Support capital letter options in doLoadFailed
Also display invalid response character.
2020-05-01 13:12:37 -07:00
Ethan Atkins 73235d12e0 Switch to lower case for some messages
There is push to move away from complete sentences in warnings.
2020-05-01 13:12:13 -07:00
Ethan Atkins 079cf2178c Add ClearScreenAfterCursor
This communicates intent better than clearScreen(0).
2020-05-01 13:02:48 -07:00
Ethan Atkins 24d4b3549b Set default supershell blank zone to 1
We do not need a large blank zone with the virtual system.out.
2020-05-01 12:35:43 -07:00
Ethan Atkins 5c42c20cdc Simplify setting dumbTerm variable 2020-05-01 12:35:43 -07:00