gac 0.17.1__tar.gz → 0.17.3__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 gac might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: gac
3
- Version: 0.17.1
3
+ Version: 0.17.3
4
4
  Summary: AI-powered Git commit message generator with multi-provider support
5
5
  Project-URL: Homepage, https://github.com/cellwebb/gac
6
6
  Project-URL: Documentation, https://github.com/cellwebb/gac#readme
@@ -1,3 +1,3 @@
1
1
  """Version information for gac package."""
2
2
 
3
- __version__ = "0.17.1"
3
+ __version__ = "0.17.3"
@@ -161,11 +161,16 @@ def push_changes() -> bool:
161
161
  return False
162
162
 
163
163
  try:
164
- run_git_command(["push"])
164
+ # Use raise_on_error=True to properly catch push failures
165
+ run_subprocess(["git", "push"], raise_on_error=True, strip_output=True)
165
166
  return True
166
- except GitError as e:
167
- if "fatal: No configured push destination" in str(e):
167
+ except subprocess.CalledProcessError as e:
168
+ error_msg = e.stderr.strip() if e.stderr else str(e)
169
+ if "fatal: No configured push destination" in error_msg:
168
170
  logger.error("No configured push destination.")
169
171
  else:
170
- logger.error(f"Failed to push changes: {e}")
172
+ logger.error(f"Failed to push changes: {error_msg}")
173
+ return False
174
+ except Exception as e:
175
+ logger.error(f"Failed to push changes: {e}")
171
176
  return False
@@ -270,15 +270,13 @@ def main(
270
270
  logger.info("Changes pushed successfully")
271
271
  console.print("[green]Changes pushed successfully[/green]")
272
272
  else:
273
- handle_error(
274
- GitError("Failed to push changes. Check your remote configuration."),
275
- exit_program=True,
273
+ console.print(
274
+ "[red]Failed to push changes. Check your remote configuration and network connection.[/red]"
276
275
  )
276
+ sys.exit(1)
277
277
  except Exception as e:
278
- handle_error(
279
- GitError(f"Error pushing changes: {e}"),
280
- exit_program=True,
281
- )
278
+ console.print(f"[red]Error pushing changes: {e}[/red]")
279
+ sys.exit(1)
282
280
 
283
281
  if not quiet:
284
282
  logger.info("Successfully committed changes with message:")
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