GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — importOrderFile fails on "all unmatched type imports" group · Issue #2 · diffplug/spotless

importOrderFile fails on "all unmatched type imports" group #2

New issue
Copy link
New issue
Copy link
Closed
Closed
importOrderFile fails on "all unmatched type imports" group#2
Copy link

Description

@benjaminhawkeslewis
benjaminhawkeslewis
opened on Aug 24, 2015
Issue body actions

If you create an Eclipse import order including an "all unmatched type imports" group and attempt to use it with Spotless, Spotless errors.

Example import order file matching the Google Java style guide:

#Organize Import Order
#Sat Aug 22 12:43:31 BST 2015
4=javax
3=java
2=
1=com.google
0=\#

Note that "all unmatched type imports" (as the Eclipse UI phrases it) is represented by an empty string (number 2).

I think the error is produced in

spotless/src/main/java/com/diffplug/gradle/spotless/java/ImportSorterStep.java

Line 54 in 191e7dd

String name = pieces[1];
where it is assumed that splitting the line on = will produce two strings.

Activity

  1. nedtwigg commented on Aug 24, 2015

    @nedtwigg
    nedtwigg
    on Aug 24, 2015
    Member
    More actions

    Good find! There's a test harness for the import ordering here, which should make it easy to test a fix.

    I should be able to look into a fix by Wednesday. If you'd like to do it yourself before then, I'd be happy to help in the gitter chat and merge the PR.

  2. nedtwigg
    added a commit that references this issue on Aug 25, 2015

    Fixed an issue with "all unmatched type imports" (Issue #2).

    878fb2d
  3. nedtwigg commented on Aug 25, 2015

    @nedtwigg
    nedtwigg
    on Aug 25, 2015
    Member
    More actions

    Implemented in 1.2.0.

  4. nedtwigg
    closed this as completedon Aug 25, 2015
  5. nedtwigg
    added a commit that references this issue on Feb 2, 2018

    Attempt diffplug#2...

    ea6ebb5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402775 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.