exercism / dart

Exercism exercises in Dart.
https://exercism.org/tracks/dart
MIT License
57 stars 94 forks source link

New exercise: Roman Numerals #520

Closed glennj closed 7 months ago

glennj commented 7 months ago

I used bin/configlet create --practice-exercise roman-numerals to create the exercise, and that apparently formats the config.json file. Sorry for the extra noise

glennj commented 7 months ago

The presubmit script isn't running for me. I see this:

$ dart pub get
Resolving dependencies...
  _fe_analyzer_shared 49.0.0 (66.0.0 available)
  analyzer 5.1.0 (6.4.0 available)
  args 2.3.1 (2.4.2 available)
  async 2.9.0 (2.11.0 available)
  boolean_selector 2.1.0 (2.1.1 available)
  collection 1.16.0 (1.18.0 available)
  coverage 1.6.1 (1.7.2 available)
  crypto 3.0.2 (3.0.3 available)
  dart_style 2.2.4 (2.3.4 available)
  file 6.1.4 (7.0.0 available)
  frontend_server_client 3.0.0 (3.2.0 available)
  glob 2.1.0 (2.1.2 available)
  http_parser 4.0.1 (4.0.2 available)
  io 1.0.3 (1.0.4 available)
  js 0.6.4 (0.7.0 available)
  logging 1.1.0 (1.2.0 available)
  matcher 0.12.12 (0.12.16+1 available)
  meta 1.8.0 (1.11.0 available)
  mime 1.0.2 (1.0.4 available)
  node_preamble 2.0.1 (2.0.2 available)
  path 1.8.2 (1.9.0 available)
  pub_semver 2.1.1 (2.1.4 available)
  shelf 1.4.0 (1.4.1 available)
  shelf_packages_handler 3.0.1 (3.0.2 available)
  shelf_static 1.1.1 (1.1.2 available)
  shelf_web_socket 1.0.2 (1.0.4 available)
  source_map_stack_trace 2.1.0 (2.1.1 available)
  source_maps 0.10.10 (0.10.12 available)
  source_span 1.9.1 (1.10.0 available)
  stack_trace 1.10.0 (1.11.1 available)
  stream_channel 2.1.1 (2.1.2 available)
  string_scanner 1.1.1 (1.2.0 available)
  test 1.21.6 (1.25.2 available)
  test_api 0.4.14 (0.7.0 available)
  test_core 0.4.18 (0.6.0 available)
  typed_data 1.3.1 (1.3.2 available)
  vm_service 9.4.0 (14.0.0 available)
  watcher 1.0.1 (1.1.0 available)
  web_socket_channel 2.2.0 (2.4.3 available)
  webkit_inspection_protocol 1.2.0 (1.2.1 available)
  yaml 3.1.1 (3.1.2 available)
Got dependencies!
41 packages have newer versions incompatible with dependency constraints.
Try `dart pub outdated` for more information.

$ dart run bin/presubmit.dart
Formatting config.json...
Unsupported operation: Please see https://github.com/exercism/dart/issues/296
Formatting all Dart files...
Failed to build dart_style:format:
../../../../.pub-cache/hosted/pub.dev/watcher-1.0.1/lib/src/constructable_file_system_event.dart:7:57: Error: The class 'FileSystemEvent' can't be extended, implemented, or mixed in outside of its library because it's a sealed class.
abstract class _ConstructableFileSystemEvent implements FileSystemEvent {
                                                        ^
../../../../.pub-cache/hosted/pub.dev/pub_semver-2.1.1/lib/src/version_constraint.dart:96:13: Error: Method not found: 'FallThroughError'.
      throw FallThroughError();
            ^^^^^^^^^^^^^^^^
Failed to build dart_style:format:
../../../../.pub-cache/hosted/pub.dev/watcher-1.0.1/lib/src/constructable_file_system_event.dart:7:57: Error: The class 'FileSystemEvent' can't be extended, implemented, or mixed in outside of its library because it's a sealed class.
abstract class _ConstructableFileSystemEvent implements FileSystemEvent {
                                                        ^
../../../../.pub-cache/hosted/pub.dev/pub_semver-2.1.1/lib/src/version_constraint.dart:96:13: Error: Method not found: 'FallThroughError'.
      throw FallThroughError();
            ^^^^^^^^^^^^^^^^
Failed. Error code: 255.
Running tests...
Failed to build test:test:
../../../../.pub-cache/hosted/pub.dev/watcher-1.0.1/lib/src/constructable_file_system_event.dart:7:57: Error: The class 'FileSystemEvent' can't be extended, implemented, or mixed in outside of its library because it's a sealed class.
abstract class _ConstructableFileSystemEvent implements FileSystemEvent {
                                                        ^
../../../../.pub-cache/hosted/pub.dev/pub_semver-2.1.1/lib/src/version_constraint.dart:96:13: Error: Method not found: 'FallThroughError'.
      throw FallThroughError();
            ^^^^^^^^^^^^^^^^
Failed to build test:test:
../../../../.pub-cache/hosted/pub.dev/watcher-1.0.1/lib/src/constructable_file_system_event.dart:7:57: Error: The class 'FileSystemEvent' can't be extended, implemented, or mixed in outside of its library because it's a sealed class.
abstract class _ConstructableFileSystemEvent implements FileSystemEvent {
                                                        ^
../../../../.pub-cache/hosted/pub.dev/pub_semver-2.1.1/lib/src/version_constraint.dart:96:13: Error: Method not found: 'FallThroughError'.
      throw FallThroughError();
            ^^^^^^^^^^^^^^^^
Failed. Error code: 255.
Done!

$ dart --version
Dart SDK version: 3.2.5 (stable) (Tue Jan 16 15:02:13 2024 +0000) on "linux_x64"
Stargator commented 7 months ago

@glennj, the presubmit script needs to be updated since exercism made changes to how their end script works and I think presubmit needs to be updated to work with Dart 2.

Working on a separate ticket to update the repo to Dart 3