androidannotations icon indicating copy to clipboard operation
androidannotations copied to clipboard

Faulty import statement generated

Open krischik opened this issue 5 years ago • 2 comments

AndroidAnnotations version:

4.7.0

Android compile SDK version:

30

Annotated code:

   @org.androidannotations.annotations.FragmentById (R.id.Main_Fragment)
   @org.jetbrains.annotations.Nullable
   protected MainFragment mainFragment;

Expected generated code:

import java.util.HashMap;
import java.util.Map;
import com.krischik.fit_import.MainFragment;
import android.app.Activity;
import android.content.Context;

Actual generated code:

import java.util.HashMap;
import java.util.Map;
import(@org.jetbrains.annotations.Nullable :: com.krischik.fit_import.MainFragment);
import android.app.Activity;
import android.content.Context;

Stacktrace in case of AA crash:

N/A

krischik avatar Oct 23 '20 06:10 krischik

Quick check: Still happens with AndroidAnnotations version: 4.8.0.

krischik avatar Dec 17 '20 08:12 krischik

As a workaround, did you trie to remove the nullable annotation?

WonderCsabo avatar Dec 17 '20 15:12 WonderCsabo