maturin 1.7.6b1__tar.gz → 1.7.7b1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of maturin might be problematic. Click here for more details.

Files changed (59) hide show
  1. {maturin-1.7.6b1 → maturin-1.7.7b1}/Cargo.lock +1 -1
  2. {maturin-1.7.6b1 → maturin-1.7.7b1}/Cargo.toml +1 -1
  3. {maturin-1.7.6b1 → maturin-1.7.7b1}/Changelog.md +4 -0
  4. {maturin-1.7.6b1 → maturin-1.7.7b1}/PKG-INFO +2 -2
  5. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/build_context.rs +1 -1
  6. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/build_options.rs +47 -44
  7. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/metadata.rs +2 -2
  8. {maturin-1.7.6b1 → maturin-1.7.7b1}/.cirrus.yml +0 -0
  9. {maturin-1.7.6b1 → maturin-1.7.7b1}/.codespellrc +0 -0
  10. {maturin-1.7.6b1 → maturin-1.7.7b1}/.config/nextest.toml +0 -0
  11. {maturin-1.7.6b1 → maturin-1.7.7b1}/.gitignore +0 -0
  12. {maturin-1.7.6b1 → maturin-1.7.7b1}/.pre-commit-config.yaml +0 -0
  13. {maturin-1.7.6b1 → maturin-1.7.7b1}/MANIFEST.in +0 -0
  14. {maturin-1.7.6b1 → maturin-1.7.7b1}/README.md +0 -0
  15. {maturin-1.7.6b1 → maturin-1.7.7b1}/clippy.toml +0 -0
  16. {maturin-1.7.6b1 → maturin-1.7.7b1}/license-apache +0 -0
  17. {maturin-1.7.6b1 → maturin-1.7.7b1}/license-mit +0 -0
  18. {maturin-1.7.6b1 → maturin-1.7.7b1}/maturin/__init__.py +0 -0
  19. {maturin-1.7.6b1 → maturin-1.7.7b1}/maturin/__main__.py +0 -0
  20. {maturin-1.7.6b1 → maturin-1.7.7b1}/maturin.schema.json +0 -0
  21. {maturin-1.7.6b1 → maturin-1.7.7b1}/netlify.toml +0 -0
  22. {maturin-1.7.6b1 → maturin-1.7.7b1}/pyproject.toml +0 -0
  23. {maturin-1.7.6b1 → maturin-1.7.7b1}/setup.py +0 -0
  24. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/auditwheel/audit.rs +0 -0
  25. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/auditwheel/manylinux-policy.json +0 -0
  26. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/auditwheel/mod.rs +0 -0
  27. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/auditwheel/musllinux-policy.json +0 -0
  28. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/auditwheel/musllinux.rs +0 -0
  29. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/auditwheel/patchelf.rs +0 -0
  30. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/auditwheel/platform_tag.rs +0 -0
  31. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/auditwheel/policy.rs +0 -0
  32. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/auditwheel/repair.rs +0 -0
  33. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/cargo_toml.rs +0 -0
  34. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/ci.rs +0 -0
  35. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/compile.rs +0 -0
  36. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/cross_compile.rs +0 -0
  37. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/develop.rs +0 -0
  38. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/generate_json_schema.rs +0 -0
  39. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/lib.rs +0 -0
  40. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/main.rs +0 -0
  41. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/module_writer.rs +0 -0
  42. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/new_project.rs +0 -0
  43. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/project_layout.rs +0 -0
  44. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/pyproject_toml.rs +0 -0
  45. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/python_interpreter/config.rs +0 -0
  46. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/python_interpreter/get_interpreter_metadata.py +0 -0
  47. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/python_interpreter/mod.rs +0 -0
  48. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/source_distribution.rs +0 -0
  49. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/target.rs +0 -0
  50. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/templates/.gitignore.j2 +0 -0
  51. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/templates/Cargo.toml.j2 +0 -0
  52. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/templates/__init__.py.j2 +0 -0
  53. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/templates/build.rs.j2 +0 -0
  54. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/templates/example.udl.j2 +0 -0
  55. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/templates/lib.rs.j2 +0 -0
  56. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/templates/main.rs.j2 +0 -0
  57. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/templates/pyproject.toml.j2 +0 -0
  58. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/templates/test_all.py.j2 +0 -0
  59. {maturin-1.7.6b1 → maturin-1.7.7b1}/src/upload.rs +0 -0
@@ -1341,7 +1341,7 @@ dependencies = [
1341
1341
 
1342
1342
  [[package]]
1343
1343
  name = "maturin"
1344
- version = "1.7.6-beta.1"
1344
+ version = "1.7.7-beta.1"
1345
1345
  dependencies = [
1346
1346
  "anyhow",
1347
1347
  "base64 0.21.7",
@@ -1,7 +1,7 @@
1
1
  [package]
2
2
  authors = ["konstin <konstin@mailbox.org>", "messense <messense@icloud.com>"]
3
3
  name = "maturin"
4
- version = "1.7.6-beta.1"
4
+ version = "1.7.7-beta.1"
5
5
  description = "Build and publish crates with pyo3, cffi and uniffi bindings as well as rust binaries as python packages"
6
6
  exclude = [
7
7
  "test-crates/**/*",
@@ -1,5 +1,9 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.7.6]
4
+
5
+ * Set core metadata version to 2.4 to fix `project.license.files` handling in [#2332](https://github.com/PyO3/maturin/pull/2332)
6
+
3
7
  ## [1.7.5]
4
8
 
5
9
  * Improve wheel reproducibility by sorting external libraries [#2261](https://github.com/PyO3/maturin/pull/2261)
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.3
1
+ Metadata-Version: 2.4
2
2
  Name: maturin
3
- Version: 1.7.6b1
3
+ Version: 1.7.7b1
4
4
  Classifier: Topic :: Software Development :: Build Tools
5
5
  Classifier: Programming Language :: Rust
6
6
  Classifier: Programming Language :: Python :: Implementation :: CPython
@@ -234,7 +234,7 @@ impl BuildContext {
234
234
  if !non_abi3_interps.is_empty() {
235
235
  let interp_names: HashSet<_> = non_abi3_interps
236
236
  .iter()
237
- .map(|interp| format!("{}{}{}", interp, interp.major, interp.minor))
237
+ .map(|interp| interp.to_string())
238
238
  .collect();
239
239
  eprintln!(
240
240
  "⚠️ Warning: {} does not yet support abi3 so the build artifacts will be version-specific.",
@@ -362,13 +362,28 @@ impl BuildOptions {
362
362
  }
363
363
  BridgeModel::Bin(None) | BridgeModel::UniFfi => Ok(vec![]),
364
364
  BridgeModel::BindingsAbi3(major, minor) => {
365
+ let found_interpreters =
366
+ find_interpreter_in_host(bridge, interpreter, target, requires_python)
367
+ .or_else(|err| {
368
+ // Can only use sysconfig-derived interpreter on windows if generating the import lib
369
+ if target.is_windows() && !generate_import_lib {
370
+ return Err(err.context("Need a Python interpreter to compile for Windows without PyO3's `generate-import-lib` feature"));
371
+ }
372
+
373
+ let interps =
374
+ find_interpreter_in_sysconfig(interpreter, target, requires_python)
375
+ .unwrap_or_default();
376
+ if interps.is_empty() && !self.interpreter.is_empty() {
377
+ // Print error when user supplied `--interpreter` option
378
+ Err(err)
379
+ } else {
380
+ Ok(interps)
381
+ }
382
+ })?;
383
+
365
384
  if target.is_windows() {
366
- // Ideally, we wouldn't want to use any python interpreter without abi3 at all.
367
- // Unfortunately, on windows we need one to figure out base_prefix for a linker
368
- // argument.
369
- let interpreters =
370
- find_interpreter_in_host(bridge, interpreter, target, requires_python)
371
- .unwrap_or_default();
385
+ // On windows we might need a Python executable to locate a base prefix for
386
+ // linker args, if we're not using PyO3's `generate-import-lib` feature.
372
387
  if env::var_os("PYO3_CROSS_LIB_DIR").is_some() {
373
388
  // PYO3_CROSS_LIB_DIR should point to the `libs` directory inside base_prefix
374
389
  // when cross compiling, so we fake a python interpreter matching it
@@ -394,48 +409,36 @@ impl BuildOptions {
394
409
  InterpreterConfig::from_pyo3_config(config_file.as_ref(), target)
395
410
  .context("Invalid PYO3_CONFIG_FILE")?;
396
411
  Ok(vec![PythonInterpreter::from_config(interpreter_config)])
397
- } else if let Some(interp) = interpreters.first() {
398
- eprintln!("🐍 Using {interp} to generate to link bindings (With abi3, an interpreter is only required on windows)");
399
- Ok(interpreters)
400
412
  } else if generate_import_lib {
401
- eprintln!("🐍 Not using a specific python interpreter (Automatically generating windows import library)");
402
- // fake a python interpreter
403
- Ok(vec![PythonInterpreter {
404
- config: InterpreterConfig {
405
- major: *major as usize,
406
- minor: *minor as usize,
407
- interpreter_kind: InterpreterKind::CPython,
408
- abiflags: "".to_string(),
409
- ext_suffix: ".pyd".to_string(),
410
- pointer_width: None,
411
- gil_disabled: false,
412
- },
413
- executable: PathBuf::new(),
414
- platform: None,
415
- runnable: false,
416
- implementation_name: "cpython".to_string(),
417
- soabi: None,
418
- }])
413
+ eprintln!("🐍 Not using a specific python interpreter (automatically generating windows import library)");
414
+ let mut found_interpreters = found_interpreters;
415
+ // fake a python interpreter if none directly found
416
+ if found_interpreters.is_empty() {
417
+ found_interpreters.push(PythonInterpreter {
418
+ config: InterpreterConfig {
419
+ major: *major as usize,
420
+ minor: *minor as usize,
421
+ interpreter_kind: InterpreterKind::CPython,
422
+ abiflags: "".to_string(),
423
+ ext_suffix: ".pyd".to_string(),
424
+ pointer_width: None,
425
+ gil_disabled: false,
426
+ },
427
+ executable: PathBuf::new(),
428
+ platform: None,
429
+ runnable: false,
430
+ implementation_name: "cpython".to_string(),
431
+ soabi: None,
432
+ })
433
+ }
434
+ Ok(found_interpreters)
419
435
  } else {
420
- bail!("Failed to find a python interpreter");
436
+ if found_interpreters.is_empty() {
437
+ bail!("Failed to find any python interpreter");
438
+ }
439
+ Ok(found_interpreters)
421
440
  }
422
441
  } else {
423
- let found_interpreters =
424
- find_interpreter_in_host(bridge, interpreter, target, requires_python)
425
- .or_else(|err| {
426
- let interps = find_interpreter_in_sysconfig(
427
- interpreter,
428
- target,
429
- requires_python,
430
- )
431
- .unwrap_or_default();
432
- if interps.is_empty() && !self.interpreter.is_empty() {
433
- // Print error when user supplied `--interpreter` option
434
- Err(err)
435
- } else {
436
- Ok(interps)
437
- }
438
- })?;
439
442
  eprintln!("🐍 Not using a specific python interpreter");
440
443
  if self.interpreter.is_empty() {
441
444
  // Fake one to make `BuildContext::build_wheels` happy for abi3 when no cpython/pypy found on host
@@ -70,7 +70,7 @@ impl Metadata23 {
70
70
  /// Initializes with name, version and otherwise the defaults
71
71
  pub fn new(name: String, version: Version) -> Self {
72
72
  Self {
73
- metadata_version: "2.3".to_string(),
73
+ metadata_version: "2.4".to_string(),
74
74
  name,
75
75
  version,
76
76
  platform: vec![],
@@ -679,7 +679,7 @@ mod test {
679
679
  );
680
680
 
681
681
  let expected = expect![[r#"
682
- Metadata-Version: 2.3
682
+ Metadata-Version: 2.4
683
683
  Name: info-project
684
684
  Version: 0.1.0
685
685
  Summary: A test project
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes