Comments (10)
@ahmadazimi You are using a compiled jar. The step that fails is the Android dex step which converts Java bytecode in the jar to Dalvik bytecode to be assembled in your apk. I have no idea if there is a way to bypass this check in the Android toolchain.
from iciql.
This is likely caused by bundling the AutoClosable interface in the jar so that iciql can still be used by Java 6 but also enjoy try-catch-with-resources introduced in Java 7. Is it Gradle that complains or Google's toolchain? Is there a way to disable that verification?
from iciql.
Hi,
I'm using Android Studio and Gradle build system (I am newbie in gradle)
I've tried running app using command line with gradle and the full error report is:
trouble processing "java/lang/AutoCloseable.class":
Ill-advised or mistaken usage of a core class (java.* or javax.*)
when not building a core library.
This is often due to inadvertently including a core library file
in your application's project, when using an IDE (such as
Eclipse). If you are sure you're not intentionally defining a
core class, then this is the most likely explanation of what's
going on.
However, you might actually be trying to define a class in a core
namespace, the source of which you may have taken, for example,
from a non-Android virtual machine project. This will most
assuredly not work. At a minimum, it jeopardizes the
compatibility of your app with future versions of the platform.
It is also often of questionable legality.
If you really intend to build a core library -- which is only
appropriate as part of creating a full virtual machine
distribution, as opposed to compiling an application -- then use
the "--core-library" option to suppress this error message.
If you go ahead and use "--core-library" but are in fact
building an application, then be forewarned that your application
will still fail to build or run, at some point. Please be
prepared for angry customers who find, for example, that your
application ceases to function once they upgrade their operating
system. You will be to blame for this problem.
If you are legitimately using some code that happens to be in a
core package, then the easiest safe alternative you have is to
repackage that code. That is, move the classes in question into
your own package namespace. This means that they will never be in
conflict with core system classes. JarJar is a tool that may help
you in this endeavor. If you find that you cannot do this, then
that is an indication that the path you are on will ultimately
lead to pain, suffering, grief, and lamentation.
1 error; aborting
:app:transformClassesWithDexForDebug FAILED
Do you have any idea how can I disable checking this in gradle or android studio?
from iciql.
Hi there,
I have the same problem using this library in Android Studio with Gradle.
When I try to build my app, gradle stop working on a task and print an error log starts with these lines:
:app:compileDebugNdk UP-TO-DATE
:app:compileDebugSources
:app:prePackageMarkerForDebug
:app:transformClassesWithDexForDebug
trouble processing "java/lang/AutoCloseable.class":
Ill-advised or mistaken usage of a core class (java.* or javax.*)
when not building a core library.
This is often due to inadvertently including a core library file
in your application's project, when using an IDE (such as
Eclipse). If you are sure you're not intentionally defining a
core class, then this is the most likely explanation of what's
going on.
and continue like @ahmadazarnia log.
Is there any way to not use gradle and instead using a compiled jar file? Or this problem may fixed in gradle build system?
from iciql.
Thank you @gitblit
I'm trying to find a solution for it and If I find it, give it here.
from iciql.
Hi,I tried to get select from MyTable seen below:
MyTable m = new MyTable();
m = db.from(m).where(m._id).is(1).selectFirst();
but,I get below error while compile:
com.iciql.IciqlException: unmapped field in statement! SELECT FROM missions WHERE ? = ?
Please help me!
from iciql.
Show me MyTable.
from iciql.
It is MyTable:
@Iciql.IQTable(name = "MyTable")
public class DBMission {
@Iciql.IQColumn(primaryKey = true, autoIncrement = true)
public int _id;
@Iciql.IQColumn
public int server_id;
@Iciql.IQColumn
public int agent_id;
@Iciql.IQColumn
public String mission_name;
@Iciql.IQColumn
public String route_name;
@Iciql.IQColumn
public String assigned_at;
@Iciql.IQColumn
public String import_status;
@Iciql.IQColumn
public String description;
@Iciql.IQColumn
public boolean is_active;
@Iciql.IQColumn
public boolean is_remote_mission;
public DBMission() {
}
}
from iciql.
That looks fine. I've never used this on Android. Perhaps the dex step is discarding file names rendering reflection useless? You could specify a name for the fields in the annotation as a test.
from iciql.
Assuming issue has been resolved or OP has moved on.
from iciql.
Related Issues (18)
- Class loading issue with dao interface proxy HOT 1
- IQTable.inheritColumns works only for depth 3 HOT 2
- IQColumn length with trim not working for DSL HOT 2
- imcomplete maven description HOT 1
- Generic Dao Iciql implementation HOT 16
- Database & Table Versioning HOT 1
- Unable to set null in some statements HOT 1
- Need groupBy methods
- Order by desc does not like primitives
- Unable to insert data which all column's value is null HOT 1
- Postgres 9.5 Upsert syntax is wrong
- The "where" compile-time statement did not work with "String" type field HOT 3
- JdbcUtils.DRIVERS.db2: "COM.ibm.db2.jdbc.net.DB2Driver" ??? HOT 3
- Activate Console Logger not function HOT 5
- Generation of classes via command line HOT 1
- SamplesTest method testSelectManyCompoundFrom2()
- Can't create a table for model HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from iciql.